Login | Register For Free | Help
Search for: (Advanced)

Mailing List Archive: SpamAssassin: devel

[Bug 6780] Existing but empty From: and To:

 

 

SpamAssassin devel RSS feed   Index | Next | Previous | View Threaded


bugzilla-daemon at bugzilla

Mar 31, 2012, 3:56 PM

Post #1 of 4 (210 views)
Permalink
[Bug 6780] Existing but empty From: and To:

https://issues.apache.org/SpamAssassin/show_bug.cgi?id=6780

D. Stussy <software+spamassassin [at] kd6lvw> changed:

What |Removed |Added
----------------------------------------------------------------------------
CC| |software+spamassassin [at] kd6l
| |w.ampr.org

--- Comment #1 from D. Stussy <software+spamassassin [at] kd6lvw> 2012-03-31 22:56:20 UTC ---
If these rules only operate when the header is present, the I suggest the same
with ALL other headers except "Bcc:" - since if present, they may not be empty.

Only BCC is permitted to be empty when present, and except for mail submission
agent processing, is expected ans supposed to be empty if present.

--
Configure bugmail: https://issues.apache.org/SpamAssassin/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug.


bugzilla-daemon at bugzilla

Apr 2, 2012, 3:03 PM

Post #2 of 4 (184 views)
Permalink
[Bug 6780] Existing but empty From: and To: [In reply to]

https://issues.apache.org/SpamAssassin/show_bug.cgi?id=6780

Kevin A. McGrail <kmcgrail [at] pccc> changed:

What |Removed |Added
----------------------------------------------------------------------------
CC| |kmcgrail [at] pccc

--- Comment #2 from Kevin A. McGrail <kmcgrail [at] pccc> 2012-04-02 22:03:15 UTC ---
(In reply to comment #1)
> If these rules only operate when the header is present, the I suggest the same
> with ALL other headers except "Bcc:" - since if present, they may not be empty.
>
> Only BCC is permitted to be empty when present, and except for mail submission
> agent processing, is expected ans supposed to be empty if present.

I agree. I think it needs a meta for !MISSING_HEADERS.

header __EMPTY_FROM From =~ /^\s*$/
header __EMPTY_TO To =~ /^\s*$/
header __EMPTY_CC Cc =~ /^\s*$/

meta EMPTY_TO_AND_FROM (!MISSING_HEADERS && (__EMPTY_FROM + __EMPTY_TO +
__EMPTY_CC >= 2))
describe EMPTY_TO_AND_FROM Mail contains headers that are blank and shouldn't
be.
score EMPTY_TO_AND_FROM 1.0

Lemat, the above passes lint. Does it hit on the emails you are seeing?

regards,
KAM

--
Configure bugmail: https://issues.apache.org/SpamAssassin/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug.


bugzilla-daemon at bugzilla

Apr 3, 2012, 4:57 PM

Post #3 of 4 (181 views)
Permalink
[Bug 6780] Existing but empty From: and To: [In reply to]

https://issues.apache.org/SpamAssassin/show_bug.cgi?id=6780

Lemat <lemat [at] lemat> changed:

What |Removed |Added
----------------------------------------------------------------------------
CC| |lemat [at] lemat

--- Comment #3 from Lemat <lemat [at] lemat> 2012-04-03 23:57:11 UTC ---
Kevin, your rules do match the spamrun I see.

Meanwhile I was also testing something different:

header __HAS_FROM exists:From
header __EMPTY_FROM From =~ /^\s*$/
meta EMPTY_FROM __HAS_FROM && __EMPTY_FROM
describe EMPTY_FROM empty from
score EMPTY_FROM 1

header __HAS_TO exists:To
header __EMPTY_TO To =~ /^\s*$/
meta EMPTY_TO __HAS_TO && __EMPTY_TO
describe EMPTY_TO empty to
score EMPTY_TO 1

and it also did the job. But (I believe) your rule is faster.

--
Configure bugmail: https://issues.apache.org/SpamAssassin/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug.


bugzilla-daemon at bugzilla

Apr 3, 2012, 5:16 PM

Post #4 of 4 (183 views)
Permalink
[Bug 6780] Existing but empty From: and To: [In reply to]

https://issues.apache.org/SpamAssassin/show_bug.cgi?id=6780

--- Comment #4 from Lemat <lemat [at] lemat> 2012-04-04 00:16:34 UTC ---
hmm... MISSING_HEADERS is operating only on To: header:

header MISSING_HEADERS eval:check_for_missing_to_header()

sub check_for_missing_to_header {
my ($self, $pms) = @_;

my $hdr = $pms->get('To');
$hdr = $pms->get('Apparently-To') if $hdr eq '';
return 1 if $hdr eq '';

return 0;
}

which is not exactly identical to what I have been thinking about. And I have
been thinking not about AND but OR, something like that:

header __EMPTY_FROM From =~ /^\s*$/
header __EMPTY_TO To =~ /^\s*$/
header __EMPTY_CC Cc =~ /^\s*$/
header __HAS_FROM exists:From
header __HAS_TO exists:To
header __HAS_CC exists:CC

meta EMPTY_TO_OR_FROM_OR_CC (__HAS_TO && __EMPTY_TO) || (__HAS_FROM &&
__EMPTY_FROM) || (__HAS_CC && __EMPTY_CC)
describe EMPTY_TO_OR_FROM_OR_CC Mail contains headers that are blank and
shouldn't be.
score EMPTY_TO_OR_FROM_OR_CC 1.0

--
Configure bugmail: https://issues.apache.org/SpamAssassin/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug.

SpamAssassin devel RSS feed   Index | Next | Previous | View Threaded
 
 


Interested in having your list archived? Contact Gossamer Threads
 
  Web Applications & Managed Hosting Powered by Gossamer Threads Inc.