---
title: "CVE-2026-42257"
canonical_url: "https://pkgseek.com/security/CVE-2026-42257"
locale: "en"
source: "pkgseek"
entity_type: "cve"
severity: "critical"
---

# CVE-2026-42257

Net::IMAP implements Internet Message Access Protocol (IMAP) client functionality in Ruby. Prior to versions 0.4.24, 0.5.14, and 0.6.4, several Net::IMAP commands accept a raw string argument that is sent to the server without validation or escaping. If this string is derived from user-controlled input, it may contain contain CRLF sequences, which an attacker can use to inject arbitrary IMAP commands. This issue has been patched in versions 0.4.24, 0.5.14, and 0.6.4.

CVE-2026-42257 is rated CRITICAL (9.8), with 226 indexed affected package builds across 7 distributions.

- **Severity / Score**: CRITICAL (9.8)
- **Affected builds**: 226
- **Affected distros**: 7
- **Distros with fixed_in**: Alibaba Cloud Linux, AlmaLinux, Debian, OpenAnolis, Oracle Linux, Rocky Linux

## Affected Packages

| Distribution | Release | Package | Version | Fixed In |
| --- | --- | --- | --- | --- |
| Alibaba Cloud Linux | 4 | ruby | 3.3.9-7.alnx4 | 3.3.9-8.alnx4 |
| Alibaba Cloud Linux | 4 | ruby-bundled-gems | 3.3.9-7.alnx4 | 3.3.9-8.alnx4 |
| Alibaba Cloud Linux | 4 | ruby-default-gems | 3.3.9-7.alnx4 | 3.3.9-8.alnx4 |
| Alibaba Cloud Linux | 4 | ruby-devel | 3.3.9-7.alnx4 | 3.3.9-8.alnx4 |
| Alibaba Cloud Linux | 4 | ruby-doc | 3.3.9-7.alnx4 | 3.3.9-8.alnx4 |
| Alibaba Cloud Linux | 4 | rubygem-bigdecimal | 3.1.5-7.alnx4 | 3.1.5-8.alnx4 |
| Alibaba Cloud Linux | 4 | rubygem-bundler | 2.5.22-7.alnx4 | 2.5.22-8.alnx4 |
| Alibaba Cloud Linux | 4 | rubygem-io-console | 0.7.1-7.alnx4 | 0.7.1-8.alnx4 |
| Alibaba Cloud Linux | 4 | rubygem-irb | 1.13.1-7.alnx4 | 1.13.1-8.alnx4 |
| Alibaba Cloud Linux | 4 | rubygem-json | 2.7.2-7.alnx4 | 2.7.2-8.alnx4 |
| Alibaba Cloud Linux | 4 | rubygem-minitest | 5.20.0-7.alnx4 | 5.20.0-8.alnx4 |
| Alibaba Cloud Linux | 4 | rubygem-power_assert | 2.0.3-7.alnx4 | 2.0.3-8.alnx4 |
| Alibaba Cloud Linux | 4 | rubygem-psych | 5.1.2-7.alnx4 | 5.1.2-8.alnx4 |
| Alibaba Cloud Linux | 4 | rubygem-rake | 13.1.0-7.alnx4 | 13.1.0-8.alnx4 |
| Alibaba Cloud Linux | 4 | rubygem-rbs | 3.4.0-7.alnx4 | 3.4.0-8.alnx4 |
| Alibaba Cloud Linux | 4 | rubygem-rdoc | 6.6.3.1-7.alnx4 | 6.6.3.1-8.alnx4 |
| Alibaba Cloud Linux | 4 | rubygem-rexml | 3.3.9-7.alnx4 | 3.3.9-8.alnx4 |
| Alibaba Cloud Linux | 4 | rubygem-rss | 0.3.1-7.alnx4 | 0.3.1-8.alnx4 |
| Alibaba Cloud Linux | 4 | rubygems | 3.5.22-7.alnx4 | 3.5.22-8.alnx4 |
| Alibaba Cloud Linux | 4 | rubygems-devel | 3.5.22-7.alnx4 | 3.5.22-8.alnx4 |
| Alibaba Cloud Linux | 4 | rubygem-test-unit | 3.6.1-7.alnx4 | 3.6.1-8.alnx4 |
| Alibaba Cloud Linux | 4 | rubygem-typeprof | 0.21.9-7.alnx4 | 0.21.9-8.alnx4 |
| Alibaba Cloud Linux | 4 | ruby-libs | 3.3.9-7.alnx4 | 3.3.9-8.alnx4 |
| AlmaLinux | 9 | ruby | 3.0.7-170.el9_8 | 4.0.6-34.module_el9.8.0+289+5a070f48 |
| AlmaLinux | 9 | ruby-bundled-gems | 3.3.13-10.module_el9.8.0+336+233af6ab | 4.0.6-34.module_el9.8.0+289+5a070f48 |
| AlmaLinux | 9 | ruby-default-gems | 3.0.7-170.el9_8 | 4.0.6-34.module_el9.8.0+289+5a070f48 |
| AlmaLinux | 9 | ruby-devel | 3.0.7-170.el9_8 | 4.0.6-34.module_el9.8.0+289+5a070f48 |
| AlmaLinux | 9 | ruby-doc | 3.3.13-10.module_el9.8.0+336+233af6ab | 4.0.6-34.module_el9.8.0+289+5a070f48 |
| AlmaLinux | 9 | rubygem-bigdecimal | 3.0.0-170.el9_8 | 4.0.6-34.module_el9.8.0+289+5a070f48 |
| AlmaLinux | 9 | rubygem-bundler | 2.2.33-170.el9_8 | 4.0.6-34.module_el9.8.0+289+5a070f48 |
| AlmaLinux | 9 | rubygem-io-console | 0.5.7-170.el9_8 | 3.3.12-8.module_el9.8.0+288+22f1c9f2 |
| AlmaLinux | 9 | rubygem-irb | 1.3.5-170.el9_8 | 3.3.12-8.module_el9.8.0+288+22f1c9f2 |
| AlmaLinux | 9 | rubygem-json | 2.5.1-170.el9_8 | 3.3.12-8.module_el9.8.0+288+22f1c9f2 |
| AlmaLinux | 9 | rubygem-minitest | 5.14.2-170.el9_8 | 6.0.0-34.module_el9.8.0+289+5a070f48 |
| AlmaLinux | 9 | rubygem-mysql2 | 0.5.5-3.module_el9.7.0+184+e2e36072 | 0.5.7-1.module_el9.8.0+232+50f6dd36 |
| AlmaLinux | 9 | rubygem-mysql2-doc | 0.5.5-3.module_el9.7.0+184+e2e36072 | 0.5.7-1.module_el9.8.0+232+50f6dd36 |
| AlmaLinux | 9 | rubygem-pg | 1.5.4-2.module_el9.7.0+245+447713a2 | 1.6.3-1.module_el9.8.0+232+50f6dd36 |
| AlmaLinux | 9 | rubygem-pg-doc | 1.5.4-2.module_el9.7.0+245+447713a2 | 1.6.3-1.module_el9.8.0+232+50f6dd36 |
| AlmaLinux | 9 | rubygem-power_assert | 1.2.1-170.el9_8 | 3.3.12-8.module_el9.8.0+288+22f1c9f2 |
| AlmaLinux | 9 | rubygem-psych | 3.3.2-170.el9_8 | 5.3.1-34.module_el9.8.0+289+5a070f48 |
| AlmaLinux | 9 | rubygem-racc | 1.8.1-36.module_el9.8.0+337+2e29b311 | 3.3.12-8.module_el9.8.0+288+22f1c9f2 |
| AlmaLinux | 9 | rubygem-rake | 13.0.3-170.el9_8 | 13.3.1-34.module_el9.8.0+289+5a070f48 |
| AlmaLinux | 9 | rubygem-rbs | 1.4.0-170.el9_8 | 4.0.6-34.module_el9.8.0+289+5a070f48 |
| AlmaLinux | 9 | rubygem-rdoc | 6.3.4.1-170.el9_8 | 7.0.4-34.module_el9.8.0+289+5a070f48 |
| AlmaLinux | 9 | rubygem-rexml | 3.2.5-170.el9_8 | 4.0.6-34.module_el9.8.0+289+5a070f48 |
| AlmaLinux | 9 | rubygem-rss | 0.2.9-170.el9_8 | 3.3.12-8.module_el9.8.0+288+22f1c9f2 |
| AlmaLinux | 9 | rubygems | 3.2.33-170.el9_8 | 4.0.6-34.module_el9.8.0+289+5a070f48 |
| AlmaLinux | 9 | rubygems-devel | 3.2.33-170.el9_8 | 4.0.6-34.module_el9.8.0+289+5a070f48 |
| AlmaLinux | 9 | rubygem-test-unit | 3.3.7-170.el9_8 | 4.0.6-34.module_el9.8.0+289+5a070f48 |
| AlmaLinux | 9 | rubygem-typeprof | 0.15.2-170.el9_8 | 3.3.12-8.module_el9.8.0+288+22f1c9f2 |
| AlmaLinux | 9 | ruby-libs | 3.0.7-170.el9_8 | 4.0.6-34.module_el9.8.0+289+5a070f48 |
| Debian | trixie | libruby3.3 | 3.3.8-2 | 3.3.13-0+deb13u1 |
| Debian | trixie | ruby3.3 | 3.3.8-2 | 3.3.13-0+deb13u1 |
| Debian | trixie | ruby3.3-dev | 3.3.8-2 | 3.3.13-0+deb13u1 |
| Debian | trixie | ruby3.3-doc | 3.3.8-2 | 3.3.13-0+deb13u1 |
| OpenAnolis | 23.4 | ruby | 3.3.9-7.an23 | 3.3.9-8.an23 |
| OpenAnolis | 23.4 | ruby-bundled-gems | 3.3.9-7.an23 | 3.3.9-8.an23 |
| OpenAnolis | 23.4 | ruby-default-gems | 3.3.9-7.an23 | 3.3.9-8.an23 |
| OpenAnolis | 23.4 | ruby-devel | 3.3.9-7.an23 | 3.3.9-8.an23 |
| OpenAnolis | 23.4 | ruby-doc | 3.3.9-7.an23 | 3.3.9-8.an23 |
| OpenAnolis | 23.4 | rubygem-bigdecimal | 3.1.5-7.an23 | 3.1.5-8.an23 |
| OpenAnolis | 23.4 | rubygem-bundler | 2.5.22-7.an23 | 2.5.22-8.an23 |
| OpenAnolis | 23.4 | rubygem-io-console | 0.7.1-7.an23 | 0.7.1-8.an23 |
| OpenAnolis | 23.4 | rubygem-irb | 1.13.1-7.an23 | 1.13.1-8.an23 |
| OpenAnolis | 23.4 | rubygem-json | 2.7.2-7.an23 | 2.7.2-8.an23 |
| OpenAnolis | 23.4 | rubygem-minitest | 5.20.0-7.an23 | 5.20.0-8.an23 |
| OpenAnolis | 23.4 | rubygem-power_assert | 2.0.3-7.an23 | 2.0.3-8.an23 |
| OpenAnolis | 23.4 | rubygem-psych | 5.1.2-7.an23 | 5.1.2-8.an23 |
| OpenAnolis | 23.4 | rubygem-racc | 1.7.3-7.an23 | 1.7.3-8.an23 |
| OpenAnolis | 23.4 | rubygem-rake | 13.1.0-7.an23 | 13.1.0-8.an23 |
| OpenAnolis | 23.4 | rubygem-rbs | 3.4.0-7.an23 | 3.4.0-8.an23 |
| OpenAnolis | 23.4 | rubygem-rdoc | 6.6.3.1-7.an23 | 6.6.3.1-8.an23 |
| OpenAnolis | 23.4 | rubygem-rexml | 3.3.9-7.an23 | 3.3.9-8.an23 |
| OpenAnolis | 23.4 | rubygem-rss | 0.3.1-7.an23 | 0.3.1-8.an23 |
| OpenAnolis | 23.4 | rubygems | 3.5.22-7.an23 | 3.5.22-8.an23 |
| OpenAnolis | 23.4 | rubygems-devel | 3.5.22-7.an23 | 3.5.22-8.an23 |
| OpenAnolis | 23.4 | rubygem-test-unit | 3.6.1-7.an23 | 3.6.1-8.an23 |
| OpenAnolis | 23.4 | rubygem-typeprof | 0.21.9-7.an23 | 0.21.9-8.an23 |
| OpenAnolis | 23.4 | ruby-libs | 3.3.9-7.an23 | 3.3.9-8.an23 |
| Oracle Linux | 10 | ruby | 3.3.10-13.el10_2 | 3.3.12-14.el10_2 |
| Oracle Linux | 10 | ruby4.0 | 4.0.3-35.el10_2 | 4.0.6-36.el10_2 |
| Oracle Linux | 10 | ruby4.0-devel | 4.0.3-35.el10_2 | 4.0.6-36.el10_2 |
| Oracle Linux | 10 | ruby4.0-rubygem-mysql2 | 0.5.7-35.el10_2 | 0.5.7-36.el10_2 |
| Oracle Linux | 10 | ruby4.0-rubygem-pg | 1.6.3-35.el10_2 | 1.6.3-36.el10_2 |
| Oracle Linux | 10 | ruby-bundled-gems | 3.3.10-13.el10_2 | 3.3.12-14.el10_2 |
| Oracle Linux | 10 | ruby-default-gems | 3.3.10-13.el10_2 | 3.3.12-14.el10_2 |
| Oracle Linux | 10 | ruby-devel | 3.3.10-13.el10_2 | 3.3.12-14.el10_2 |
| Oracle Linux | 10 | rubygem-bigdecimal | 3.1.5-13.el10_2 | 3.1.5-14.el10_2 |
| Oracle Linux | 10 | rubygem-bundler | 2.5.22-13.el10_2 | 2.5.22-14.el10_2 |
| Oracle Linux | 10 | rubygem-io-console | 0.7.1-13.el10_2 | 0.7.1-14.el10_2 |
| Oracle Linux | 10 | rubygem-irb | 1.13.1-13.el10_2 | 1.13.1-14.el10_2 |
| Oracle Linux | 10 | rubygem-json | 2.7.2-13.el10_2 | 2.7.2-14.el10_2 |
| Oracle Linux | 10 | rubygem-minitest | 5.20.0-13.el10_2 | 5.20.0-14.el10_2 |
| Oracle Linux | 10 | rubygem-power_assert | 2.0.3-13.el10_2 | 2.0.3-14.el10_2 |
| Oracle Linux | 10 | rubygem-psych | 5.1.2-13.el10_2 | 5.1.2-14.el10_2 |
| Oracle Linux | 10 | rubygem-racc | 1.7.3-13.el10_2 | 1.7.3-14.el10_2 |
| Oracle Linux | 10 | rubygem-rake | 13.1.0-13.el10_2 | 13.1.0-14.el10_2 |
| Oracle Linux | 10 | rubygem-rbs | 3.4.0-13.el10_2 | 3.4.0-14.el10_2 |
| Oracle Linux | 10 | rubygem-rdoc | 6.6.3.1-13.el10_2 | 6.6.3.1-14.el10_2 |
| Oracle Linux | 10 | rubygem-rexml | 3.4.4-13.el10_2 | 3.4.4-14.el10_2 |

_Showing 100 of 226 total affected builds._
