Condition Coverage

blib/lib/Mail/SpamAssassin/Plugin/HeaderEval.pm
Criterion Covered Total %
condition 9 165 5.4


and 2 conditions

line l !l condition
871 0 0 defined $pms->{'date_header_time'} and scalar @received_header_times

and 3 conditions

line !l l&&!r l&&r condition
173 0 0 0 $id =~ /\d{5,}/ and /(?:item|invoice|order|number|confirmation).{1,6}\Q$id\E\s*$/
184 0 0 0 $id && !$self->word_is_in_dictionary($id)
285 0 0 0 $illegal > 0 and lc $header eq 'subject:raw'
292 0 0 0 $illegal / length($str) >= $ratio && $illegal >= $count
301 0 0 0 defined $txt and $txt =~ /^contact \S+\@\S+\; run by ezmlm$/
306 0 0 0 $dlto =~ /^mailing list \S+\@\S+/ and $rcvd =~ /qmail \d+ invoked (?:from network|by .{3,20})\); \d+ ... \d+/
350 0 0 0 defined $ip and $ip =~ /$IP_ADDRESS/
351 0 0 0 defined $orig and $orig =~ /$ORIGINATOR/
361 0 0 0 $rcvd =~ /from (?:\S*\.)?hotmail.com \(\S+\.hotmail(?:\.msn)?\.com[ \)]/ and $ip
363 0 0 0 $rcvd =~ /from \S*\.outbound\.protection\.outlook\.com \(\S+\.outbound\.protection\.outlook\.com[ \)]/ and $orig
365 0 0 0 $rcvd =~ /from \S*\.hotmail.com \(\[$IP_ADDRESS\][ \):]/ and $ip
367 0 0 0 $rcvd =~ /from \S+ by \S+\.hotmail(?:\.msn)?\.com with HTTP\;/ and $ip
369 0 0 0 $rcvd =~ /from \[66\.218.\S+\] by \S+\.yahoo\.com/ and $ip
476 0 0 0 defined $ip and $ip =~ /$IP_ADDRESS/
488 0 0 0 $rcvd =~ /by \S*whowhere.com\;/ and $ip
503 0 0 0 $pms->get('Resent-From') ne '' and $pms->get('Resent-To') ne ''
541 0 0 0 $rcvd =~ /\bmailer\d+\.bulk\.scd\.yahoo\.com\b/ and $from =~ /\@reply\.yahoo\.com$/i
602 0 0 0 length $xgms >= 60 and length $xss >= 60
632 77 0 0 ($min eq 'undef' || $pms->{'tocc_similar'} >= $min) && ($max eq 'undef' || $pms->{'tocc_similar'} < $max)
664 76 1 0 scalar @address >= 7 && join(',', @address) eq join(',', sort(@address))
679 572 253 303 $host[$i] eq $host[$j] and $fqhn[$i] ne $fqhn[$j]
709 0 0 0 defined $h1 and defined $h2
0 0 0 defined $h1 and defined $h2 and not $h2 =~ /\./
725 0 0 0 ($min eq 'undef' || $pms->{'date_diff'} >= 3600 * $min) && ($max eq 'undef' || $pms->{'date_diff'} < 3600 * $max)
739 0 0 0 !defined($min) || $min eq 'undef' || $diff >= 31556952 * ($min / 12) and !defined($max) || $max eq 'undef' || $diff < 31556952 * ($max / 12)
757 0 0 0 defined $date and length $date
796 0 0 0 scalar @received and $received[0] =~ /\bby localhost with \w+ \(fetchmail-[\d.]+/
811 0 0 0 defined $time and time >= $time
914 0 0 0 $#diffs > 0 and $diffs[$#diffs] == 0
945 0 0 0 length $subject && $subject eq uc $subject
1030 0 0 0 scalar @hdrs >= $min && scalar @hdrs <= $max
1041 0 0 0 $header =~ /%[A-Z][A-Z_-]/ and not $header =~ /^(?:X-VMS-To|X-UIDL|X-Face|To|Cc|From|Subject|References|In-Reply-To|(?:X-|Resent-|X-Original-)?Message-Id):/i

or 2 conditions

line l !l condition
990 1 0 parse_rfc822_date($_) || 0
997 1 0 parse_rfc822_date($_) || 0

or 3 conditions

line l !l&&r !l&&!r condition
40 0 63 0 ref $class || $class
146 0 0 0 /[-_\.\s]{7,}([-a-z0-9]{4,})$/ or /\s{10,}(?:\S\s)?(\S+)$/
0 0 0 /[-_\.\s]{7,}([-a-z0-9]{4,})$/ or /\s{10,}(?:\S\s)?(\S+)$/ or /\s{3,}[-:\#\(\[]+([-a-z0-9]{4,})[\]\)]+$/
0 0 0 /[-_\.\s]{7,}([-a-z0-9]{4,})$/ or /\s{10,}(?:\S\s)?(\S+)$/ or /\s{3,}[-:\#\(\[]+([-a-z0-9]{4,})[\]\)]+$/ or /\s{3,}[:\#\(\[]*([a-f0-9]{4,})[\]\)]*$/
0 0 0 /[-_\.\s]{7,}([-a-z0-9]{4,})$/ or /\s{10,}(?:\S\s)?(\S+)$/ or /\s{3,}[-:\#\(\[]+([-a-z0-9]{4,})[\]\)]+$/ or /\s{3,}[:\#\(\[]*([a-f0-9]{4,})[\]\)]*$/ or /\s{3,}[-:\#]([a-z0-9]{5,})$/
0 0 0 /[-_\.\s]{7,}([-a-z0-9]{4,})$/ or /\s{10,}(?:\S\s)?(\S+)$/ or /\s{3,}[-:\#\(\[]+([-a-z0-9]{4,})[\]\)]+$/ or /\s{3,}[:\#\(\[]*([a-f0-9]{4,})[\]\)]*$/ or /\s{3,}[-:\#]([a-z0-9]{5,})$/ or /[\s._]{3,}([^0\s._]\d{3,})$/
0 0 0 /[-_\.\s]{7,}([-a-z0-9]{4,})$/ or /\s{10,}(?:\S\s)?(\S+)$/ or /\s{3,}[-:\#\(\[]+([-a-z0-9]{4,})[\]\)]+$/ or /\s{3,}[:\#\(\[]*([a-f0-9]{4,})[\]\)]*$/ or /\s{3,}[-:\#]([a-z0-9]{5,})$/ or /[\s._]{3,}([^0\s._]\d{3,})$/ or /[\s._]{3,}\[(\S+)\]$/
0 0 0 /[-_\.\s]{7,}([-a-z0-9]{4,})$/ or /\s{10,}(?:\S\s)?(\S+)$/ or /\s{3,}[-:\#\(\[]+([-a-z0-9]{4,})[\]\)]+$/ or /\s{3,}[:\#\(\[]*([a-f0-9]{4,})[\]\)]*$/ or /\s{3,}[-:\#]([a-z0-9]{5,})$/ or /[\s._]{3,}([^0\s._]\d{3,})$/ or /[\s._]{3,}\[(\S+)\]$/ or /\(([-\w]{7,}\@\d+)\)$/
0 0 0 /[-_\.\s]{7,}([-a-z0-9]{4,})$/ or /\s{10,}(?:\S\s)?(\S+)$/ or /\s{3,}[-:\#\(\[]+([-a-z0-9]{4,})[\]\)]+$/ or /\s{3,}[:\#\(\[]*([a-f0-9]{4,})[\]\)]*$/ or /\s{3,}[-:\#]([a-z0-9]{5,})$/ or /[\s._]{3,}([^0\s._]\d{3,})$/ or /[\s._]{3,}\[(\S+)\]$/ or /\(([-\w]{7,}\@\d+)\)$/ or /\b(\d{7,})\s*$/
0 0 0 /[-_\.\s]{7,}([-a-z0-9]{4,})$/ or /\s{10,}(?:\S\s)?(\S+)$/ or /\s{3,}[-:\#\(\[]+([-a-z0-9]{4,})[\]\)]+$/ or /\s{3,}[:\#\(\[]*([a-f0-9]{4,})[\]\)]*$/ or /\s{3,}[-:\#]([a-z0-9]{5,})$/ or /[\s._]{3,}([^0\s._]\d{3,})$/ or /[\s._]{3,}\[(\S+)\]$/ or /\(([-\w]{7,}\@\d+)\)$/ or /\b(\d{7,})\s*$/ or /[!\?]\s*(\d{4,}|\w+(-\w+)+)\s*$/
0 0 0 /[-_\.\s]{7,}([-a-z0-9]{4,})$/ or /\s{10,}(?:\S\s)?(\S+)$/ or /\s{3,}[-:\#\(\[]+([-a-z0-9]{4,})[\]\)]+$/ or /\s{3,}[:\#\(\[]*([a-f0-9]{4,})[\]\)]*$/ or /\s{3,}[-:\#]([a-z0-9]{5,})$/ or /[\s._]{3,}([^0\s._]\d{3,})$/ or /[\s._]{3,}\[(\S+)\]$/ or /\(([-\w]{7,}\@\d+)\)$/ or /\b(\d{7,})\s*$/ or /[!\?]\s*(\d{4,}|\w+(-\w+)+)\s*$/ or /(?:\w{2,3}:\s)?\w+\s+(\w{7,}-\w{7,}(-\w+)*)\s*$/
0 0 0 /[-_\.\s]{7,}([-a-z0-9]{4,})$/ or /\s{10,}(?:\S\s)?(\S+)$/ or /\s{3,}[-:\#\(\[]+([-a-z0-9]{4,})[\]\)]+$/ or /\s{3,}[:\#\(\[]*([a-f0-9]{4,})[\]\)]*$/ or /\s{3,}[-:\#]([a-z0-9]{5,})$/ or /[\s._]{3,}([^0\s._]\d{3,})$/ or /[\s._]{3,}\[(\S+)\]$/ or /\(([-\w]{7,}\@\d+)\)$/ or /\b(\d{7,})\s*$/ or /[!\?]\s*(\d{4,}|\w+(-\w+)+)\s*$/ or /(?:\w{2,3}:\s)?\w+\s+(\w{7,}-\w{7,}(-\w+)*)\s*$/ or /\s#\s*([a-f0-9]{4,})\s*$/
240 0 0 0 defined $_ or $! == 0
269 0 0 0 $header eq 'ALL' or $header =~ /:raw$/
271 0 0 0 not defined $str or $str eq ''
521 0 0 0 $pms->{'relays_trusted_str'} =~ / rdns=\S+\.yahoo\.com / or $pms->{'relays_untrusted_str'} =~ /^[^\]]+ rdns=\S+\.yahoo\.com /
567 0 0 0 $rcvd =~ /from.*\b(?:juno|untd)\.com.*[\[\(]${IP_ADDRESS}[\]\)].*by/ or $rcvd =~ / cookie\.(?:juno|untd)\.com /
739 0 0 0 !defined($min) || $min eq 'undef' || $diff >= 31556952 * ($min / 12)
0 0 0 !defined($max) || $max eq 'undef' || $diff < 31556952 * ($max / 12)
791 0 0 0 $received[0] =~ /\bfrom (?:localhost\s|(?:\S+ ){1,2}\S*\b127\.0\.0\.1\b)/ or $received[0] =~ /qmail \d+ invoked by uid \d+/
1069 0 0 0 $from eq '' or $to eq ''