From 0e211d73471e57a1ac1bf20fad04e9866a5142c3 Mon Sep 17 00:00:00 2001 From: Art Cancro Date: Mon, 10 Sep 2007 22:14:26 +0000 Subject: [PATCH] For the SSL-only ports, if crypto negotiation fails, drop the session instead of falling back to unencrypted mode. --- citadel/modules/imap/serv_imap.c | 1 + citadel/modules/pop3/serv_pop3.c | 1 + citadel/modules/smtp/serv_smtp.c | 1 + 3 files changed, 3 insertions(+) diff --git a/citadel/modules/imap/serv_imap.c b/citadel/modules/imap/serv_imap.c index ca4acfb6c..1454781aa 100644 --- a/citadel/modules/imap/serv_imap.c +++ b/citadel/modules/imap/serv_imap.c @@ -508,6 +508,7 @@ void imap_greeting(void) */ void imaps_greeting(void) { CtdlModuleStartCryptoMsgs(NULL, NULL, NULL); + if (!CC->redirect_ssl) CC->kill_me = 1; /* kill session if no crypto */ imap_greeting(); } diff --git a/citadel/modules/pop3/serv_pop3.c b/citadel/modules/pop3/serv_pop3.c index 761a4da96..fadb9f50c 100644 --- a/citadel/modules/pop3/serv_pop3.c +++ b/citadel/modules/pop3/serv_pop3.c @@ -98,6 +98,7 @@ void pop3_greeting(void) { */ void pop3s_greeting(void) { CtdlModuleStartCryptoMsgs(NULL, NULL, NULL); + if (!CC->redirect_ssl) CC->kill_me = 1; /* kill session if no crypto */ pop3_greeting(); } diff --git a/citadel/modules/smtp/serv_smtp.c b/citadel/modules/smtp/serv_smtp.c index e6f3c6957..960e105d0 100644 --- a/citadel/modules/smtp/serv_smtp.c +++ b/citadel/modules/smtp/serv_smtp.c @@ -166,6 +166,7 @@ void smtp_greeting(int is_msa) */ void smtps_greeting(void) { CtdlModuleStartCryptoMsgs(NULL, NULL, NULL); + if (!CC->redirect_ssl) CC->kill_me = 1; /* kill session if no crypto */ smtp_greeting(0); } -- 2.30.2