diff --git a/Changes b/Changes index e492c3c..8b02d84 100644 --- a/Changes +++ b/Changes @@ -1,3 +1,9 @@ +0.31 - + + when disconncting with a temporary failure, return 421 rather than + 450 or 451. (Peter J. Holzer) + + 0.30 - 2005/07/05 Add plugable logging support include sample plugin which replicates diff --git a/lib/Qpsmtpd.pm b/lib/Qpsmtpd.pm index 1ce4fbd..382aea7 100644 --- a/lib/Qpsmtpd.pm +++ b/lib/Qpsmtpd.pm @@ -5,7 +5,7 @@ use vars qw($VERSION $Logger $TraceLevel $Spool_dir); use Sys::Hostname; use Qpsmtpd::Constants; -$VERSION = "0.30"; +$VERSION = "0.31-dev"; sub version { $VERSION }; diff --git a/lib/Qpsmtpd/SMTP.pm b/lib/Qpsmtpd/SMTP.pm index 8aac8d2..f8af97f 100644 --- a/lib/Qpsmtpd/SMTP.pm +++ b/lib/Qpsmtpd/SMTP.pm @@ -272,7 +272,7 @@ sub mail { elsif ($rc == DENYSOFT_DISCONNECT) { $msg ||= $from->format . ', temporarily denied'; $self->log(LOGINFO, "denysoft mail from " . $from->format . " ($msg)"); - $self->respond(450, $msg); + $self->respond(421, $msg); $self->disconnect; } else { # includes OK @@ -316,7 +316,7 @@ sub rcpt { elsif ($rc == DENYSOFT_DISCONNECT) { $msg ||= 'relaying denied'; $self->log(LOGINFO, "delivery denied ($msg)"); - $self->respond(450, $msg); + $self->respond(421, $msg); $self->disconnect; } elsif ($rc == OK) { @@ -413,7 +413,7 @@ sub data { return 1; } elsif ($rc == DENYSOFT_DISCONNECT) { - $self->respond(451, $msg || "Message denied temporarily"); + $self->respond(421, $msg || "Message denied temporarily"); $self->disconnect; return 1; }