Description
Nodemailer before 8.0.4 is vulnerable to SMTP command injection through the unsanitized envelope.size parameter. When an application passes a custom envelope object with a size property containing CRLF characters to sendMail(), the value is concatenated into the SMTP MAIL FROM command (as SIZE=...) without sanitization, allowing injection of arbitrary SMTP commands such as RCPT TO to silently add attacker-controlled recipients. Exploitation requires the application to expose the envelope size to attacker-controlled input, as Nodemailer does not include size in the default auto-constructed envelope.
Published: 2026-08-31
Score: 9.3 Critical
EPSS: n/a
KEV: No
Impact: n/a
Action: n/a
AI Analysis

Impact

This vulnerability allows arbitrary SMTP commands to be injected through an unsanitized envelope.size field supplied to sendMail(). By embedding CRLF characters, an attacker can inject commands such as RCPT TO, silently adding recipients and potentially delivering unused email traffic or facilitating spam. The flaw is a classic example of command injection (CWE-93) and can lead to unauthorized mail delivery, data leakage, and system abuse.

Affected Systems

The flaw exists in the Nodemailer library prior to version 8.0.4. Any application that uses Nodemailer and accepts externally controllable envelope.size values is impacted. The default configuration in older releases does not include a size value, so the risk is contingent on the application explicitly providing this parameter.

Risk and Exploitability

The vulnerability carries a CVSS score of 9.3, indicating critical severity. The EPSS score is not available, and the issue is not listed in the CISA KEV catalog. Exploitation requires the attacker to control or influence the envelope.size value; once injected, arbitrary SMTP commands are executed during the mail transaction, facilitating silent message delivery or other attacks. The likely attack vector is through application input that is reflected in the SMTP conversation, making it a network-based exploit.

Generated by OpenCVE AI on August 31, 2026 at 10:28 UTC.

Remediation

No vendor fix or workaround currently provided.

OpenCVE Recommended Actions

  • Upgrade Nodemailer to version 8.0.4 or later, which sanitizes the envelope.size field.
  • If an upgrade cannot be performed immediately, validate or sanitize any user-supplied envelope.size value to remove CRLF characters before passing it to sendMail().
  • Restrict applications from allowing unauthenticated users to specify the envelope.size parameter or remove the parameter entirely if it is not required.

Generated by OpenCVE AI on August 31, 2026 at 10:28 UTC.

Tracking

Sign in to view the affected projects.

Advisories

No advisories yet.

History

Mon, 31 Aug 2026 09:00:00 +0000

Type Values Removed Values Added
Description Nodemailer before 8.0.4 is vulnerable to SMTP command injection through the unsanitized envelope.size parameter. When an application passes a custom envelope object with a size property containing CRLF characters to sendMail(), the value is concatenated into the SMTP MAIL FROM command (as SIZE=...) without sanitization, allowing injection of arbitrary SMTP commands such as RCPT TO to silently add attacker-controlled recipients. Exploitation requires the application to expose the envelope size to attacker-controlled input, as Nodemailer does not include size in the default auto-constructed envelope.
Title Nodemailer before 8.0.3 SMTP Command Injection via envelope.size
First Time appeared Nodemailer
Nodemailer nodemailer
Weaknesses CWE-93
CPEs cpe:2.3:a:nodemailer:nodemailer:*:*:*:*:*:*:*:*
Vendors & Products Nodemailer
Nodemailer nodemailer
References
Metrics cvssV3_1

{'score': 9.8, 'vector': 'CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:H'}

cvssV4_0

{'score': 9.3, 'vector': 'CVSS:4.0/AV:N/AC:L/AT:N/PR:N/UI:N/VC:H/VI:H/VA:H/SC:N/SI:N/SA:N'}


Subscriptions

Nodemailer Nodemailer
cve-icon MITRE

Status: PUBLISHED

Assigner: VulnCheck

Published:

Updated: 2026-08-31T08:46:28.405Z

Reserved: 2026-08-31T08:37:27.053Z

Link: CVE-2026-82854

cve-icon Vulnrichment

No data.

cve-icon NVD

Status : Received

Published: 2026-08-31T09:17:05.463

Modified: 2026-08-31T09:17:05.463

Link: CVE-2026-82854

cve-icon Redhat

No data.

cve-icon OpenCVE Enrichment

Updated: 2026-08-31T10:30:17Z

Weaknesses
  • CWE-93

    Improper Neutralization of CRLF Sequences ('CRLF Injection')