summaryrefslogtreecommitdiffstats
path: root/qmail-smtpd.c
diff options
context:
space:
mode:
authormanuel <manuel@mausz.at>2016-03-21 14:05:48 +0100
committermanuel <manuel@mausz.at>2016-03-21 14:05:48 +0100
commit8de6e0db2523d68161799dd5cbaf1d05b7dc40a2 (patch)
treee1d97cbc4ce4b32309e22548f0198c1371e94fa0 /qmail-smtpd.c
parent08723a94ed461a2f5969b21bb4ddb9f887a21d2a (diff)
downloadqmail-8de6e0db2523d68161799dd5cbaf1d05b7dc40a2.tar.gz
qmail-8de6e0db2523d68161799dd5cbaf1d05b7dc40a2.tar.bz2
qmail-8de6e0db2523d68161799dd5cbaf1d05b7dc40a2.zip
don't announce SMTP AUTH commands if not available
Diffstat (limited to 'qmail-smtpd.c')
-rw-r--r--qmail-smtpd.c17
1 files changed, 10 insertions, 7 deletions
diff --git a/qmail-smtpd.c b/qmail-smtpd.c
index 1c462b4..dac1b52 100644
--- a/qmail-smtpd.c
+++ b/qmail-smtpd.c
@@ -577,13 +577,7 @@ void smtp_helo(arg) char *arg;
577 seenmail = 0; dohelo(arg); 577 seenmail = 0; dohelo(arg);
578 if (bhelook) flagbarfbhelo = bmcheck(BMCHECK_BHELO); 578 if (bhelook) flagbarfbhelo = bmcheck(BMCHECK_BHELO);
579} 579}
580void smtp_authout() { 580void smtp_authout();
581#ifdef CRAM_MD5
582 out("250-AUTH LOGIN PLAIN CRAM-MD5\r\n");
583#else
584 out("250-AUTH LOGIN PLAIN\r\n");
585#endif
586}
587/* ESMTP extensions are published here */ 581/* ESMTP extensions are published here */
588void smtp_ehlo(arg) char *arg; 582void smtp_ehlo(arg) char *arg;
589{ 583{
@@ -868,6 +862,15 @@ char ssauth2buf[512];
868substdio ssauth = SUBSTDIO_FDBUF(safewrite,3,ssauthbuf,sizeof(ssauthbuf)); 862substdio ssauth = SUBSTDIO_FDBUF(safewrite,3,ssauthbuf,sizeof(ssauthbuf));
869substdio ssauth2 = SUBSTDIO_FDBUF(saferead,4,ssauth2buf,sizeof(ssauth2buf)); 863substdio ssauth2 = SUBSTDIO_FDBUF(saferead,4,ssauth2buf,sizeof(ssauth2buf));
870 864
865void smtp_authout() {
866 if (!*childargs) return;
867#ifdef CRAM_MD5
868 out("250-AUTH LOGIN PLAIN CRAM-MD5\r\n");
869#else
870 out("250-AUTH LOGIN PLAIN\r\n");
871#endif
872}
873
871int authgetl(void) { 874int authgetl(void) {
872 int i; 875 int i;
873 876