Advisory Database
  • Advisories
  • Dependency Scanning
  1. npm
  2. ›
  3. nodemailer
  4. ›
  5. GHSA-g73g-hqqh-jr95

GHSA-g73g-hqqh-jr95: Nodemailer: RFC 5322 comment inside an angle-bracket address is never stripped

October 27, 2026

Nodemailer’s address parser has three published, patched fixes for RFC 5322 comment ( ... ) handling inside an addr-spec: GHSA-cc9r-2j5m-2m83 (comment glued two domain atoms into one), GHSA-g57g-f23g-4646 (the same glue for a quoted local part), and the related ReDoS fixes GHSA-prgh-xp8r-p3m5 / GHSA-v53p-9fqp-m79j. All three fixes live in _handleAddress()’s joins / _recoverAddrSpec() logic in src/addressparser/index.ts, and that logic is exercised whenever the local text-accumulation path in the tokenizer runs.

That logic is never reached at all for the single most common way a recipient is written: a display name followed by an angle-bracket address, Name <local@domain>. When the input inside the angle brackets itself contains an RFC 5322 comment, e.g.

Legit User <user@good-corp.com(x)evil.com>

the comment is not recognized as an operator, is not stripped, and the parenthesis characters survive verbatim inside the parsed address. That value is used as-is for envelope.to and is written raw onto the wire in the RCPT TO SMTP command. I confirmed this end to end:

  • against nodemailer’s own jsonTransport/streamTransport (envelope.to and the emitted To: header both carry the malformed value), and
  • against a real SMTP server (aiosmtpd), where the malformed value is fatal to the transaction (501 Syntax: RCPT TO: <address> [SP <mail-parameters>], all recipients rejected).

This reproduces unmodified on every version I tested from 6.9.16 through the current 10.0.12 HEAD, i.e. it predates and survives all three of the address-parser advisories above unchanged, because it is a different root cause in a code path those fixes never touch.

References

  • github.com/advisories/GHSA-g73g-hqqh-jr95
  • github.com/nodemailer/nodemailer/commit/a502247555fd81773eac337486781f3b6008e16a
  • github.com/nodemailer/nodemailer/releases/tag/v10.0.13
  • github.com/nodemailer/nodemailer/security/advisories/GHSA-g73g-hqqh-jr95

Code Behaviors & Features

Detect and mitigate GHSA-g73g-hqqh-jr95 with GitLab Dependency Scanning

Secure your software supply chain by verifying that all open source dependencies used in your projects contain no disclosed vulnerabilities. Dependency Scanning using SBOM also detects vulnerabilities from proprietary advisories that this site does not include. Learn more about Dependency Scanning using SBOM →

Affected versions

All versions starting from 3.0.0 before 10.0.13

Fixed versions

  • 10.0.13

Solution

Upgrade to version 10.0.13 or above.

Impact 5.3 MEDIUM

CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:L/A:N

Learn more about CVSS

Weakness

  • CWE-20: Improper Input Validation
  • CWE-436: Interpretation Conflict

Source file

npm/nodemailer/GHSA-g73g-hqqh-jr95.yml

Spotted a mistake? Edit the file on GitLab.

  • Site Repo
  • About GitLab
  • Terms
  • Privacy Statement
  • Contact

Page generated Sun, 08 Nov 2026 00:15:51 +0000.