[Bug 6216] New: check_blank_line_ratio does not properly calculate blank lines

View: New views
4 Messages — Rating Filter:   Alert me  

[Bug 6216] New: check_blank_line_ratio does not properly calculate blank lines

by Bugzilla from bugzilla-daemon@bugzilla.spamassassin.org :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

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

           Summary: check_blank_line_ratio does not properly calculate
                    blank lines
           Product: Spamassassin
           Version: SVN Trunk (Latest Devel Version)
          Platform: Other
        OS/Version: All
            Status: NEW
          Severity: enhancement
          Priority: P5
         Component: Rules (Eval Tests)
        AssignedTo: dev@...
        ReportedBy: parkerm@...


The check_blank_line_ration assumes that the return value for
$pms->get_decoded_body_text_array() is an array of lines.  This is incorrect,
it is actually an array of paragraph chunks.  The function needs to be adjusted
to account for the different return value.

This causes hits for BLANK_LINES_* rules (which apparently we only have one of
now) to miss.

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

[Bug 6216] check_blank_line_ratio does not properly calculate blank lines

by Bugzilla from bugzilla-daemon@bugzilla.spamassassin.org :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

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

Mark Martinec <Mark.Martinec@...> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
   Target Milestone|Undefined                   |3.3.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.

[Bug 6216] check_blank_line_ratio does not properly calculate blank lines

by Bugzilla from bugzilla-daemon@bugzilla.spamassassin.org :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

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

Mark Martinec <Mark.Martinec@...> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
           Severity|enhancement                 |normal

--- Comment #1 from Mark Martinec <Mark.Martinec@...> 2009-10-30 12:25:50 UTC ---
> The check_blank_line_ration assumes that the return value for
> $pms->get_decoded_body_text_array() is an array of lines.  This is incorrect,
> it is actually an array of paragraph chunks.  The function needs to be adjusted
> to account for the different return value.
>
> This causes hits for BLANK_LINES_* rules (which apparently we only have one of
> now) to miss.

Considering that the SA::Message::new already compresses multiple blank lines
right during acquisition of a message:

  # also merge multiple blank lines into a single one
  my $start;
  # iterate over lines in reverse order
  for (my $cnt=$#message; $cnt>=0; $cnt--) {
    $message[$cnt] =~ s/\015\012/\012/;
    # line is blank
    if ($message[$cnt] !~ /\S/) {

I wonder what is the check_blank_line_ratio supposed to count anyway?

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

[Bug 6216] check_blank_line_ratio does not properly calculate blank lines

by Bugzilla from bugzilla-daemon@bugzilla.spamassassin.org :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

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

--- Comment #2 from Mark Martinec <Mark.Martinec@...> 2009-10-30 13:19:04 UTC ---
Bug 6216: fix Plugin::BodyEval::check_blank_line_ratio()
Sending        lib/Mail/SpamAssassin/Plugin/BodyEval.pm
Committed revision 831439.


This fixes the reported concern - but does not address the fact
that blank lines have already been squashed.

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