Apache James vulnerable to STARTTLS command injection (IMAP and POP3)
Description
Apache James prior to release 3.6.1 is vulnerable to a buffering attack relying on the use of the STARTTLS command. This can result in Man-in -the-middle command injection attacks, leading potentially to leakage of sensible information.
AI Insight
LLM-synthesized narrative grounded in this CVE's description and references.
Apache James prior to 3.6.1 is vulnerable to a STARTTLS buffering attack, allowing MITM command injection and leakage of sensitive information.
Vulnerability
Apache James prior to release 3.6.1 is vulnerable to a buffering attack that leverages the STARTTLS command in SMTP, IMAP, and POP3 protocols. The vulnerability allows an attacker to inject commands during the TLS negotiation handshake by exploiting the buffering of plaintext commands before TLS is established. This issue is tracked as JAMES-1862 [1][2][3][4].
Exploitation
For SMTP exploitation, no prior authentication is required. For IMAP, a local account is needed; POP3 exploitation can compromise data integrity. An attacker with man-in-the-middle (MITM) network position can intercept the unencrypted STARTTLS command and inject commands that are processed before the TLS session begins, leading to command injection [1][3][4].
Impact
Successful exploitation results in MITM command injection attacks that can lead to leakage of sensitive information such as user credentials. Data integrity may be compromised in POP3 sessions [1][3][4].
Mitigation
Upgrade to Apache James 3.6.1 or later to fix the vulnerability. As a workaround, if possible, disable STARTTLS and rely solely on explicit TLS for SMTP, IMAP, and POP3 [1][3][4].
AI Insight generated on May 21, 2026. Synthesized from this CVE's description and the cited reference URLs; citations are validated against the source bundle.
Affected packages
Versions sourced from the GitHub Security Advisory.
| Package | Affected versions | Patched versions |
|---|---|---|
org.apache.james:james-serverMaven | < 3.6.1 | 3.6.1 |
Affected products
10- osv-coords9 versionspkg:apk/chainguard/keycloakpkg:apk/chainguard/keycloak-bitnami-compatpkg:apk/chainguard/keycloak-compatpkg:apk/chainguard/keycloak-iamguarded-compatpkg:apk/wolfi/keycloakpkg:apk/wolfi/keycloak-bitnami-compatpkg:apk/wolfi/keycloak-compatpkg:apk/wolfi/keycloak-iamguarded-compatpkg:maven/org.apache.james/james-server
< 0+ 8 more
- (no CPE)range: < 0
- (no CPE)range: < 0
- (no CPE)range: < 0
- (no CPE)range: < 0
- (no CPE)range: < 0
- (no CPE)range: < 0
- (no CPE)range: < 0
- (no CPE)range: < 0
- (no CPE)range: < 3.6.1
- Apache Software Foundation/Apache Jamesv5Range: Apache James
Patches
0No patches discovered yet.
Vulnerability mechanics
AI mechanics synthesis has not run for this CVE yet.
References
5- github.com/advisories/GHSA-84wg-rgp8-2hg4ghsaADVISORY
- nvd.nist.gov/vuln/detail/CVE-2021-38542ghsaADVISORY
- www.openwall.com/lists/oss-security/2022/01/04/1ghsamailing-listx_refsource_MLISTWEB
- www.openwall.com/lists/oss-security/2022/09/20/1ghsamailing-listx_refsource_MLISTWEB
- www.openwall.com/lists/oss-security/2022/01/04/1ghsax_refsource_MISCWEB
News mentions
0No linked articles in our index yet.