CVE detail

CVE-2009-3766

Mutt SSL vulnerability affects users of versions before 1.5.19

MediumModified
CVSS6.8
EPSS
Exploitability5
Exploit refs0

Summary

Mutt before 1.5.19 fails to verify the Common Name (CN) in X.509 certificates when using OpenSSL, enabling man-in-the-middle attacks via any valid certificate. This undermines TLS trust for email and other SSL connections.

Published

Oct 24, 2009

Last modified

Jun 17, 2026

CWE

CWE-310 · Cryptographic Issues

Affected product

cpe:2.3:a:mutt:mutt:*:*:*:*:*:*:*:*

Why exploitable

Why Exploitable

The CVE-2009-3766 vulnerability in mutt is exploitable due to its failure to verify the domain name in the subject's Common Name (CN) field of an X.509 certificate. This allows man-in-the-middle attackers to spoof SSL servers using an arbitrary valid certificate.

  • Empirical exploitation probability (EPSS) is not available for this CVE, which makes it difficult to assess the likelihood of exploitation.
  • The absence of public exploit/PoC references and its exclusion from CISA KEV may indicate a lower urgency. However, organizations should still validate their mutt versions and update to 1.5.19 or later to prevent potential man-in-the-middle attacks.

Technical details

Overview

CVE-2009-3766 is a cryptographic vulnerability in the mutt email client, specifically in the mutt_ssl.c module, affecting versions 1.5.16 through 1.5.18 when compiled with OpenSSL. The flaw causes mutt to skip verification of the Common Name (CN) field in X.509 certificates, meaning any valid certificate—even one issued for a different domain—will be accepted as authentic. This allows an attacker in a privileged network position (e.g., on the same LAN or as a rogue Wi-Fi access point) to perform man-in-the-middle (MITM) attacks against mutt users, intercepting or modifying SSL/TLS-protected email traffic. The vulnerability was publicly disclosed and patched in mutt 1.5.19. The NVD rates it as MEDIUM severity (CVSS 6.8), and the EPSS percentile of 62.5 indicates moderate exploitation likelihood. Red Hat Linux distributions are among the affected platforms. Security teams managing mail servers or endpoints with mutt should prioritize patching, especially in environments where email confidentiality is critical.

Technical details

The root cause lies in the certificate verification logic within mutt_ssl.c. When mutt establishes an SSL/TLS connection using OpenSSL, it should call a function to verify that the certificate's Common Name (or Subject Alternative Name) matches the server hostname the client intended to connect to. In affected versions, this hostname check is entirely omitted. The code path that performs certificate chain validation (e.g., checking expiry, issuer trust) remains intact, so a certificate that is otherwise valid (signed by a trusted CA, not expired) will be accepted even if it was issued for a completely different domain. The vulnerability is classified under CWE-310 (Cryptographic Issues), specifically a missing or improper certificate hostname verification. Attack prerequisites include network access to intercept and modify traffic between the mutt client and the target mail server (e.g., via ARP spoofing, DNS poisoning, or rogue Wi-Fi). The attacker must also possess or obtain a valid X.509 certificate for any domain (e.g., a cheap or self-signed certificate that the client's trust store accepts). No authentication or user interaction beyond initiating an SSL connection is required.

Impact

Successful exploitation allows an attacker to decrypt, read, and modify all email traffic transmitted over SSL/TLS between mutt and the mail server. This includes login credentials (username/password), email content, and attachments. The confidentiality and integrity of email communications are completely compromised. Downstream abuse scenarios include credential theft for further lateral movement, email account takeover, and injection of malicious content (e.g., phishing links or malware) into trusted email threads. For organizations, this can lead to data breaches, compliance violations (e.g., HIPAA, GDPR), and reputational damage. The attack does not require sophisticated malware; it can be executed with standard MITM tools (e.g., ettercap, mitmproxy) and a valid certificate. The impact is amplified in environments where mutt is used for sensitive communications, such as system administration or secure file transfers.

Exploitation steps

  1. The attacker gains a position on the network path between the victim's mutt client and the target mail server (e.g., via ARP spoofing, rogue DHCP, or compromised router).
  2. The attacker obtains a valid X.509 certificate for any domain (e.g., by purchasing a cheap DV certificate or using a self-signed certificate if the client's trust store accepts it).
  3. When the victim's mutt initiates an SSL/TLS connection to the mail server (e.g., imaps://mail.example.com), the attacker intercepts the TCP handshake.
  4. The attacker establishes an SSL/TLS session with the victim, presenting the attacker's certificate (which is valid but for a different domain).
  5. Simultaneously, the attacker opens a separate SSL/TLS connection to the legitimate mail server, using the server's real certificate.
  6. The attacker relays data between the two sessions, decrypting traffic from the victim, reading/modifying it, and re-encrypting it to the server.
  7. The victim's mutt accepts the attacker's certificate because the CN check is missing; no warning is displayed.
  8. The attacker can now capture credentials, read emails, and inject arbitrary content into the email stream.

Indicators of compromise

  • Network: Unexpected SSL/TLS certificates presented to mutt clients, especially certificates with a CN that does not match the intended mail server hostname. Monitor for certificate mismatches in TLS handshake logs.
  • Logs: Mutt debug logs (if enabled) may show certificate acceptance without hostname verification. Look for absence of hostname check messages.
  • EDR: Unusual outbound connections from mutt processes to IP addresses not associated with the configured mail server. Processes initiating multiple TLS handshakes in quick succession.
  • Behavioral: Users reporting missing or modified emails, or unexpected certificate prompts (though mutt may not prompt due to the bug).
  • System: Presence of MITM tools (e.g., ettercap, mitmproxy) on the network segment. Unauthorized ARP table changes.
  • Certificate transparency: Check for certificates issued to domains that are not owned by the organization but appear in TLS logs.

Mitigation and workarounds

  • Patch: Upgrade mutt to version 1.5.19 or later, which includes proper CN verification. For Red Hat systems, apply the relevant package update (e.g., yum update mutt).
  • Workaround: If patching is not immediately possible, disable SSL/TLS in mutt and use STARTTLS with strict hostname checks (though this may not fully mitigate). Alternatively, use a different email client that performs proper certificate validation.
  • Compensating controls: Implement network segmentation to limit MITM attack surface. Use certificate pinning or public key pinning where supported. Deploy TLS inspection at the network perimeter to detect anomalous certificates.
  • Monitoring: Enable detailed logging for mutt and mail server connections. Alert on any certificate validation failures or mismatches.

Community reactions

The vulnerability was disclosed in 2009 and quickly patched in mutt 1.5.19. Red Hat issued advisories (RHSA-2009:1513) and updated packages. The security community noted the simplicity of the attack and the critical nature of missing hostname verification in an email client. Some discussions highlighted that the bug had existed for several versions, emphasizing the need for thorough code review of SSL/TLS implementations. OpenSSL's own documentation and best practices were referenced as guidance for developers. The CVE remains a classic example of improper certificate validation.

Additional resources

References

Intelligence is provided for awareness and triage. Validate exposure in your own environment before prioritising remediation.

CVE-2009-3766 · Mutt SSL vulnerability affects users of versions before 1.5.19 | CVE Intelligence | Trusteed