Keep data_post hook, and add data_post_headers
This commit is contained in:
parent
f8c49b6067
commit
bd2f30bdad
@ -12,7 +12,7 @@ our @hooks = qw(
|
||||
logging config user_config post-fork pre-connection connect ehlo_parse ehlo
|
||||
helo_parse helo auth_parse auth auth-plain auth-login auth-cram-md5
|
||||
rcpt_parse rcpt_pre rcpt mail_parse mail mail_pre
|
||||
data data_headers_end data_post data_post_final queue_pre queue queue_post vrfy noop
|
||||
data data_headers_end data_post_headers data_post queue_pre queue queue_post vrfy noop
|
||||
quit reset_transaction disconnect post-connection
|
||||
unrecognized_command deny ok received_line help
|
||||
);
|
||||
|
@ -781,10 +781,10 @@ sub data_respond {
|
||||
return 1;
|
||||
}
|
||||
|
||||
$self->run_hooks("data_post");
|
||||
$self->run_hooks("data_post_headers");
|
||||
$self->authentication_results();
|
||||
$self->received_line();
|
||||
$self->run_hooks("data_post_final");
|
||||
$self->run_hooks("data_post");
|
||||
}
|
||||
|
||||
sub authentication_results {
|
||||
@ -889,7 +889,7 @@ sub received_line {
|
||||
$self->transaction->header->add('Received', $header_str, 0);
|
||||
}
|
||||
|
||||
sub data_post_final_respond {
|
||||
sub data_post_respond {
|
||||
my ($self, $rc, $msg, $args) = @_;
|
||||
if ($rc == DONE) {
|
||||
return 1;
|
||||
|
@ -220,7 +220,7 @@ sub register {
|
||||
|
||||
$self->get_dspam_bin() or return DECLINED;
|
||||
|
||||
$self->register_hook('data_post_final', 'data_post_handler');
|
||||
$self->register_hook('data_post', 'data_post_handler');
|
||||
}
|
||||
|
||||
sub get_dspam_bin {
|
||||
|
@ -164,7 +164,7 @@ sub register {
|
||||
$self->{_args}{reject_type} = 'perm';
|
||||
}
|
||||
|
||||
$self->register_hook('data_post_final', 'data_post_handler');
|
||||
$self->register_hook('data_post', 'data_post_handler');
|
||||
}
|
||||
|
||||
sub data_post_handler {
|
||||
|
Loading…
Reference in New Issue
Block a user