srvrsmtp.c (110560) | srvrsmtp.c (111823) |
---|---|
1/* | 1/* |
2 * Copyright (c) 1998-2002 Sendmail, Inc. and its suppliers. | 2 * Copyright (c) 1998-2003 Sendmail, Inc. and its suppliers. |
3 * All rights reserved. 4 * Copyright (c) 1983, 1995-1997 Eric P. Allman. All rights reserved. 5 * Copyright (c) 1988, 1993 6 * The Regents of the University of California. All rights reserved. 7 * 8 * By using this file, you agree to the terms and conditions set 9 * forth in the LICENSE file which can be found at the top level of 10 * the sendmail distribution. 11 * 12 */ 13 14#include <sendmail.h> 15#if MILTER 16# include <libmilter/mfdef.h> 17#endif /* MILTER */ 18 | 3 * All rights reserved. 4 * Copyright (c) 1983, 1995-1997 Eric P. Allman. All rights reserved. 5 * Copyright (c) 1988, 1993 6 * The Regents of the University of California. All rights reserved. 7 * 8 * By using this file, you agree to the terms and conditions set 9 * forth in the LICENSE file which can be found at the top level of 10 * the sendmail distribution. 11 * 12 */ 13 14#include <sendmail.h> 15#if MILTER 16# include <libmilter/mfdef.h> 17#endif /* MILTER */ 18 |
19SM_RCSID("@(#)$Id: srvrsmtp.c,v 8.829.2.17 2002/12/09 16:46:18 ca Exp $") | 19SM_RCSID("@(#)$Id: srvrsmtp.c,v 8.829.2.21 2003/01/15 19:17:14 ca Exp $") |
20 21#if SASL || STARTTLS 22# include <sys/time.h> 23# include "sfsasl.h" 24#endif /* SASL || STARTTLS */ 25#if SASL 26# define ENC64LEN(l) (((l) + 2) * 4 / 3 + 1) 27static int saslmechs __P((sasl_conn_t *, char **)); --- 1602 unchanged lines hidden (view full) --- 1630 FD_SET(rfd, &ssl_maskx); 1631 if (select(wfd + 1, NULL, &ssl_maskw, 1632 &ssl_maskx, &tv) > 0) 1633 goto ssl_retry; 1634 } 1635 if (LogLevel > 5) 1636 { 1637 sm_syslog(LOG_WARNING, NOQID, | 20 21#if SASL || STARTTLS 22# include <sys/time.h> 23# include "sfsasl.h" 24#endif /* SASL || STARTTLS */ 25#if SASL 26# define ENC64LEN(l) (((l) + 2) * 4 / 3 + 1) 27static int saslmechs __P((sasl_conn_t *, char **)); --- 1602 unchanged lines hidden (view full) --- 1630 FD_SET(rfd, &ssl_maskx); 1631 if (select(wfd + 1, NULL, &ssl_maskw, 1632 &ssl_maskx, &tv) > 0) 1633 goto ssl_retry; 1634 } 1635 if (LogLevel > 5) 1636 { 1637 sm_syslog(LOG_WARNING, NOQID, |
1638 "STARTTLS=server, error: accept failed=%d, SSL_error=%d, timedout=%d", 1639 r, i, (int) timedout); | 1638 "STARTTLS=server, error: accept failed=%d, SSL_error=%d, timedout=%d, errno=%d", 1639 r, i, (int) timedout, errno); |
1640 if (LogLevel > 8) 1641 tlslogerr("server"); 1642 } 1643tlsfail: 1644 tls_ok_srv = false; 1645 SSL_free(srv_ssl); 1646 srv_ssl = NULL; 1647 --- 1064 unchanged lines hidden (view full) --- 2712 if (LogLevel > 5) 2713 sm_syslog(LOG_INFO, e->e_id, 2714 "%s: ETRN %s", CurSmtpClient, 2715 shortenstring(p, MAXSHORTSTR)); 2716 2717 id = p; 2718 if (*id == '#') 2719 { | 1640 if (LogLevel > 8) 1641 tlslogerr("server"); 1642 } 1643tlsfail: 1644 tls_ok_srv = false; 1645 SSL_free(srv_ssl); 1646 srv_ssl = NULL; 1647 --- 1064 unchanged lines hidden (view full) --- 2712 if (LogLevel > 5) 2713 sm_syslog(LOG_INFO, e->e_id, 2714 "%s: ETRN %s", CurSmtpClient, 2715 shortenstring(p, MAXSHORTSTR)); 2716 2717 id = p; 2718 if (*id == '#') 2719 { |
2720 int wgrp; | 2720 int i, qgrp; |
2721 2722 id++; | 2721 2722 id++; |
2723 wgrp = name2qid(id); 2724 if (!ISVALIDQGRP(wgrp)) | 2723 qgrp = name2qid(id); 2724 if (!ISVALIDQGRP(qgrp)) |
2725 { 2726 usrerr("459 4.5.4 Queue %s unknown", 2727 id); 2728 break; 2729 } | 2725 { 2726 usrerr("459 4.5.4 Queue %s unknown", 2727 id); 2728 break; 2729 } |
2730 ok = run_work_group(wgrp, RWG_FORK|RWG_RUNALL); | 2730 for (i = 0; i < NumQueue && Queue[i] != NULL; 2731 i++) 2732 Queue[i]->qg_nextrun = (time_t) -1; 2733 Queue[qgrp]->qg_nextrun = 0; 2734 ok = run_work_group(Queue[qgrp]->qg_wgrp, 2735 RWG_FORK|RWG_FORCE); |
2731 if (ok && Errors == 0) 2732 message("250 2.0.0 Queuing for queue group %s started", id); 2733 break; 2734 } 2735 2736 if (*id == '@') 2737 id++; 2738 else --- 1575 unchanged lines hidden --- | 2736 if (ok && Errors == 0) 2737 message("250 2.0.0 Queuing for queue group %s started", id); 2738 break; 2739 } 2740 2741 if (*id == '@') 2742 id++; 2743 else --- 1575 unchanged lines hidden --- |