aboutsummaryrefslogtreecommitdiffstats
path: root/sink.c
diff options
context:
space:
mode:
Diffstat (limited to 'sink.c')
-rw-r--r--sink.c12
1 files changed, 12 insertions, 0 deletions
diff --git a/sink.c b/sink.c
index 78630a02..3db9def4 100644
--- a/sink.c
+++ b/sink.c
@@ -539,6 +539,18 @@ static int handle_smtp_report(struct query *ctl, struct msgblk *msg)
free(responses[0]);
return(PS_REFUSED);
+ case 530: /* must issue STARTTLS error */
+ /*
+ * Some SMTP servers insist on encrypted communication
+ * Let's set PS_TRANSIENT, otherwise all messages to be sent
+ * over such server would be blackholed - see RFC 3207.
+ */
+ if (outlevel > O_SILENT)
+ report_complete(stdout,
+ GT_("SMTP server requires STARTTLS, keeping message.\n"));
+ free(responses[0]);
+ return(PS_TRANSIENT);
+
default:
/* bounce non-transient errors back to the sender */
if (smtperr >= 500 && smtperr <= 599)