1 |
stephdl |
1.1 |
From 33d8825ecfc68ec49b9647bfd84394e356b3aa9b Mon Sep 17 00:00:00 2001 |
2 |
|
|
From: Hanno Hecker <vetinari@ankh-morp.org> |
3 |
|
|
Date: Wed, 11 Mar 2009 14:18:21 +0800 |
4 |
|
|
Subject: Fix for plugins returning DONE from HELO/EHLO |
5 |
|
|
|
6 |
|
|
We have to return something true, else the client gets an additional |
7 |
|
|
451 Internal error - try again later - command 'helo' failed unexpectedly |
8 |
|
|
after the plugin's ->respond() message. |
9 |
|
|
--- |
10 |
|
|
lib/Qpsmtpd/SMTP.pm | 6 ++++-- |
11 |
|
|
1 files changed, 4 insertions(+), 2 deletions(-) |
12 |
|
|
|
13 |
|
|
diff --git a/lib/Qpsmtpd/SMTP.pm b/lib/Qpsmtpd/SMTP.pm |
14 |
|
|
index 0735f0c..7c126dd 100644 |
15 |
|
|
--- a/lib/Qpsmtpd/SMTP.pm |
16 |
|
|
+++ b/lib/Qpsmtpd/SMTP.pm |
17 |
|
|
@@ -162,7 +162,8 @@ sub helo_respond { |
18 |
|
|
my ($self, $rc, $msg, $args) = @_; |
19 |
|
|
my ($hello_host) = @$args; |
20 |
|
|
if ($rc == DONE) { |
21 |
|
|
- # do nothing |
22 |
|
|
+ # do nothing: |
23 |
|
|
+ 1; |
24 |
|
|
} elsif ($rc == DENY) { |
25 |
|
|
$self->respond(550, @$msg); |
26 |
|
|
} elsif ($rc == DENYSOFT) { |
27 |
|
|
@@ -198,7 +199,8 @@ sub ehlo_respond { |
28 |
|
|
my ($self, $rc, $msg, $args) = @_; |
29 |
|
|
my ($hello_host) = @$args; |
30 |
|
|
if ($rc == DONE) { |
31 |
|
|
- # do nothing |
32 |
|
|
+ # do nothing: |
33 |
|
|
+ 1; |
34 |
|
|
} elsif ($rc == DENY) { |
35 |
|
|
$self->respond(550, @$msg); |
36 |
|
|
} elsif ($rc == DENYSOFT) { |
37 |
|
|
-- |
38 |
|
|
1.7.2.2 |
39 |
|
|
|