tls: added pass|fail prefix to a couple log msgs

This commit is contained in:
Matt Simerson 2013-04-21 17:03:24 -04:00
parent 7f8848d2e8
commit a14de07280

View File

@ -149,12 +149,16 @@ sub hook_connect {
my ($self, $transaction) = @_; my ($self, $transaction) = @_;
my $local_port = $self->qp->connection->local_port; my $local_port = $self->qp->connection->local_port;
return DECLINED unless defined $local_port && $local_port == 465; # SMTPS if ( ! defined $local_port || $local_port != 465 ) { # SMTPS
$self->log(LOGDEBUG, "skip, not SMTPS");
return DECLINED;
};
unless (_convert_to_ssl($self)) { unless (_convert_to_ssl($self)) {
$self->log(LOGINFO, "fail, unable to establish SSL");
return (DENY_DISCONNECT, "Cannot establish SSL session"); return (DENY_DISCONNECT, "Cannot establish SSL session");
} }
$self->log(LOGWARN, "Connected via SMTPS"); $self->log(LOGINFO, "pass, connect via SMTPS");
return DECLINED; return DECLINED;
} }