Intel

AIKIDO-2026-608303

symfony/mailer is vulnerable to SMTP Command Injection

Pre-CVE
Found by Aikido Intel before public disclosure or CVE publication.
Published Aug 5, 2026
August 5, 2026

22

CVE Score

Low

SMTP Command Injection

Are you affected? Scan for Free

TL;DR

SmtpTransport stores the value passed to setLocalDomain (the local_domain DSN option) without validation and interpolates it directly into the HELO/EHLO greeting written to the SMTP connection. A local domain that contains carriage return, line feed, or other control characters writes extra lines onto the connection, letting additional SMTP commands be smuggled ahead of the real envelope. Applications that build the local domain from externally influenced data are exposed to SMTP command injection. The fix rejects control characters in setLocalDomain and throws an exception instead of forwarding them.

How do I fix this?

Upgrade the symfony/mailer and/or the symfony/symfony library to the patch version.

Who does this affect?

You are affected if you are using a version that falls within the vulnerable range and your application configures the SMTP local domain (the local_domain DSN option or setLocalDomain()) from externally influenced or user-controlled data.

Versions

4.3.0 - 6.4.42

Fixed in 6.4.43

7.0.0 - 7.4.14

Fixed in 7.4.15

8.0.0 - 8.0.14

Fixed in 8.0.15

8.1.0 - 8.1.1

Fixed in 8.1.2

Background info

symfony/mailer is vulnerable to SMTP Command Injection in versions 4.3.0 - 6.4.42, 7.0.0 - 7.4.14, 8.0.0 - 8.0.14 and 8.1.0 - 8.1.1.

Get secure today,
quickly and for free.

Secure your code, cloud, and runtime in one central system. Connect a repo to discover what the reasoning agents find in your codebase.

No credit card required | Scan results in 32 seconds.

Trusted by 150k+ orgs
  • Revolut
  • n8n
  • Lovable
  • Deel
  • Prove
  • Omnea