# CVE-2025-43857: net-imap rubygem vulnerable to possible DoS by memory exhaustion

Source: https://junglewise.ai/threats/cve-2025-43857-net-imap-rubygem-vulnerable-to-possible-dos-by-memory-exhaustion  
Publisher: Junglewise Threat Intelligence, https://junglewise.ai/threats  
Published: 2025-04-28  
License: CC BY 4.0 with a link back

CVE-2025-43857 · Severity: medium · CVSS 4 · Published 2025-04-28

net-imap rubygem vulnerable to possible DoS by memory exhaustion

Technologies: [net-imap (RubyGems)](https://junglewise.ai/threats/technologies/net-imap). Vendors: [RubyGems](https://junglewise.ai/threats/vendors/rubygems).

## Quick answers

**Is CVE-2025-43857 exploited in the wild?** No. Junglewise Threat Intelligence has no report of CVE-2025-43857 being exploited in the wild.

**How severe is CVE-2025-43857?** Medium severity, with a CVSS score of 4, published 28 April 2025.

**Which products and versions are affected?** net-imap (RubyGems) ECOSYSTEM:introduced=0.5.0,fixed=0.5.7.

**Is there a fix for CVE-2025-43857?** Yes. net-imap (RubyGems): upgrade to 0.5.7 or later. Junglewise finds every place you run it, drafts the upgrade and applies it once you approve.

**Am I affected by CVE-2025-43857?** Check whether you run net-imap (RubyGems) at an affected version. Junglewise does that check for you around the clock: connect your code, cloud and domains, and it matches new vulnerabilities like this one against what you actually run and tells you when one reaches you.

## How to fix

- net-imap (RubyGems): upgrade to 0.5.7 or later

  ```sh
  bundle update net-imap
  ```


## Affected products

- net-imap (RubyGems) ECOSYSTEM:introduced=0.5.0,fixed=0.5.7

## Identifiers

- CVE-2025-43857
- GHSA-j3g3-5qv5-52mj

## Related threats

- [Ruby Net::IMAP command injection in ID and ENABLE commands](https://junglewise.ai/threats/cve-2026-47242-ruby-net-imap-command-injection-in-id-and-enable-commands)
- [Ruby Net::IMAP denial of service via incomplete raw argument validation](https://junglewise.ai/threats/cve-2026-47241-ruby-net-imap-denial-of-service-via-incomplete-raw-argument)
- [Ruby Net::IMAP command injection via non-synchronizing literals](https://junglewise.ai/threats/cve-2026-47240-ruby-net-imap-command-injection-via-non-synchronizing-literals)
- [Ruby Net::IMAP command injection via Symbol arguments](https://junglewise.ai/threats/cve-2026-42258-ruby-net-imap-command-injection-via-symbol-arguments)
- [Ruby Net::IMAP command injection in multiple commands](https://junglewise.ai/threats/cve-2026-42257-ruby-net-imap-command-injection-in-multiple-commands)
