CVE-2026-42246: CWE-392: Missing Report of Error Condition in ruby net-imap
Net::IMAP implements Internet Message Access Protocol (IMAP) client functionality in Ruby. Prior to versions 0.3.10, 0.4.24, 0.5.14, and 0.6.4, a man-in-the-middle attacker can cause Net::IMAP#starttls to return "successfully", without starting TLS. This issue has been patched in versions 0.3.10, 0.4.24, 0.5.14, and 0.6.4.
AI Analysis
Technical Summary
The Ruby net-imap library's Net::IMAP#starttls method improperly handles certain responses during the STARTTLS negotiation, allowing a man-in-the-middle attacker to inject a predicted tagged OK response before the client completes the STARTTLS command. This causes the method to return success without actually establishing a TLS session, leaving the connection unencrypted and vulnerable to interception and modification. The vulnerability affects versions prior to 0.3.10, 0.4.24, 0.5.14, and 0.6.4 and has been patched in these versions. Exploitation complexity is high due to the need to intercept and modify network traffic and win a timing race. Red Hat has issued advisories and updates for affected products, including Red Hat Enterprise Linux 7 Extended Lifecycle Support. Temporary mitigation includes switching to implicit TLS connections on port 993, which bypasses the vulnerable STARTTLS negotiation path.
Potential Impact
Successful exploitation allows an attacker capable of man-in-the-middle interception to bypass TLS encryption during the STARTTLS upgrade, causing sensitive information such as authentication credentials and email contents to be transmitted in cleartext. This also enables unauthorized modification of data exchanged over the affected connection. The vulnerability impacts confidentiality and integrity but does not affect availability. The attack complexity is high, requiring network interception and precise timing.
Mitigation Recommendations
A fix is available in net-imap versions 0.3.10, 0.4.24, 0.5.14, and 0.6.4 and later. Users should upgrade to these patched versions to remediate the vulnerability. As a temporary workaround, it is strongly recommended to avoid using STARTTLS on port 143 and instead use implicit TLS connections (IMAPS) on port 993, which are not vulnerable to this attack vector. Red Hat has released security updates for affected Ruby packages in Red Hat Enterprise Linux 7 Extended Lifecycle Support. Users should apply these updates promptly.
CVE-2026-42246: CWE-392: Missing Report of Error Condition in ruby net-imap
Description
Net::IMAP implements Internet Message Access Protocol (IMAP) client functionality in Ruby. Prior to versions 0.3.10, 0.4.24, 0.5.14, and 0.6.4, a man-in-the-middle attacker can cause Net::IMAP#starttls to return "successfully", without starting TLS. This issue has been patched in versions 0.3.10, 0.4.24, 0.5.14, and 0.6.4.
CVSS v4.0
Score 7.6high
Affected software
AI-Powered Analysis
Machine-generated threat intelligence
Technical Analysis
The Ruby net-imap library's Net::IMAP#starttls method improperly handles certain responses during the STARTTLS negotiation, allowing a man-in-the-middle attacker to inject a predicted tagged OK response before the client completes the STARTTLS command. This causes the method to return success without actually establishing a TLS session, leaving the connection unencrypted and vulnerable to interception and modification. The vulnerability affects versions prior to 0.3.10, 0.4.24, 0.5.14, and 0.6.4 and has been patched in these versions. Exploitation complexity is high due to the need to intercept and modify network traffic and win a timing race. Red Hat has issued advisories and updates for affected products, including Red Hat Enterprise Linux 7 Extended Lifecycle Support. Temporary mitigation includes switching to implicit TLS connections on port 993, which bypasses the vulnerable STARTTLS negotiation path.
Potential Impact
Successful exploitation allows an attacker capable of man-in-the-middle interception to bypass TLS encryption during the STARTTLS upgrade, causing sensitive information such as authentication credentials and email contents to be transmitted in cleartext. This also enables unauthorized modification of data exchanged over the affected connection. The vulnerability impacts confidentiality and integrity but does not affect availability. The attack complexity is high, requiring network interception and precise timing.
Mitigation Recommendations
A fix is available in net-imap versions 0.3.10, 0.4.24, 0.5.14, and 0.6.4 and later. Users should upgrade to these patched versions to remediate the vulnerability. As a temporary workaround, it is strongly recommended to avoid using STARTTLS on port 143 and instead use implicit TLS connections (IMAPS) on port 993, which are not vulnerable to this attack vector. Red Hat has released security updates for affected Ruby packages in Red Hat Enterprise Linux 7 Extended Lifecycle Support. Users should apply these updates promptly.
Technical Details
- Data Version
- 5.2
- Assigner Short Name
- GitHub_M
- Date Reserved
- 2026-04-25T05:37:12.118Z
- Cvss Version
- 4.0
- State
- PUBLISHED
- Remediation Level
- null
- Vendor Advisory Urls
- [{"url":"https://access.redhat.com/security/cve/CVE-2026-42246","vendor":"Red Hat"}]
Threat ID: 69ff93c0cbff5d86106e4582
Added to database: 05/09/2026, 20:06:24 UTC
Last enriched: 08/05/2026, 12:59:50 UTC
Last updated: 08/12/2026, 15:26:16 UTC
Views: 244
Community Reviews
0 reviewsCrowdsource mitigation strategies, share intel context, and vote on the most helpful responses. Sign in to add your voice and help keep defenders ahead.
Want to contribute mitigation steps or threat intel context? Sign in or create an account to join the community discussion.
Actions
Updates to AI analysis require Pro Console access. Upgrade inside Console → Billing.
External Links
Need more coverage?
Upgrade to Pro Console for AI refresh and higher limits.
For incident response and remediation, OffSeq services can help resolve threats faster.
Latest Threats
Check if your credentials are on the dark web
Instant breach scanning across billions of leaked records. Free tier available.