# CVE-2024-21742: Apache James Mime4J: Mime4J DOM header injection

- Severity: Medium 5.3 (CVSS:3.1, scored by CISA-ADP) `CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:L/A:N`
- Known to be exploited: not in CISA's catalogue, which lists only what CISA has confirmed
- Likelihood of exploitation in the next 30 days (EPSS): 1.09%, higher than 66% of CVEs (2026-12-01)
- Published: 2024-02-27T16:21:16.432Z
- Modified: 2026-09-10T03:50:06.254Z
- Also known as: GHSA-jw7r-rxff-gv24
- Weaknesses: CWE-20, CWE-74
- SSVC (CISA-ADP): exploitation none, automatable no, technical impact partial
- Assigned by: apache

## Description

Improper input validation allows for header injection in MIME4J library when using MIME4J DOM for composing message.
This can be exploited by an attacker to add unintended headers to MIME messages.

(As written by CVE List.)

## Affected

- org.apache.james:apache-mime4j-dom: up to 0.8.9
- org.apache.james:apache-mime4j-core (Maven): before 0.8.10
- apache james_mime4j: up to 0.8.9

## Every score

- CISA-ADP: CVSS:3.1 5.3 Medium `CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:L/A:N`
- GitHub: CVSS:3.1 5.3 Medium `CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:L/A:N`
- NVD: CVSS:3.1 5.3 Medium `CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:L/A:N`

## References

- <https://lists.apache.org/thread/nrqzg93219wdj056pqfszsd33dc54kfy> (mailing-list, vendor-advisory, web)
- <http://www.openwall.com/lists/oss-security/2024/02/27/5> (mailing-list, web)
- <https://nvd.nist.gov/vuln/detail/CVE-2024-21742> (advisory)
- <https://github.com/apache/james-mime4j/commit/9dec5df2a588fed8027839815daefa79ee66efd1> (web)
- <https://github.com/apache/james-mime4j/commit/d25fb3fd35db42b060789a20634fbe3cb84aba17> (web)
- <https://github.com/apache/james-mime4j> (package)

## Sources

- CVE List: [CVE-2024-21742](https://www.cve.org/CVERecord?id=CVE-2024-21742), CVE Terms of Use, modified 2025-05-06
- GitHub Advisory Database: [GHSA-jw7r-rxff-gv24](https://github.com/advisories/GHSA-jw7r-rxff-gv24), CC-BY-4.0, modified 2026-09-10
- NVD: [CVE-2024-21742](https://nvd.nist.gov/vuln/detail/CVE-2024-21742), Public domain, modified 2026-06-17

---

Page: https://cve.day/CVE-2024-21742 · Whole record: https://cve.day/CVE-2024-21742.json · Rebuilt by cve.day 2026-11-25T22:58:37.087Z
