badmailfrom rename fixups
This commit is contained in:
parent
7c798e45e6
commit
47488650b3
@ -38,7 +38,7 @@ require_resolvable_fromhost
|
|||||||
|
|
||||||
rhsbl
|
rhsbl
|
||||||
dnsbl
|
dnsbl
|
||||||
check_badmailfrom
|
badmailfrom
|
||||||
check_badrcptto
|
check_badrcptto
|
||||||
check_spamhelo
|
check_spamhelo
|
||||||
|
|
||||||
|
@ -2,18 +2,18 @@
|
|||||||
|
|
||||||
=head1 NAME
|
=head1 NAME
|
||||||
|
|
||||||
check_badmailfromto - checks the badmailfromto config
|
badmailfromto - checks the badmailfromto config
|
||||||
|
|
||||||
=head1 DESCRIPTION
|
=head1 DESCRIPTION
|
||||||
|
|
||||||
Much like the similar check_badmailfrom, this plugin references both the
|
Much like the similar badmailfrom, this plugin references both the
|
||||||
FROM: and TO: lines, and if they both are present in the badmailfromto
|
FROM: and TO: lines, and if they both are present in the badmailfromto
|
||||||
config file (a tab delimited list of FROM/TO pairs), then the message is
|
config file (a tab delimited list of FROM/TO pairs), then the message is
|
||||||
blocked as if the recipient (TO) didn't exist. This is specifically designed
|
blocked as if the recipient (TO) didn't exist. This is specifically designed
|
||||||
to not give the impression that the sender is blocked (good for cases of
|
to not give the impression that the sender is blocked (good for cases of
|
||||||
harassment).
|
harassment).
|
||||||
|
|
||||||
Based heavily on check_badmailfrom.
|
Based heavily on badmailfrom.
|
||||||
|
|
||||||
=cut
|
=cut
|
||||||
|
|
||||||
|
@ -70,25 +70,25 @@ sub test_badmailfrom_match {
|
|||||||
# is_match receives ( $from, $bad, $host )
|
# is_match receives ( $from, $bad, $host )
|
||||||
|
|
||||||
my $r = $self->is_match( 'matt@test.net', 'matt@test.net', 'test.net' );
|
my $r = $self->is_match( 'matt@test.net', 'matt@test.net', 'test.net' );
|
||||||
ok($r, "check_badmailfrom match");
|
ok($r, "match");
|
||||||
|
|
||||||
ok( ! $self->is_match( 'matt@test.net', 'matt@test.com', 'tnpi.net' ),
|
ok( ! $self->is_match( 'matt@test.net', 'matt@test.com', 'tnpi.net' ),
|
||||||
"check_badmailfrom non-match");
|
"non-match");
|
||||||
|
|
||||||
ok( $self->is_match( 'matt@test.net', '@test.net', 'test.net' ),
|
ok( $self->is_match( 'matt@test.net', '@test.net', 'test.net' ),
|
||||||
"check_badmailfrom match host");
|
"match host");
|
||||||
|
|
||||||
ok( ! $self->is_match( 'matt@test.net', '@test.not', 'test.net' ),
|
ok( ! $self->is_match( 'matt@test.net', '@test.not', 'test.net' ),
|
||||||
"check_badmailfrom non-match host");
|
"non-match host");
|
||||||
|
|
||||||
ok( ! $self->is_match( 'matt@test.net', '@test.net', 'test.not' ),
|
ok( ! $self->is_match( 'matt@test.net', '@test.net', 'test.not' ),
|
||||||
"check_badmailfrom non-match host");
|
"non-match host");
|
||||||
|
|
||||||
ok( $self->is_match( 'matt@test.net', 'test.net$', 'tnpi.net' ),
|
ok( $self->is_match( 'matt@test.net', 'test.net$', 'tnpi.net' ),
|
||||||
"check_badmailfrom pattern match");
|
"pattern match");
|
||||||
|
|
||||||
ok( ! $self->is_match( 'matt@test.net', 'test.not$', 'tnpi.net' ),
|
ok( ! $self->is_match( 'matt@test.net', 'test.not$', 'tnpi.net' ),
|
||||||
"check_badmailfrom pattern non-match");
|
"pattern non-match");
|
||||||
};
|
};
|
||||||
|
|
||||||
sub _reset_connection_flags {
|
sub _reset_connection_flags {
|
||||||
|
Loading…
Reference in New Issue
Block a user