https://issues.apache.org/SpamAssassin/show_bug.cgi?id=5907
Summary: Inaccurate parsing of Received: headers
Product: Spamassassin
Version: 3.2.4
Platform: All
OS/Version: All
Status: NEW
Severity: minor
Priority: P5
Component: Rules (Eval Tests)
AssignedTo: [email protected]
ReportedBy: [EMAIL PROTECTED]
I have 2 messages, they differ slightly:
# diff msg1.eml msg2.eml
4c4
< Received: from host-81-190-40-230.szczecin.mm.pl (HELO [192.168.0.136])
([EMAIL PROTECTED])
---
> Received: from host-81-190-40-230.szczecin.mm.pl (HELO localhost) ([EMAIL
> PROTECTED])
With the first message the address 192.168.0.136 is beeing used as a relay and
evaluated further, while with the second message the address 81.190.40.230 is
beeing considered a relay. IMO this needs fixing.
# spamassassin -D < msg1.eml 2>&1 | grep -i "relay"
[...]
[8770] dbg: received-header: relay 192.168.0.136 trusted? no internal? no msa?
no
[8770] dbg: metadata: X-Spam-Relays-Trusted:
[8770] dbg: metadata: X-Spam-Relays-Untrusted: [ ip=192.168.0.136 rdns=HELO
helo=host-81-190-40-230.szczecin.mm.pl by=smtp.domain.com ident=
[EMAIL PROTECTED] intl=0 id= auth= msa=0 ]
[8770] dbg: metadata: X-Spam-Relays-Internal:
[8770] dbg: metadata: X-Spam-Relays-External: [ ip=192.168.0.136 rdns=HELO
helo=host-81-190-40-230.szczecin.mm.pl by=smtp.domain.com ident=
[EMAIL PROTECTED] intl=0 id= auth= msa=0 ]
[8770] dbg: plugin: Mail::SpamAssassin::Plugin::RelayCountry=HASH(0x8a64348)
implements 'extract_metadata', priority 0
[8770] dbg: metadata: X-Relay-Countries: **
[...]
# spamassassin -D < msg2.eml 2>&1 | grep -i "relay"
[...]
[10511] dbg: received-header: relay 81.190.40.230 trusted? no internal? no msa?
no
[10511] dbg: metadata: X-Spam-Relays-Trusted:
[10511] dbg: metadata: X-Spam-Relays-Untrusted: [ ip=81.190.40.230
rdns=host-81-190-40-230.szczecin.mm.pl helo=localhost by=smtp.domain.com
ident=sender [EMAIL PROTECTED] intl=0 id= auth= msa=0 ]
[10511] dbg: metadata: X-Spam-Relays-Internal:
[10511] dbg: metadata: X-Spam-Relays-External: [ ip=81.190.40.230
rdns=host-81-190-40-230.szczecin.mm.pl helo=localhost by=smtp.domain.com
ident=sender [EMAIL PROTECTED] intl=0 id= auth= msa=0 ]
[10511] dbg: plugin: Mail::SpamAssassin::Plugin::RelayCountry=HASH(0x8a64378)
implements 'extract_metadata', priority 0
[10511] dbg: metadata: X-Relay-Countries: PL
[...]
--
Configure bugmail:
https://issues.apache.org/SpamAssassin/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug.