Skip to content
Heist/ feed
MediumFix available

Nodemailer: Quoted local-part can produce malformed envelope recipient through RFC 5322 comment parsing

Type: advisorySource: OSV1 source record

## Summary Nodemailer's address parser can produce an unexpected recipient address when an RFC 5322 comment follows the domain of an address whose local-part is a quoted string. For example: ```text "user"@example.com(x)evil.com ``` is parsed as: ```text { address: "user@example.com evil.com", name: "" } ``` The resulting address therefore contains additional attacker-controlled domain text separated by a literal space. The parsed `.address` value is subsequently propagated into the SMTP envelope: ```text src/addressparser/index.ts ↓ recipient.address ↓ src/mime-node/index.ts ↓ envelope.to ``` The envelope construction uses the parsed address without another strict address validation step. This appears to be a variant of the RFC 5322 comment parsing issue addressed by GHSA-cc9r-2j5m-2m83, but it follows a different parser path when the local-part is quoted. ## Reproduction Input: ```text "user"@example.com(x)evil.com ``` Observed parser output: ```text address: "user@example.com evil.com" name: "" ``` A second example: ```text "a"@b.com(c)d.com(e)f.com ``` produces: ```text address: "a@b.com d.com f.com" name: "" ``` For comparison, the corresponding unquoted form: ```text user@example.com(x)evil.com ``` takes a different code path and is handled by the existing protection differently. ## Technical Details The issue is caused by different parsing behavior for quoted and unquoted local-parts. The quoted-local-part variant allows the comment-separated trailing domain atoms to r

Announced Group revision 1
Original source ↗

GHSA-g57g-f23g-4646

Primary source · Revision 1

Imported from structured advisory data. Source references identify upstream records or fields; verify affected versions and your deployed configuration.

Security context

Source reference: osv:GHSA-g57g-f23g-4646

nodemailer

Source reference: /affected/0/package/name

Affected versions
Not stated in this record
Fixed versions
10.0.9

Source reference: /affected/0/ranges

Prerequisites
Not stated in this record

Structured affected-version data

Original package identities and version rules from this source.

[
  {
    "ranges": [
      {
        "type": "SEMVER",
        "events": [
          {
            "introduced": "9.1.0"
          },
          {
            "fixed": "10.0.9"
          }
        ]
      }
    ],
    "package": {
      "name": "nodemailer",
      "purl": "pkg:npm/nodemailer",
      "ecosystem": "npm"
    },
    "database_specific": {
      "source": "https://github.com/github/advisory-database/blob/main/advisories/github-reviewed/2026/09/GHSA-g57g-f23g-4646/GHSA-g57g-f23g-4646.json"
    }
  }
]
Related CVEs
CVE-2026-100699

Source reference: /aliases

Publisher severity

No explicit severity was provided.

Linked CVE context

These ratings describe the referenced vulnerabilities and products. They are not a severity rating for every application using this dependency.

Event
#33268 · Revision 1
Added to Heist Feed
Publisher date
Read the original announcement