# CVE-2026-23829: Mailpit has SMTP Header Injection via Regex Bypass

- Priority: **Routine**
- Reason: Not severe (CVSS 5.3, network access); no exploitation reported by the 5 checked sources
- Next step: Fix in the normal cadence
- Status: published
- Published: 2026-01-18 · Modified: 2026-01-20
- Aliases: GHSA-54wq-72mp-cq7c, GO-2026-4333
- Record: https://cvemate.com/vulnerability/CVE-2026-23829 · JSON: https://cvemate.com/vulnerability/CVE-2026-23829/json

## Description

```text
Mailpit is an email testing tool and API for developers. Prior to version 1.28.3, Mailpit's SMTP server is vulnerable to Header Injection due to an insufficient Regular Expression used to validate `RCPT TO` and `MAIL FROM` addresses. An attacker can inject arbitrary SMTP headers (or corrupt existing ones) by including carriage return characters (`\r`) in the email address. This header injection occurs because the regex intended to filter control characters fails to exclude `\r` and `\n` when used inside a character class. Version 1.28.3 fixes this issue.
```

## Signals

- CVSS: 5.3 medium (v3.1, CVE.org) CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:L/A:N
- EPSS: 1.402%, percentile 73.499%, as of 2026-12-05
- Known exploited (KEV): CISA not listed, ENISA not listed, CIRCL not listed
- Ransomware use: none recorded
- Public exploits: 1 (github)

## Affected

- axllent mailpit: \< 1.28.3
- github.com/axllent mailpit (Go): \< 1.28.3

## References

- <https://github.com/axllent/mailpit/security/advisories/GHSA-54wq-72mp-cq7c>
- <https://github.com/axllent/mailpit/commit/36cc06c125954dec6673219dafa084e13cc14534>
- <https://github.com/axllent/mailpit/releases/tag/v1.28.3>
- <https://nvd.nist.gov/vuln/detail/CVE-2026-23829>
- <https://github.com/axllent/mailpit>

---

Data as of 2026-12-05T18:29:34.085Z. The priority label is CveMate's own model from public evidence, not an official rating, and it knows nothing about your assets. How labels are decided: https://cvemate.com/faq#priority
