Branch Coverage

blib/lib/Mail/Milter/Authentication/Handler/Sanitize.pm
Criterion Covered Total %
branch 30 40 75.0


line true false branch
36 0 32 unless defined $check_hostname
38 32 0 if (exists $config->{'hosts_to_remove'})
40 8 24 if ($check_hostname =~ /^(.*\.)?\Q$remove_hostname\E$/iu)
48 8 16 if ($check_hostname =~ /^(.*\.)?\Q$check_for\E$/iu)
53 2 14 if (fc $check_hostname eq fc $authserv_id)
63 4 14 unless (exists $self->{'remove_auth_headers'}{$type})
110 30 845 if $self->is_trusted_ip_address
111 0 845 if lc $config->{'remove_headers'} eq "no"
114 0 845 if (exists $config->{'extra_auth_results_types'})
120 32 813 if (lc $header eq lc $type)
121 4 28 unless (exists $self->{'auth_result_header_index'}{$type})
132 0 32 if (my $error = $@)
139 32 0 if ($authserv_id) { }
149 18 14 if ($remove)
151 18 0 unless ($silent)
167 837 8 if lc $remove_header ne lc $header
171 0 8 unless ($self->{'header_hash'}{lc $header}{'silent'})
187 0 74 if lc $config->{'remove_headers'} eq "no"
189 74 0 if (exists $self->{'remove_auth_headers'})
200 4 70 if ($max_index)