milter: the sender check keeps two From: and two Sender: values (audit M5)
Security audit 2026-10-17, finding M5 (low), stage 0. senderSession.Header appended every From:/Sender: value; Postfix bounds one header at 60 000 bytes but not their number, and the signer's 1 MiB cap runs after the sender check, so an application could make it hold megabytes per connection (the reader's test: a hundred lines, 6 MB). judge needs only none / one / more, so two of each are kept; the refusal text joins what is kept, as before. Tests: "a hundred From: lines" in the judgement table (refused, more than one From: line); TestSenderKeepsTwoFromAndSenderLines. go test ./internal/milter. Docs: security.md (the sentence "a few headers each"); CHANGELOG; plan. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
@@ -18,6 +18,9 @@ Format follows [Keep a Changelog](https://keepachangelog.com/en/1.1.0/); version
|
||||
removed, so `RCPT TO:<"; from=<x> to=<y> …"@domain>` spelled a second
|
||||
sender and recipient there, and the parser took the first. It now takes
|
||||
Postfix's own tail at the end of the line.
|
||||
- **The sender check keeps two `From:` and two `Sender:` lines** (audit M5),
|
||||
not every one an application sends: the judgement needs no more, and a
|
||||
hundred long lines were megabytes held per connection.
|
||||
- **The entrypoint follows no link at the DMARC maps** (audit I2): the
|
||||
three `dmarc_*` maps root creates at the start were missing from the list
|
||||
of paths where a symbolic link is removed first.
|
||||
|
||||
Reference in New Issue
Block a user