diff options
author | gshapiro <gshapiro@FreeBSD.org> | 2011-06-14 04:20:18 +0000 |
---|---|---|
committer | gshapiro <gshapiro@FreeBSD.org> | 2011-06-14 04:20:18 +0000 |
commit | b73afeb2a402ad777e43387c907da53a40696c88 (patch) | |
tree | 76ab24e8fa418fcd903ec416f76b86ad8e8725ff /contrib | |
parent | b8dcfe0228713cd46d96c831843ee6c8bbcb84e3 (diff) | |
parent | 8601cea5b1f7986bb1bf047627c2e1c4169d2655 (diff) | |
download | FreeBSD-src-b73afeb2a402ad777e43387c907da53a40696c88.zip FreeBSD-src-b73afeb2a402ad777e43387c907da53a40696c88.tar.gz |
Merge sendmail 8.14.5 to HEAD
MFC after: 4 days
Diffstat (limited to 'contrib')
43 files changed, 880 insertions, 398 deletions
diff --git a/contrib/sendmail/CACerts b/contrib/sendmail/CACerts index dee2819..245148d 100644 --- a/contrib/sendmail/CACerts +++ b/contrib/sendmail/CACerts @@ -1,4 +1,4 @@ -# $Id: CACerts,v 8.4 2009/06/26 05:46:10 ca Exp $ +# $Id: CACerts,v 8.5 2011/05/06 23:05:10 ca Exp $ # This file contains some CA certificates that are used to sign the # certificates of mail servers of members of the sendmail consortium # who may reply to questions etc sent to sendmail.org. @@ -9,73 +9,6 @@ Certificate: Data: Version: 3 (0x2) - Serial Number: 0 (0x0) - Signature Algorithm: md5WithRSAEncryption - Issuer: C=US, ST=Illinois, L=De Kalb, O=Northern Illinois University, OU=Computer Science, CN=Neil Rickert/emailAddress=rickert@cs.niu.edu - Validity - Not Before: May 12 00:40:50 2000 GMT - Not After : May 20 00:40:50 2010 GMT - Subject: C=US, ST=Illinois, L=De Kalb, O=Northern Illinois University, OU=Computer Science, CN=Neil Rickert/emailAddress=rickert@cs.niu.edu - Subject Public Key Info: - Public Key Algorithm: rsaEncryption - RSA Public Key: (1024 bit) - Modulus (1024 bit): - 00:b1:1b:49:06:ef:3f:44:e0:93:ad:8c:a7:f7:21: - 7c:87:cb:da:35:f6:4b:a2:fd:8a:a0:07:5b:cc:6a: - 9b:89:33:fc:24:f5:b1:24:59:5a:25:50:fd:16:d7: - d4:bc:c7:04:1d:df:90:9b:5e:c3:a8:e9:8b:7d:a3: - 5d:9a:e9:7f:e5:2b:ea:15:a7:ad:ba:58:26:0a:11: - 49:4f:da:9a:67:7f:b0:a6:66:f4:27:b6:61:4e:3c: - c8:3e:a0:2f:6a:b4:0e:15:d6:39:f8:92:60:85:df: - a6:34:f3:fa:a4:a5:e4:47:49:e7:87:a4:a5:5c:8e: - 6a:2f:13:76:5f:29:f3:64:73 - Exponent: 65537 (0x10001) - X509v3 extensions: - X509v3 Subject Key Identifier: - B6:31:78:BB:7E:AA:4D:A1:5D:FD:A2:24:18:C6:90:5A:2D:2F:19:48 - X509v3 Authority Key Identifier: - keyid:B6:31:78:BB:7E:AA:4D:A1:5D:FD:A2:24:18:C6:90:5A:2D:2F:19:48 - DirName:/C=US/ST=Illinois/L=De Kalb/O=Northern Illinois University/OU=Computer Science/CN=Neil Rickert/emailAddress=rickert@cs.niu.edu - serial:00 - - X509v3 Basic Constraints: - CA:TRUE - Signature Algorithm: md5WithRSAEncryption - 60:69:23:65:97:51:5c:06:a4:42:cb:00:e7:9a:dc:39:70:c3: - d3:5d:bf:0f:e0:04:54:4d:d9:dc:12:57:12:6c:67:fd:5b:b0: - 39:63:ea:c4:12:65:51:bb:3d:f1:f7:25:b4:cd:0b:f6:5b:7a: - 61:25:ad:06:0a:01:55:dc:71:05:29:0d:73:e9:30:51:be:d3: - e1:b2:89:fc:0f:28:f7:06:75:96:1b:34:75:e0:07:e5:3b:b3: - 0b:28:24:e5:79:ea:55:39:e7:d2:ee:ec:63:b4:e4:c6:ee:cb: - 15:d0:c8:eb:3b:4f:36:10:a4:6a:c0:6b:03:e8:29:72:c7:a7: - 10:00 ------BEGIN CERTIFICATE----- -MIID5TCCA06gAwIBAgIBADANBgkqhkiG9w0BAQQFADCBrjELMAkGA1UEBhMCVVMx -ETAPBgNVBAgTCElsbGlub2lzMRAwDgYD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-AQEEBQADgYEAYGkjZZdRXAakQssA55rcOXDD012/D+AEVE3Z3BJXEmxn/VuwOWPq -xBJlUbs98fcltM0L9lt6YSWtBgoBVdxxBSkNc+kwUb7T4bKJ/A8o9wZ1lhs0deAH -5TuzCygk5XnqVTnn0u7sY7Tkxu7LFdDI6ztPNhCkasBrA+gpcsenEAA= ------END CERTIFICATE----- - -Certificate: - Data: - Version: 3 (0x2) Serial Number: c2:3c:61:67:3b:0a:cc:5e Signature Algorithm: md5WithRSAEncryption diff --git a/contrib/sendmail/KNOWNBUGS b/contrib/sendmail/KNOWNBUGS index 998fb11..5b7918c 100644 --- a/contrib/sendmail/KNOWNBUGS +++ b/contrib/sendmail/KNOWNBUGS @@ -12,6 +12,14 @@ distribution). This list is not guaranteed to be complete. +* Header values which are too long may be truncated. + + If a value of a structured header is longer than 256 (MAXNAME) + characters then it may be truncated during output. For example, + if a single address in the To: header is longer than 256 characters + then it will be truncated which may result in a syntactically + invalid address. + * Delivery to programs that generate too much output may cause problems If e-mail is delivered to a program which generates too much @@ -258,4 +266,4 @@ Kresolve sequence dnsmx canon be used if set instead of LOCAL_RELAY ($R). This will be fixed in a future version. -$Revision: 8.60 $, Last updated $Date: 2007/12/04 01:16:50 $ +$Revision: 8.61 $, Last updated $Date: 2011/04/07 17:48:23 $ diff --git a/contrib/sendmail/LICENSE b/contrib/sendmail/LICENSE index 2c60403..a0ad124 100644 --- a/contrib/sendmail/LICENSE +++ b/contrib/sendmail/LICENSE @@ -1,8 +1,9 @@ SENDMAIL LICENSE -The following license terms and conditions apply, unless a different -license is obtained from Sendmail, Inc., 6475 Christie Ave, Suite 350, -Emeryville, CA 94608, USA, or by electronic mail at license@sendmail.com. +The following license terms and conditions apply, unless a redistribution +agreement or other license is obtained from Sendmail, Inc., 6475 Christie +Ave, Third Floor, Emeryville, CA 94608, USA, or by electronic mail at +license@sendmail.com. License Terms: @@ -22,10 +23,11 @@ each of the following conditions is met: must allow further use, modification, and redistribution of the Source Code under substantially the same terms as this license. For the purposes of redistribution "Source Code" means the complete compilable - and linkable source code of sendmail including all modifications. + and linkable source code of sendmail and associated libraries and + utilities in the sendmail distribution including all modifications. -2. Redistributions of source code must retain the copyright notices as they - appear in each source code file, these license terms, and the +2. Redistributions of Source Code must retain the copyright notices as they + appear in each Source Code file, these license terms, and the disclaimer/limitation of liability set forth as paragraph 6 below. 3. Redistributions in binary form must reproduce the Copyright Notice, @@ -33,16 +35,16 @@ each of the following conditions is met: forth as paragraph 6 below, in the documentation and/or other materials provided with the distribution. For the purposes of binary distribution the "Copyright Notice" refers to the following language: - "Copyright (c) 1998-2009 Sendmail, Inc. All rights reserved." + "Copyright (c) 1998-2010 Sendmail, Inc. All rights reserved." 4. Neither the name of Sendmail, Inc. nor the University of California nor - the names of their contributors may be used to endorse or promote + names of their contributors may be used to endorse or promote products derived from this software without specific prior written permission. The name "sendmail" is a trademark of Sendmail, Inc. 5. All redistributions must comply with the conditions imposed by the - University of California on certain embedded code, whose copyright - notice and conditions for redistribution are as follows: + University of California on certain embedded code, which copyright + Notice and conditions for redistribution are as follows: (a) Copyright (c) 1988, 1993 The Regents of the University of California. All rights reserved. @@ -76,4 +78,4 @@ each of the following conditions is met: (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGES. -$Revision: 8.15 $, Last updated $Date: 2009/03/04 19:58:04 $ +$Revision: 8.17 $, Last updated $Date: 2010/12/03 01:10:00 $, Document 139848.1 diff --git a/contrib/sendmail/PGPKEYS b/contrib/sendmail/PGPKEYS index 5f89ed4..fd6daf8 100644 --- a/contrib/sendmail/PGPKEYS +++ b/contrib/sendmail/PGPKEYS @@ -142,6 +142,223 @@ gpExpdV7qPrw9k01j5rod5PjZlG8zV0= -----END PGP PUBLIC KEY BLOCK----- Type Bits KeyID Created Expires Algorithm Use +pub 2048 A97884B0 2011-01-04 ------- RSA Sign & Encrypt +fingerprint: 5872 6218 A913 400D E660 3601 39A4 C77D A978 84B0 +uid Sendmail Signing Key/2011 <sendmail@Sendmail.ORG> + +-----BEGIN PGP PUBLIC KEY BLOCK----- +Version: GnuPG v1.4.9 (OpenBSD) + +mQENBE0ios4BCAC0mjr+Fljl/LRvhI3sI29bM146dWJFr+oJVTHuafDuKQS5ICeU +89LewVL6Pjp8RureijfbqZC51Z2v5v6GxAizr/LlD9FohjQXiAaA1vgPChBdzvLg +4TzEVnQOGFuDUnuucQH82I7ysQkK7z1GpFkofKHHgwmcfFpOiRLoUR7YVP7yDpfv +Zx3EPvRoFtR22kWlhms49J7zgRpXUCH9ggrtcl1QCXkPOlZ+VspUPrZaZEZy8RTA +3W5l0yhnGVgnJHBfOo2svFurukQ7LAU4U6yCG5AFogcD3sgEvuFAkmWBJZ2rnOBn +yCL658zfAJlmrni8kLQp6yBuEsUrT6jdRgRBABEBAAG0MVNlbmRtYWlsIFNpZ25p +bmcgS2V5LzIwMTEgPHNlbmRtYWlsQFNlbmRtYWlsLk9SRz6JATkEEwECACMFAk0i +os4CGwMHCwkIBwMCAQYVCAIJCgsEFgIDAQIeAQIXgAAKCRA5pMd9qXiEsHIXB/0S +PFGPpoJzQqcEUHZ8w21mJOhoB6eO3GYRXBBLODQbu3x5qMXgTXT2fZgsSO5zkKBD +QCm4lMns+cJCds1+ggAZLywNM1SUvctXJYIaHnSLEnEbxIgRMM+HdULlJn3xgT6w +HUVZhzjamXOLospz5BfIXx9NynvjxvjcZ/NI8Cas1WFPvP+89fT+VCzLw0eC1bAo +puv2CA384i7pqeCvw13taksA0QnpHeN9c2xjWA6LTbLBrDLoTkfxvas0H9WzgNTF +DpzSuIHyDFonrkSvdgyOCIUYWJ0qkzDYnJzaOd7ku+4YjcF1bw5FhbvXAvcBY8OA +Ilr9WaR2TGj7//OylOjNiQEcBBABAgAGBQJNIqNLAAoJEGBN+/KFQQq+gDEH/i7x +aOd7L+QV5rIYyujJdirVoO/9s1+YJkKmFAKltUPcj8v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B9O845HrHAPmQ +=pDAG +-----END PGP PUBLIC KEY BLOCK----- + +Type Bits KeyID Created Expires Algorithm Use +pub 2048 85410ABE 2010-02-19 ------- RSA Sign +fingerprint: B175 9644 5303 5DCE DD7B E919 604D FBF2 8541 0ABE +uid Sendmail Signing Key/2010 <sendmail@Sendmail.ORG> + +-----BEGIN PGP PUBLIC KEY BLOCK----- +Version: GnuPG v1.4.9 (OpenBSD) + +mQENBEt+6goBCAC95sVPzf4AWFmUklHO9yGBq6K135Tlt9JaX3frj6PCBjkLNn97 +J5WDAoLqE9wB7WgiBzs2lu8OPZZcf+6syd97SojEze5bj2uv84DBv2juupbHEBys +9OH52QqYWG+1yuwAHY2gjKLYcvNgaOKLp5hoHZ2rakRc4a2ypLTPazsGFBO9/qBA ++v6qkP70/lOZeN9HX/yipbygAE+Y9elptW6ohvdGW8jbtllFqYFebB+lIaclkQnK +pldnQfktnJDB+XmLOc5m/1BsultlI5IH9HXCeskXxLcxXq+ldg+it1DgzxmHpHTK +dIhgOKY3MvTgxkcXiwIGcHBMnov6ESL1KaU5ABEBAAG0MVNlbmRtYWlsIFNpZ25p +bmcgS2V5LzIwMTAgPHNlbmRtYWlsQFNlbmRtYWlsLk9SRz6JATkEEwECACMFAkt+ +6goCGwMHCwkIBwMCAQYVCAIJCgsEFgIDAQIeAQIXgAAKCRBgTfvyhUEKvi4qB/0T +Em3whttGoUrxdZd1gYKI9SY1/4dHOhD+xJQQgIoQSRpOEA7xQ6TTAYvG8sYdsF5K +9/lWjOTEy5w6wBcu4e9F7aO/TUzue/7p0c2UKJTrEOw4HsRrENfQHx1TAXudQHHn +5+PgBCQCSr36ktuSXnlOo2bGbZ4FUwNCu0ztmoEEca8ZgY6ciEXbva1kRj6Eumul +MkqtVYEAtjzdIga6M3xYuJlus+qi/uEj5kivtf2LUDxXpGE6XFrArum0za/URiW8 +wxt5zBbTbne3tDr2yg6GC046+f1Wr02xWYapGyNRU6yrPciWOu0tpaxJ7CwEIMRq +6HzbSVd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B/5PTy67pX+AC1JgvPPafUMu +=6Xeh +-----END PGP PUBLIC KEY BLOCK----- + +Type Bits KeyID Created Expires Algorithm Use pub 1024 0xA77F2429 2009-01-01 ---------- RSA Sign & Encrypt f16 Fingerprint16 = 33 3A 62 61 2C F3 21 AA 4E 87 47 F2 2F 2C 40 4D uid Sendmail Signing Key/2009 <sendmail@Sendmail.ORG> @@ -1865,4 +2082,4 @@ DnF3FZZEzV7oqPwC2jzv/1dD6GFhtgy0cnyoPGUJCyc= =nES8 -----END PGP PUBLIC KEY BLOCK----- -$Revision: 8.29 $, Last updated $Date: 2009/01/06 05:59:03 $ +$Revision: 8.36 $, Last updated $Date: 2011/01/28 21:17:54 $ diff --git a/contrib/sendmail/RELEASE_NOTES b/contrib/sendmail/RELEASE_NOTES index 4e1e8f3..f96f8cf 100644 --- a/contrib/sendmail/RELEASE_NOTES +++ b/contrib/sendmail/RELEASE_NOTES @@ -1,11 +1,75 @@ SENDMAIL RELEASE NOTES - $Id: RELEASE_NOTES,v 8.1963 2009/12/23 04:43:46 ca Exp $ + $Id: RELEASE_NOTES,v 8.1991 2011/05/15 04:28:16 ca Exp $ This listing shows the version of the sendmail binary, the version of the sendmail configuration files, the date of release, and a summary of the changes in that release. +8.14.5/8.14.5 2011/05/17 + Do not cache SMTP extensions across connections as the cache + is based on hostname which may not be a unique identifier + for a server, i.e., different machines may have the + same hostname but provide different SMTP extensions. + Problem noted by Jim Hermann. + Avoid an out-of-bounds access in case a resolver reply for a DNS + map lookup returns a size larger than 1K. Based on a + patch from Dr. Werner Fink of SuSE. + If a job is aborted using the interrupt signal (e.g., control-C from + the keyboard), perform minimal cleanup to avoid invoking + functions that are not signal-safe. Note: in previous + versions the mail might have been queued up already + and would be delivered subsequently, now an interrupt + will always remove the queue files and thus prevent + delivery. + Per RFC 6176, when operating as a TLS client, do not offer SSLv2. + Since TLS session resumption is never used as a client, disable + use of RFC 4507-style session tickets. + Work around gcc4 versions which reverse 25 years of history and + no longer align char buffers on the stack, breaking calls + to resolver functions on strict alignment platforms. + Found by Stuart Henderson of OpenBSD. + Read at most two AUTH lines from a server greeting (up to two + lines are read because servers may use "AUTH mechs" and + "AUTH=mechs"). Otherwise a malicious server may exhaust + the memory of the client. Bug report by Nils of MWR + InfoSecurity. + Avoid triggering an assertion in the OpenLDAP code when the + connection to an LDAP server is lost while making a query. + Problem noted and patch provided by Andy Fiddaman. + If ConnectOnlyTo is set and sendmail is compiled with NETINET6 + it would try to use an IPv6 address if an IPv4 (or + unparseable) address is specified. + If SASLv2 is used, make sure that the macro {auth_authen} is + stored in xtext format to avoid problems with parsing + it. Problem noted by Christophe Wolfhugel. + CONFIG: FEATURE(`ldap_routing') in 8.14.4 tried to add a missing + -T<TMPF> that is required, but failed for some cases + that did not use LDAP. This change has been undone + until a better solution can be implemented. Problem + found by Andy Fiddaman. + CONFIG: Add cf/ostype/solaris11.m4 for Solaris11 support. + Contributed by Casper Dik of Oracle. + CONTRIB: qtool.pl: Deal with H entries that do not have a + letter between the question marks. Patch from + Stefan Christensen. + DOC: Use a better description for the -i option in sendmail. + Patch from Mitchell Berger. + Portability: + Add support for Darwin 10.x (Mac OS X 10.6). + Enable HAVE_NANOSLEEP for FreeBSD 3 and later. Patch + from John Marshall. + Enable HAVE_NANOSLEEP for OpenBSD 4.3 and later. + Use new directory "/system/volatile" for PidFile on + Solaris 11. Patch from Casper Dik of Oracle. + Fix compilation on Solaris 11 (and maybe some other + OSs) when using OpenSSL 1.0. Based on patch from + Jan Pechanec of Oracle. + Set SOCKADDR_LEN_T and SOCKOPT_LEN_T to socklen_t + for Solaris 11. Patch from Roger Faulkner of Oracle. + New Files: + cf/ostype/solaris11.m4 + 8.14.4/8.14.4 2009/12/30 SECURITY: Handle bogus certificates containing NUL characters in CNs by placing a string indicating a bad certificate diff --git a/contrib/sendmail/cf/cf/submit.cf b/contrib/sendmail/cf/cf/submit.cf index 5286c68..6cc386a 100644 --- a/contrib/sendmail/cf/cf/submit.cf +++ b/contrib/sendmail/cf/cf/submit.cf @@ -1,5 +1,5 @@ # -# Copyright (c) 1998-2004, 2009 Sendmail, Inc. and its suppliers. +# Copyright (c) 1998-2004, 2009, 2010 Sendmail, Inc. and its suppliers. # All rights reserved. # Copyright (c) 1983, 1995 Eric P. Allman. All rights reserved. # Copyright (c) 1988, 1993 @@ -16,8 +16,8 @@ ##### ##### SENDMAIL CONFIGURATION FILE ##### -##### built by ca@wiz.smi.sendmail.com on Tue Dec 22 20:49:09 PST 2009 -##### in /extra/home/ca/sm-8.14.4/OpenSource/sendmail-8.14.4/cf/cf +##### built by ca@wiz.smi.sendmail.com on Sat May 14 21:31:14 PDT 2011 +##### in /extra/home/ca/sm-8.14.5/OpenSource/sendmail-8.14.5/cf/cf ##### using ../ as configuration include directory ##### ###################################################################### @@ -27,7 +27,7 @@ ###################################################################### ###################################################################### -##### $Id: cfhead.m4,v 8.120 2009/01/23 22:39:21 ca Exp $ ##### +##### $Id: cfhead.m4,v 8.121 2010/01/07 18:20:19 ca Exp $ ##### ##### $Id: cf.m4,v 8.32 1999/02/07 07:26:14 gshapiro Exp $ ##### ##### $Id: submit.mc,v 8.14 2006/04/05 05:54:41 ca Exp $ ##### ##### $Id: msp.m4,v 1.33 2004/02/09 22:32:38 ca Exp $ ##### @@ -35,7 +35,7 @@ ##### $Id: no_default_msa.m4,v 8.2 2001/02/14 05:03:22 gshapiro Exp $ ##### -##### $Id: proto.m4,v 8.741 2009/12/11 00:04:53 ca Exp $ ##### +##### $Id: proto.m4,v 8.744 2010/11/23 20:29:47 guenther Exp $ ##### # level 10 config file format V10/Berkeley @@ -114,7 +114,7 @@ D{MTAHost}[127.0.0.1] # Configuration version number -DZ8.14.4/Submit +DZ8.14.5/Submit ############### @@ -992,7 +992,6 @@ R< $* > $* $: $2 - ###################################################################### ### check_mail -- check SMTP `MAIL FROM:' command argument ###################################################################### diff --git a/contrib/sendmail/cf/feature/ldap_routing.m4 b/contrib/sendmail/cf/feature/ldap_routing.m4 index 227060c..e9b4880 100644 --- a/contrib/sendmail/cf/feature/ldap_routing.m4 +++ b/contrib/sendmail/cf/feature/ldap_routing.m4 @@ -1,6 +1,6 @@ divert(-1) # -# Copyright (c) 1999-2002, 2004, 2007, 2009 Sendmail, Inc. and its suppliers. +# Copyright (c) 1999-2002, 2004, 2007 Sendmail, Inc. and its suppliers. # All rights reserved. # # By using this file, you agree to the terms and conditions set @@ -10,7 +10,7 @@ divert(-1) # divert(0) -VERSIONID(`$Id: ldap_routing.m4,v 8.17 2009/06/26 21:11:08 ca Exp $') +VERSIONID(`$Id: ldap_routing.m4,v 8.18 2010/01/05 00:57:27 ca Exp $') divert(-1) # Check first two arguments. If they aren't set, may need to warn in proto.m4 @@ -35,40 +35,12 @@ ifelse(len(X`'_ARG6_), `1', `define(`_LDAP_ROUTE_MAPTEMP_', `_QUEUE_')', _ARG6_, `tempfail', `define(`_LDAP_ROUTE_MAPTEMP_', `_TEMPFAIL_')', _ARG6_, `queue', `define(`_LDAP_ROUTE_MAPTEMP_', `_QUEUE_')') -define(`_ATMPF_', `<TMPF>')dnl -dnl check whether arg contains -T`'_ATMPF_ -dnl unless it is a sequence map or just LDAP -dnl note: this does not work if ARG1 begins with space(s), however, as -dnl we issue a warning, hopefully the user will fix it... -ifelse(defn(`_ARG1_'), `', `', - defn(`_ARG1_'), `LDAP', `', - `ifelse(index(_ARG1_, `sequence '), `0', `', - `ifelse(index(_ARG1_, _ATMPF_), `-1', - `errprint(`*** WARNING: missing -T'_ATMPF_` in first argument of FEATURE(`ldap_routing') -') - define(`_ABP_', index(_ARG1_, ` ')) - define(`_NARG1_', `substr(_ARG1_, 0, _ABP_) -T'_ATMPF_` substr(_ARG1_, _ABP_)') - ') - ') - ') -ifelse(defn(`_ARG2_'), `', `', - defn(`_ARG2_'), `LDAP', `', - `ifelse(index(_ARG2_, `sequence '), `0', `', - `ifelse(index(_ARG2_, _ATMPF_), `-1', - `errprint(`*** WARNING: missing -T'_ATMPF_` in second argument of FEATURE(`ldap_routing') -') - define(`_ABP_', index(_ARG2_, ` ')) - define(`_NARG2_', `substr(_ARG2_, 0, _ABP_) -T'_ATMPF_` substr(_ARG2_, _ABP_)') - ') - ') - ') - LOCAL_CONFIG # LDAP routing maps Kldapmh ifelse(len(X`'_ARG1_), `1', `ldap -1 -T<TMPF> -v mailHost -k (&(objectClass=inetLocalMailRecipient)(mailLocalAddress=%0))', - defn(`_NARG1_'), `', `_ARG1_', `_NARG1_') + `_ARG1_') Kldapmra ifelse(len(X`'_ARG2_), `1', `ldap -1 -T<TMPF> -v mailRoutingAddress -k (&(objectClass=inetLocalMailRecipient)(mailLocalAddress=%0))', - defn(`_NARG2_'), `', `_ARG2_', `_NARG2_') + `_ARG2_') diff --git a/contrib/sendmail/cf/m4/cfhead.m4 b/contrib/sendmail/cf/m4/cfhead.m4 index c2d0df7..fbb9476 100644 --- a/contrib/sendmail/cf/m4/cfhead.m4 +++ b/contrib/sendmail/cf/m4/cfhead.m4 @@ -1,5 +1,5 @@ # -# Copyright (c) 1998-2004, 2009 Sendmail, Inc. and its suppliers. +# Copyright (c) 1998-2004, 2009, 2010 Sendmail, Inc. and its suppliers. # All rights reserved. # Copyright (c) 1983, 1995 Eric P. Allman. All rights reserved. # Copyright (c) 1988, 1993 @@ -189,6 +189,7 @@ SLocal_tls_server') define(`LOCAL_RULE_3', `divert(2)') define(`LOCAL_CONFIG', `divert(6)') define(`MAILER_DEFINITIONS', `divert(7)') +define(`LOCAL_DNSBL', `divert(8)') define(`LOCAL_NET_CONFIG', `define(`_LOCAL_RULES_', 1)divert(1)') define(`UUCPSMTP', `R DOL(*) < @ $1 .UUCP > DOL(*) DOL(1) < @ $2 > DOL(2)') define(`CONCAT', `$1$2$3$4$5$6$7') @@ -308,4 +309,4 @@ define(`confMILTER_MACROS_EOM', `{msg_id}') divert(0)dnl -VERSIONID(`$Id: cfhead.m4,v 8.120 2009/01/23 22:39:21 ca Exp $') +VERSIONID(`$Id: cfhead.m4,v 8.121 2010/01/07 18:20:19 ca Exp $') diff --git a/contrib/sendmail/cf/m4/proto.m4 b/contrib/sendmail/cf/m4/proto.m4 index c021581..8bfd9de 100644 --- a/contrib/sendmail/cf/m4/proto.m4 +++ b/contrib/sendmail/cf/m4/proto.m4 @@ -1,6 +1,6 @@ divert(-1) # -# Copyright (c) 1998-2009 Sendmail, Inc. and its suppliers. +# Copyright (c) 1998-2010 Sendmail, Inc. and its suppliers. # All rights reserved. # Copyright (c) 1983, 1995 Eric P. Allman. All rights reserved. # Copyright (c) 1988, 1993 @@ -13,10 +13,10 @@ divert(-1) # divert(0) -VERSIONID(`$Id: proto.m4,v 8.741 2009/12/11 00:04:53 ca Exp $') +VERSIONID(`$Id: proto.m4,v 8.744 2010/11/23 20:29:47 guenther Exp $') # level CF_LEVEL config file format -V`'CF_LEVEL/ifdef(`VENDOR_NAME', `VENDOR_NAME', `Berkeley') +V`'CF_LEVEL`'ifdef(`NO_VENDOR',`', `/ifdef(`VENDOR_NAME', `VENDOR_NAME', `Berkeley')') divert(-1) dnl if MAILER(`local') not defined: do it ourself; be nice @@ -1795,7 +1795,7 @@ ifdef(`_CONN_CONTROL_',`dnl ifdef(`_CONN_CONTROL_IMMEDIATE_',`',`dnl dnl workspace: ignored... R$* $: $>"ConnControl" dummy')', `dnl') -undivert(8) +undivert(8)dnl LOCAL_DNSBL ifdef(`_REQUIRE_RDNS_', `dnl R$* $: $&{client_addr} $| $&{client_resolve} R$=R $* $@ RELAY We relay for these diff --git a/contrib/sendmail/cf/m4/version.m4 b/contrib/sendmail/cf/m4/version.m4 index 5ad5ffb..566c3a5 100644 --- a/contrib/sendmail/cf/m4/version.m4 +++ b/contrib/sendmail/cf/m4/version.m4 @@ -1,6 +1,6 @@ divert(-1) # -# Copyright (c) 1998-2009 Sendmail, Inc. and its suppliers. +# Copyright (c) 1998-2011 Sendmail, Inc. and its suppliers. # All rights reserved. # Copyright (c) 1983 Eric P. Allman. All rights reserved. # Copyright (c) 1988, 1993 @@ -11,8 +11,8 @@ divert(-1) # the sendmail distribution. # # -VERSIONID(`$Id: version.m4,v 8.205 2009/12/23 04:43:09 ca Exp $') +VERSIONID(`$Id: version.m4,v 8.214 2011/04/26 23:02:36 ca Exp $') # divert(0) # Configuration version number -DZ8.14.4`'ifdef(`confCF_VERSION', `/confCF_VERSION') +DZ8.14.5`'ifdef(`confCF_VERSION', `/confCF_VERSION') diff --git a/contrib/sendmail/cf/ostype/solaris11.m4 b/contrib/sendmail/cf/ostype/solaris11.m4 new file mode 100644 index 0000000..a48b077 --- /dev/null +++ b/contrib/sendmail/cf/ostype/solaris11.m4 @@ -0,0 +1,22 @@ +divert(-1) +# +# Copyright (c) 2011 Sendmail, Inc. and its suppliers. +# All rights reserved. +# +# By using this file, you agree to the terms and conditions set +# forth in the LICENSE file which can be found at the top level of +# the sendmail distribution. +# +# This ostype file is suitable for use on Solaris 11 and later systems, +# make use of /system/volatile, introduced in Solaris 11. +# + +divert(0) +VERSIONID(`$Id: solaris11.m4,v 1.1 2011/01/24 21:22:08 ca Exp $') +divert(-1) + +ifdef(`UUCP_MAILER_ARGS',, `define(`UUCP_MAILER_ARGS', `uux - -r -a$g $h!rmail ($u)')') +define(`confEBINDIR', `/usr/lib')dnl +define(`confPID_FILE', `/system/volatile/sendmail.pid')dnl +define(`_NETINET6_')dnl +FEATURE(`local_lmtp')dnl diff --git a/contrib/sendmail/contrib/qtool.pl b/contrib/sendmail/contrib/qtool.pl index f2d33c2..c2a67f8 100755 --- a/contrib/sendmail/contrib/qtool.pl +++ b/contrib/sendmail/contrib/qtool.pl @@ -3,7 +3,7 @@ ## Copyright (c) 1998-2002 Sendmail, Inc. and its suppliers. ## All rights reserved. ## -## $Id: qtool.pl,v 8.30 2009/03/04 16:57:30 ca Exp $ +## $Id: qtool.pl,v 8.31 2010/11/10 19:11:54 ca Exp $ ## use strict; use File::Basename; @@ -607,7 +607,7 @@ sub parse_header $first_char = substr($line, 0, 1); if ($first_char eq "?") { - $line = substr($line, 3); + $line = (split(/\?/, $line,3))[2]; } elsif ($first_char eq "\t") { diff --git a/contrib/sendmail/doc/op/op.me b/contrib/sendmail/doc/op/op.me index be07810..1e7d370 100644 --- a/contrib/sendmail/doc/op/op.me +++ b/contrib/sendmail/doc/op/op.me @@ -9,7 +9,7 @@ .\" the sendmail distribution. .\" .\" -.\" $Id: op.me,v 8.745 2009/12/13 04:12:46 ca Exp $ +.\" $Id: op.me,v 8.747 2010/05/08 04:18:27 ca Exp $ .\" .\" eqn op.me | pic | troff -me .\" @@ -90,7 +90,7 @@ Sendmail, Inc. .de Ve Version \\$2 .. -.Ve $Revision: 8.745 $ +.Ve $Revision: 8.747 $ .rm Ve .sp For Sendmail Version 8.14 @@ -1095,6 +1095,9 @@ The number of envelope recipients for this message (after aliasing and forwarding). .ip msgid The message id of the message (from the header). +.ip bodytype +The message body type (7BIT or 8BITMIME), +as determined from the envelope. .ip proto The protocol used to receive this message (e.g., ESMTP or UUCP) .ip daemon @@ -5154,7 +5157,8 @@ FAIL cert presented but could not be verified, e.g., the signing CA is missing. NONE STARTTLS has not been performed. TEMP temporary error occurred. -PROTOCOL some protocol error occurred. +PROTOCOL some protocol error occurred + at the ESMTP level (not TLS). SOFTWARE STARTTLS handshake failed, which is a fatal error for this session, the e-mail will be queued. @@ -11463,7 +11467,7 @@ replace it with a blank sheet for double-sided output. .\".sz 10 .\"Eric Allman .\".sp -.\"Version $Revision: 8.745 $ +.\"Version $Revision: 8.747 $ .\".ce 0 .bp 3 .ce diff --git a/contrib/sendmail/include/sm/conf.h b/contrib/sendmail/include/sm/conf.h index 5b18754..b47a5f8 100644 --- a/contrib/sendmail/include/sm/conf.h +++ b/contrib/sendmail/include/sm/conf.h @@ -1,5 +1,5 @@ /* - * Copyright (c) 1998-2009 Sendmail, Inc. and its suppliers. + * Copyright (c) 1998-2011 Sendmail, Inc. and its suppliers. * All rights reserved. * Copyright (c) 1983, 1995-1997 Eric P. Allman. All rights reserved. * Copyright (c) 1988, 1993 @@ -10,7 +10,7 @@ * the sendmail distribution. * * - * $Id: conf.h,v 1.139 2009/06/16 23:41:32 ca Exp $ + * $Id: conf.h,v 1.144 2011/05/03 16:24:00 ca Exp $ */ /* @@ -381,6 +381,12 @@ typedef int pid_t; # ifndef __svr4__ # define __svr4__ /* use all System V Release 4 defines below */ # endif /* ! __svr4__ */ +# if SOLARIS >= 21100 +# include <paths.h> +# endif /* SOLARIS >= 21100 */ +# ifndef _PATH_VARRUN +# define _PATH_VARRUN "/var/run/" +# endif /* _PATH_VARRUN */ # define GIDSET_T gid_t # define USE_SA_SIGACTION 1 /* use sa_sigaction field */ # define BROKEN_PTHREAD_SLEEP 1 /* sleep after pthread_create() fails */ @@ -443,7 +449,7 @@ typedef int pid_t; # endif /* SOLARIS >= 20700 || (SOLARIS < 10000 && SOLARIS >= 207) */ # if SOLARIS >= 20800 || (SOLARIS < 10000 && SOLARIS >= 208) # undef _PATH_SENDMAILPID /* tmpfs /var/run added in 2.8 */ -# define _PATH_SENDMAILPID "/var/run/sendmail.pid" +# define _PATH_SENDMAILPID _PATH_VARRUN "sendmail.pid" # ifndef SMRSH_CMDDIR # define SMRSH_CMDDIR "/var/adm/sm.bin" # endif /* ! SMRSH_CMDDIR */ @@ -461,6 +467,8 @@ typedef int pid_t; # if SOLARIS >= 21100 || (SOLARIS < 10000 && SOLARIS >= 211) # define GETLDAPALIASBYNAME_VERSION 2 /* changed in S11 */ # define HAVE_NANOSLEEP 1 /* moved from librt to libc in S11 */ +# define SOCKADDR_LEN_T socklen_t /* arg#3 to accept, getsockname */ +# define SOCKOPT_LEN_T socklen_t /* arg#5 to getsockopt */ # endif /* SOLARIS >= 21100 || (SOLARIS < 10000 && SOLARIS >= 211) */ # ifndef HASGETUSERSHELL # define HASGETUSERSHELL 0 /* getusershell(3) causes core dumps pre-2.7 */ @@ -1014,6 +1022,9 @@ extern unsigned int sleepX __P((unsigned int seconds)); # if __FreeBSD_version >= 222000 /* 2.2.2-release and later */ # define HASSETUSERCONTEXT 1 /* BSDI-style login classes */ # endif /* __FreeBSD_version >= 222000 */ +# if __FreeBSD_version >= 300000 /* 3.0.0-release and later */ +# define HAVE_NANOSLEEP 1 /* has nanosleep(2) */ +# endif /* __FreeBSD_version >= 300000 */ # if __FreeBSD_version >= 330000 /* 3.3.0-release and later */ # ifndef SMRSH_CMDDIR # define SMRSH_CMDDIR "/usr/libexec/sm.bin" @@ -1055,6 +1066,9 @@ extern unsigned int sleepX __P((unsigned int seconds)); # if OpenBSD >= 200505 # undef NETISO /* iso.h removed in 3.7 */ # endif /* OpenBSD >= 200505 */ +# if OpenBSD >= 200800 +# define HAVE_NANOSLEEP 1 /* has nanosleep(2) */ +# endif /* OpenBSD >= 200800 */ # endif /* defined(__OpenBSD__) */ # endif /* defined(__DragonFly__) || defined(__FreeBSD__) || defined(__NetBSD__) || defined(__OpenBSD__) */ @@ -2808,7 +2822,7 @@ struct utsname # if _FFR_LINUX_MHNL && defined(__linux__) && MAXHOSTNAMELEN < 255 /* - ** override Linux wierdness: a FQHN can be 255 chars long + ** override Linux weirdness: a FQHN can be 255 chars long ** SUSv3 requires HOST_NAME_MAX ("Maximum length of a host ** name (not including the terminating null) as returned from the ** gethostname() function.") to be at least 255. c.f.: diff --git a/contrib/sendmail/libmilter/docs/overview.html b/contrib/sendmail/libmilter/docs/overview.html index 5c6f21c..d6e3bba 100644 --- a/contrib/sendmail/libmilter/docs/overview.html +++ b/contrib/sendmail/libmilter/docs/overview.html @@ -4,7 +4,7 @@ </HEAD> <BODY> <!-- -$Id: overview.html,v 1.20 2009/11/13 18:15:05 ca Exp $ +$Id: overview.html,v 1.21 2010/12/14 20:59:52 ca Exp $ --> <H1>Technical Overview</H1> @@ -126,7 +126,7 @@ messages may be sent in a single connection. Note also that a message or connection may be aborted by either the remote host or the MTA at any point during the SMTP transaction. -f this occurs during a message (between the MAIL command and the final "."), +If this occurs during a message (between the MAIL command and the final "."), the filter's <A HREF="xxfi_abort.html">xxfi_abort</A> routine will be called. <A HREF="xxfi_close.html">xxfi_close</A> is called any time the diff --git a/contrib/sendmail/libmilter/docs/smfi_stop.html b/contrib/sendmail/libmilter/docs/smfi_stop.html index 87ecdb2..5d25882 100644 --- a/contrib/sendmail/libmilter/docs/smfi_stop.html +++ b/contrib/sendmail/libmilter/docs/smfi_stop.html @@ -2,7 +2,7 @@ <HEAD><TITLE>smfi_stop</TITLE></HEAD> <BODY> <!-- -$Id: smfi_stop.html,v 1.6 2006/12/21 18:30:35 ca Exp $ +$Id: smfi_stop.html,v 1.7 2010/12/13 16:16:01 ca Exp $ --> <H1>smfi_stop</H1> @@ -42,7 +42,7 @@ which may then exit or warm-restart. <TABLE border="1" cellspacing=0> <TR bgcolor="#dddddd"><TH>Argument</TH><TH>Description</TH></TR> <TR valign="top"><TD>void</TD> - <TD>Takes no arguement. + <TD>Takes no argument. </TD></TR> </TABLE> </TD></TR> diff --git a/contrib/sendmail/libmilter/docs/xxfi_envrcpt.html b/contrib/sendmail/libmilter/docs/xxfi_envrcpt.html index 9fb4ce8..67a8cf5 100644 --- a/contrib/sendmail/libmilter/docs/xxfi_envrcpt.html +++ b/contrib/sendmail/libmilter/docs/xxfi_envrcpt.html @@ -2,7 +2,7 @@ <HEAD><TITLE>xxfi_envrcpt</TITLE></HEAD> <BODY> <!-- -$Id: xxfi_envrcpt.html,v 1.15 2007/01/25 01:00:20 ca Exp $ +$Id: xxfi_envrcpt.html,v 1.16 2010/07/14 04:41:03 ca Exp $ --> <H1>xxfi_envrcpt</H1> @@ -71,7 +71,8 @@ Handle the envelope RCPT command. </TR> <TR valign="top"> <TD>SMFIS_ACCEPT</TD> - <TD>Accept recipient. <A href="xxfi_abort.html">xxfi_abort</A> will not be called. + <TD>Accept this message. + <A href="xxfi_abort.html">xxfi_abort</A> will not be called. </TD> </TR> </TABLE> @@ -87,7 +88,7 @@ Handle the envelope RCPT command. <HR size="1"> <FONT size="-1"> -Copyright (c) 2000, 2003 Sendmail, Inc. and its suppliers. +Copyright (c) 2000, 2003, 2010 Sendmail, Inc. and its suppliers. All rights reserved. <BR> By using this file, you agree to the terms and conditions set diff --git a/contrib/sendmail/libmilter/engine.c b/contrib/sendmail/libmilter/engine.c index a2d3e1e..92c8e6d 100644 --- a/contrib/sendmail/libmilter/engine.c +++ b/contrib/sendmail/libmilter/engine.c @@ -9,7 +9,7 @@ */ #include <sm/gen.h> -SM_RCSID("@(#)$Id: engine.c,v 8.166 2009/11/06 00:57:07 ca Exp $") +SM_RCSID("@(#)$Id: engine.c,v 8.167 2011/03/03 06:09:15 ca Exp $") #include "libmilter.h" @@ -284,7 +284,7 @@ mi_engine(ctx) if (mi_stop() == MILTER_ABRT) { if (ctx->ctx_dbg > 3) - sm_dprintf("[%ld] milter_abort\n", + sm_dprintf("[%lu] milter_abort\n", (long) ctx->ctx_id); ret = MI_FAILURE; break; @@ -315,7 +315,7 @@ mi_engine(ctx) cmd < SMFIC_VALIDCMD) { if (ctx->ctx_dbg > 5) - sm_dprintf("[%ld] mi_engine: mi_rd_cmd error (%x)\n", + sm_dprintf("[%lu] mi_engine: mi_rd_cmd error (%x)\n", (long) ctx->ctx_id, (int) cmd); /* @@ -328,7 +328,7 @@ mi_engine(ctx) break; } if (ctx->ctx_dbg > 4) - sm_dprintf("[%ld] got cmd '%c' len %d\n", + sm_dprintf("[%lu] got cmd '%c' len %d\n", (long) ctx->ctx_id, cmd, (int) len); for (i = 0; i < ncmds; i++) { @@ -339,7 +339,7 @@ mi_engine(ctx) { /* unknown command */ if (ctx->ctx_dbg > 1) - sm_dprintf("[%ld] cmd '%c' unknown\n", + sm_dprintf("[%lu] cmd '%c' unknown\n", (long) ctx->ctx_id, cmd); ret = MI_FAILURE; break; @@ -348,7 +348,7 @@ mi_engine(ctx) { /* stop for now */ if (ctx->ctx_dbg > 1) - sm_dprintf("[%ld] cmd '%c' not impl\n", + sm_dprintf("[%lu] cmd '%c' not impl\n", (long) ctx->ctx_id, cmd); ret = MI_FAILURE; break; @@ -357,14 +357,14 @@ mi_engine(ctx) /* is new state ok? */ newstate = cmds[i].cm_next; if (ctx->ctx_dbg > 5) - sm_dprintf("[%ld] cur %x new %x nextmask %x\n", + sm_dprintf("[%lu] cur %x new %x nextmask %x\n", (long) ctx->ctx_id, curstate, newstate, next_states[curstate]); if (newstate != ST_NONE && !trans_ok(curstate, newstate)) { if (ctx->ctx_dbg > 1) - sm_dprintf("[%ld] abort: cur %d (%x) new %d (%x) next %x\n", + sm_dprintf("[%lu] abort: cur %d (%x) new %d (%x) next %x\n", (long) ctx->ctx_id, curstate, MI_MASK(curstate), newstate, MI_MASK(newstate), @@ -434,7 +434,7 @@ mi_engine(ctx) else if (r == _SMFIS_ABORT) { if (ctx->ctx_dbg > 5) - sm_dprintf("[%ld] function returned abort\n", + sm_dprintf("[%lu] function returned abort\n", (long) ctx->ctx_id); ret = MI_FAILURE; break; @@ -1122,7 +1122,7 @@ st_optionneg(g) fix_stm(ctx); if (ctx->ctx_dbg > 3) - sm_dprintf("[%ld] milter_negotiate:" + sm_dprintf("[%lu] milter_negotiate:" " mta_actions=0x%lx, mta_flags=0x%lx" " actions=0x%lx, flags=0x%lx\n" , (long) ctx->ctx_id @@ -1131,7 +1131,7 @@ st_optionneg(g) #if _FFR_MILTER_CHECK if (ctx->ctx_dbg > 3) - sm_dprintf("[%ld] milter_negotiate:" + sm_dprintf("[%lu] milter_negotiate:" " testmode=%d, pflags2mta=%X, internal_pflags=%X\n" , (long) ctx->ctx_id, testmode , ctx->ctx_pflags2mta, internal_pflags); diff --git a/contrib/sendmail/libmilter/sm_gethost.c b/contrib/sendmail/libmilter/sm_gethost.c index 5706b89..8f2b339 100644 --- a/contrib/sendmail/libmilter/sm_gethost.c +++ b/contrib/sendmail/libmilter/sm_gethost.c @@ -1,5 +1,5 @@ /* - * Copyright (c) 1999-2001, 2004 Sendmail, Inc. and its suppliers. + * Copyright (c) 1999-2001, 2004, 2010 Sendmail, Inc. and its suppliers. * All rights reserved. * * By using this file, you agree to the terms and conditions set @@ -9,7 +9,7 @@ */ #include <sm/gen.h> -SM_RCSID("@(#)$Id: sm_gethost.c,v 8.27 2004/08/20 21:12:37 ca Exp $") +SM_RCSID("@(#)$Id: sm_gethost.c,v 8.29 2010/07/27 01:09:31 ca Exp $") #include <sendmail.h> #if NETINET || NETINET6 @@ -30,7 +30,7 @@ SM_RCSID("@(#)$Id: sm_gethost.c,v 8.27 2004/08/20 21:12:37 ca Exp $") #if NETINET6 && NEEDSGETIPNODE -static struct hostent *getipnodebyname __P((char *, int, int, int *)); +static struct hostent *sm_getipnodebyname __P((const char *, int, int, int *)); # ifndef AI_ADDRCONFIG # define AI_ADDRCONFIG 0 /* dummy */ @@ -43,8 +43,8 @@ static struct hostent *getipnodebyname __P((char *, int, int, int *)); # endif /* ! AI_DEFAULT */ static struct hostent * -getipnodebyname(name, family, flags, err) - char *name; +sm_getipnodebyname(name, family, flags, err) + const char *name; int family; int flags; int *err; @@ -77,6 +77,8 @@ freehostent(h) return; } +#else /* NEEDSGETIPNODE && NETINET6 */ +#define sm_getipnodebyname getipnodebyname #endif /* NEEDSGETIPNODE && NETINET6 */ struct hostent * @@ -107,7 +109,7 @@ mi_gethostbyname(name, family) # if ADDRCONFIG_IS_BROKEN flags &= ~AI_ADDRCONFIG; # endif /* ADDRCONFIG_IS_BROKEN */ - h = getipnodebyname(name, family, flags, &err); + h = sm_getipnodebyname(name, family, flags, &err); SM_SET_H_ERRNO(err); # else /* NETINET6 */ h = gethostbyname(name); diff --git a/contrib/sendmail/libmilter/worker.c b/contrib/sendmail/libmilter/worker.c index 28d404f..aa1bd57 100644 --- a/contrib/sendmail/libmilter/worker.c +++ b/contrib/sendmail/libmilter/worker.c @@ -1,5 +1,5 @@ /* - * Copyright (c) 2003-2004, 2007, 2009 Sendmail, Inc. and its suppliers. + * Copyright (c) 2003-2004, 2007, 2009-2011 Sendmail, Inc. and its suppliers. * All rights reserved. * * By using this file, you agree to the terms and conditions set @@ -11,7 +11,7 @@ */ #include <sm/gen.h> -SM_RCSID("@(#)$Id: worker.c,v 8.17 2009/06/15 15:34:54 ca Exp $") +SM_RCSID("@(#)$Id: worker.c,v 8.19 2011/02/14 23:33:48 ca Exp $") #include "libmilter.h" @@ -165,7 +165,9 @@ mi_start_session(ctx) { static long id = 0; - SM_ASSERT(Tskmgr.tm_signature == TM_SIGNATURE); + /* this can happen if the milter is shutting down */ + if (Tskmgr.tm_signature != TM_SIGNATURE) + return MI_FAILURE; SM_ASSERT(ctx != NULL); POOL_LEV_DPRINTF(4, ("PIPE r=[%d] w=[%d]", RD_PIPE, WR_PIPE)); TASKMGR_LOCK(); @@ -216,6 +218,41 @@ mi_close_session(ctx) } /* +** NONBLOCKING -- set nonblocking mode for a file descriptor. +** +** Parameters: +** fd -- file descriptor +** name -- name for (error) logging +** +** Returns: +** MI_SUCCESS/MI_FAILURE +*/ + +static int +nonblocking(int fd, const char *name) +{ + int r; + + errno = 0; + r = fcntl(fd, F_GETFL, 0); + if (r == -1) + { + smi_log(SMI_LOG_ERR, "fcntl(%s, F_GETFL)=%s", + name, sm_errstring(errno)); + return MI_FAILURE; + } + errno = 0; + r = fcntl(fd, F_SETFL, r | O_NONBLOCK); + if (r == -1) + { + smi_log(SMI_LOG_ERR, "fcntl(%s, F_SETFL, O_NONBLOCK)=%s", + name, sm_errstring(errno)); + return MI_FAILURE; + } + return MI_SUCCESS; +} + +/* ** MI_POOL_CONTROLER_INIT -- Launch the worker pool controller ** Must be called before starting sessions. ** @@ -246,6 +283,12 @@ mi_pool_controller_init() sm_errstring(errno)); return MI_FAILURE; } + r = nonblocking(WR_PIPE, "WR_PIPE"); + if (r != MI_SUCCESS) + return r; + r = nonblocking(RD_PIPE, "RD_PIPE"); + if (r != MI_SUCCESS) + return r; (void) smutex_init(&Tskmgr.tm_w_mutex); (void) scond_init(&Tskmgr.tm_w_cond); @@ -495,25 +538,23 @@ mi_pool_controller(arg) /* has a worker signaled an end of task ? */ if (WAIT_FD(i) == RD_PIPE) { - char evt = 0; - int r = 0; + char evts[256]; + ssize_t r; POOL_LEV_DPRINTF(4, ("PIPE WILL READ evt = %08X %08X", pfd[i].events, pfd[i].revents)); - if ((pfd[i].revents & MI_POLL_RD_FLAGS) != 0) + r = 1; + while ((pfd[i].revents & MI_POLL_RD_FLAGS) != 0 + && r != -1) { - r = read(RD_PIPE, &evt, sizeof(evt)); - if (r == sizeof(evt)) - { - /* Do nothing */ - } + r = read(RD_PIPE, evts, sizeof(evts)); } POOL_LEV_DPRINTF(4, ("PIPE DONE READ i=[%d] fd=[%d] r=[%d] evt=[%d]", - i, RD_PIPE, r, evt)); + i, RD_PIPE, (int) r, evts[0])); if ((pfd[i].revents & ~MI_POLL_RD_FLAGS) != 0) { diff --git a/contrib/sendmail/libsm/ldap.c b/contrib/sendmail/libsm/ldap.c index 7ee57fc..9ae233f 100644 --- a/contrib/sendmail/libsm/ldap.c +++ b/contrib/sendmail/libsm/ldap.c @@ -11,7 +11,7 @@ #define LDAP_DEPRECATED 1 #include <sm/gen.h> -SM_RCSID("@(#)$Id: ldap.c,v 1.83 2009/06/19 22:02:26 guenther Exp $") +SM_RCSID("@(#)$Id: ldap.c,v 1.85 2011/04/18 22:20:20 ca Exp $") #if LDAPMAP # include <sys/types.h> @@ -1098,10 +1098,8 @@ sm_ldap_results(lmap, msgid, flags, delim, rpool, result, if (ret == 0) save_errno = ETIMEDOUT; - else + else if (ret == LDAP_RES_SEARCH_RESULT) { - int rc; - /* ** We may have gotten an LDAP_RES_SEARCH_RESULT response ** with an error inside it, so we have to extract that @@ -1109,11 +1107,21 @@ sm_ldap_results(lmap, msgid, flags, delim, rpool, result, ** to an LDAP proxy whose backend has gone down. */ - save_errno = ldap_parse_result(lmap->ldap_ld, lmap->ldap_res, - &rc, NULL, NULL, NULL, NULL, 0); - if (save_errno == LDAP_SUCCESS) - save_errno = rc; + if (lmap->ldap_res == NULL) + save_errno = LDAP_UNAVAILABLE; + else + { + int rc; + + save_errno = ldap_parse_result(lmap->ldap_ld, + lmap->ldap_res, &rc, NULL, NULL, + NULL, NULL, 0); + if (save_errno == LDAP_SUCCESS) + save_errno = rc; + } } + else + save_errno = sm_ldap_geterrno(lmap->ldap_ld); if (save_errno != LDAP_SUCCESS) { statp = EX_TEMPFAIL; diff --git a/contrib/sendmail/makemap/makemap.c b/contrib/sendmail/makemap/makemap.c index cacec00..f06ed07 100644 --- a/contrib/sendmail/makemap/makemap.c +++ b/contrib/sendmail/makemap/makemap.c @@ -20,7 +20,7 @@ SM_IDSTR(copyright, Copyright (c) 1992, 1993\n\ The Regents of the University of California. All rights reserved.\n") -SM_IDSTR(id, "@(#)$Id: makemap.c,v 8.179 2008/04/14 02:06:16 ca Exp $") +SM_IDSTR(id, "@(#)$Id: makemap.c,v 8.180 2010/11/23 02:35:08 gshapiro Exp $") #include <sys/types.h> @@ -238,7 +238,7 @@ main(argc, argv) if ((cfp = sm_io_open(SmFtStdio, SM_TIME_DEFAULT, cfile, SM_IO_RDONLY, NULL)) == NULL) { - sm_io_fprintf(smioerr, SM_TIME_DEFAULT, "makemap: %s: %s", + sm_io_fprintf(smioerr, SM_TIME_DEFAULT, "makemap: %s: %s\n", cfile, sm_errstring(errno)); exit(EX_NOINPUT); } diff --git a/contrib/sendmail/src/Makefile.m4 b/contrib/sendmail/src/Makefile.m4 index 0fa3374..7bcd24d 100644 --- a/contrib/sendmail/src/Makefile.m4 +++ b/contrib/sendmail/src/Makefile.m4 @@ -1,4 +1,4 @@ -dnl $Id: Makefile.m4,v 8.121 2009/12/15 22:39:23 ca Exp $ +dnl $Id: Makefile.m4,v 8.126 2010/11/24 19:59:54 gshapiro Exp $ include(confBUILDTOOLSDIR`/M4/switch.m4') define(`confREQUIRE_LIBSM', `true') diff --git a/contrib/sendmail/src/conf.c b/contrib/sendmail/src/conf.c index 8d8f9ed..ffc6f20 100644 --- a/contrib/sendmail/src/conf.c +++ b/contrib/sendmail/src/conf.c @@ -1,5 +1,5 @@ /* - * Copyright (c) 1998-2009 Sendmail, Inc. and its suppliers. + * Copyright (c) 1998-2010 Sendmail, Inc. and its suppliers. * All rights reserved. * Copyright (c) 1983, 1995-1997 Eric P. Allman. All rights reserved. * Copyright (c) 1988, 1993 @@ -13,7 +13,7 @@ #include <sendmail.h> -SM_RCSID("@(#)$Id: conf.c,v 8.1153 2009/12/18 17:25:12 ca Exp $") +SM_RCSID("@(#)$Id: conf.c,v 8.1168 2011/01/25 18:31:30 ca Exp $") #include <sm/sendmail.h> #include <sendmail/pathnames.h> @@ -50,8 +50,11 @@ static int get_num_procs_online __P((void)); static int add_hostnames __P((SOCKADDR *)); #if NETINET6 && NEEDSGETIPNODE -static struct hostent *getipnodebyname __P((char *, int, int, int *)); -static struct hostent *getipnodebyaddr __P((char *, int, int, int *)); +static struct hostent *sm_getipnodebyname __P((const char *, int, int, int *)); +static struct hostent *sm_getipnodebyaddr __P((const void *, size_t, int, int *)); +#else /* NETINET6 && NEEDSGETIPNODE */ +#define sm_getipnodebyname getipnodebyname +#define sm_getipnodebyaddr getipnodebyaddr #endif /* NETINET6 && NEEDSGETIPNODE */ @@ -2600,7 +2603,7 @@ setproctitle(fmt, va_alist) ** none. */ -/*VARARGS2*/ +/*VARARGS3*/ void #ifdef __STDC__ sm_setproctitle(bool status, ENVELOPE *e, const char *fmt, ...) @@ -4188,7 +4191,7 @@ strstr(big, little) /* ** SM_GETHOSTBY{NAME,ADDR} -- compatibility routines for gethostbyXXX ** -** Some operating systems have wierd problems with the gethostbyXXX +** Some operating systems have weird problems with the gethostbyXXX ** routines. For example, Solaris versions at least through 2.3 ** don't properly deliver a canonical h_name field. This tries to ** work around these problems. @@ -4212,8 +4215,8 @@ strstr(big, little) # endif /* ! AI_ALL */ static struct hostent * -getipnodebyname(name, family, flags, err) - char *name; +sm_getipnodebyname(name, family, flags, err) + const char *name; int family; int flags; int *err; @@ -4236,9 +4239,9 @@ getipnodebyname(name, family, flags, err) } static struct hostent * -getipnodebyaddr(addr, len, family, err) - char *addr; - int len; +sm_getipnodebyaddr(addr, len, family, err) + const void *addr; + size_t len; int family; int *err; { @@ -4305,7 +4308,7 @@ sm_gethostbyname(name, family) # if ADDRCONFIG_IS_BROKEN flags &= ~AI_ADDRCONFIG; # endif /* ADDRCONFIG_IS_BROKEN */ - h = getipnodebyname(name, family, flags, &err); + h = sm_getipnodebyname(name, family, flags, &err); SM_SET_H_ERRNO(err); # else /* NETINET6 */ h = gethostbyname(name); @@ -4344,7 +4347,7 @@ sm_gethostbyname(name, family) hbuf, family); # if NETINET6 - h = getipnodebyname(hbuf, family, flags, &err); + h = sm_getipnodebyname(hbuf, family, flags, &err); SM_SET_H_ERRNO(err); save_errno = errno; # else /* NETINET6 */ @@ -4441,7 +4444,7 @@ sm_gethostbyaddr(addr, len, type) { int err; - hp = getipnodebyaddr(addr, len, type, &err); + hp = sm_getipnodebyaddr(addr, len, type, &err); SM_SET_H_ERRNO(err); } # else /* NETINET6 */ @@ -4864,6 +4867,7 @@ load_if_names() switch (af) { case AF_INET6: + SETV6LOOPBACKADDRFOUND(*sa); # ifdef __KAME__ /* convert into proper scoped address */ if ((IN6_IS_ADDR_LINKLOCAL(&sa->sin6.sin6_addr) || @@ -5063,6 +5067,7 @@ load_if_names() # if NETINET6 case AF_INET6: + SETV6LOOPBACKADDRFOUND(*sa); # ifdef __KAME__ /* convert into proper scoped address */ if ((IN6_IS_ADDR_LINKLOCAL(&sa->sin6.sin6_addr) || @@ -5928,6 +5933,9 @@ char *OsCompileOptions[] = #if HASWAITPID "HASWAITPID", #endif /* HASWAITPID */ +#if HAVE_NANOSLEEP + "HAVE_NANOSLEEP", +#endif /* HAVE_NANOSLEEP */ #if IDENTPROTO "IDENTPROTO", #endif /* IDENTPROTO */ @@ -6018,6 +6026,9 @@ char *OsCompileOptions[] = #ifdef USESYSCTL "USESYSCTL", #endif /* USESYSCTL */ +#if USE_OPENSSL_ENGINE + "USE_OPENSSL_ENGINE", +#endif /* USE_OPENSSL_ENGINE */ #if USING_NETSCAPE_LDAP "USING_NETSCAPE_LDAP", #endif /* USING_NETSCAPE_LDAP */ @@ -6321,7 +6332,7 @@ char *FFRCompileOptions[] = #endif /* _FFR_QUEUE_SCHED_DBG */ #if _FFR_RCPTTHROTDELAY /* configurable delay for BadRcptThrottle */ - "_FFR_RCPTTHROTDELAY" + "_FFR_RCPTTHROTDELAY", #endif /* _FFR_RCPTTHROTDELAY */ #if _FFR_REDIRECTEMPTY /* diff --git a/contrib/sendmail/src/daemon.c b/contrib/sendmail/src/daemon.c index 983ad2f..a1dcbe85 100644 --- a/contrib/sendmail/src/daemon.c +++ b/contrib/sendmail/src/daemon.c @@ -1,5 +1,5 @@ /* - * Copyright (c) 1998-2007, 2009 Sendmail, Inc. and its suppliers. + * Copyright (c) 1998-2007, 2009, 2010 Sendmail, Inc. and its suppliers. * All rights reserved. * Copyright (c) 1983, 1995-1997 Eric P. Allman. All rights reserved. * Copyright (c) 1988, 1993 @@ -14,7 +14,7 @@ #include <sendmail.h> #include "map.h" -SM_RCSID("@(#)$Id: daemon.c,v 8.683 2009/12/18 01:12:40 ca Exp $") +SM_RCSID("@(#)$Id: daemon.c,v 8.691 2011/01/25 18:31:30 ca Exp $") #if defined(SOCK_STREAM) || defined(__GNU_LIBRARY__) # define USE_SOCK_STREAM 1 @@ -1267,7 +1267,8 @@ setupdaemon(daemonaddr) case AF_INET6: if (IN6_IS_ADDR_UNSPECIFIED(&daemonaddr->sin6.sin6_addr)) daemonaddr->sin6.sin6_addr = - LocalDaemon ? in6addr_loopback : in6addr_any; + (LocalDaemon && V6LoopbackAddrFound) ? + in6addr_loopback : in6addr_any; port = daemonaddr->sin6.sin6_port; break; #endif /* NETINET6 */ @@ -2219,7 +2220,8 @@ makeconnection(host, port, mci, e, enough) #if NETINET6 case AF_INET6: if (IN6_IS_ADDR_UNSPECIFIED(&clt_addr.sin6.sin6_addr)) - clt_addr.sin6.sin6_addr = LocalDaemon ? + clt_addr.sin6.sin6_addr = + (LocalDaemon && V6LoopbackAddrFound) ? in6addr_loopback : in6addr_any; else clt_bind = true; @@ -2665,6 +2667,7 @@ gothostent: #if NETINET case AF_INET: addr.sin.sin_addr.s_addr = ConnectOnlyTo.sin.sin_addr.s_addr; + addr.sa.sa_family = ConnectOnlyTo.sa.sa_family; break; #endif /* NETINET */ @@ -2872,7 +2875,10 @@ nextaddr: /* Use the configured HeloName as appropriate */ if (HeloName != NULL && HeloName[0] != '\0') + { + SM_FREE_CLR(mci->mci_heloname); mci->mci_heloname = newstr(HeloName); + } mci_setstat(mci, EX_OK, NULL, NULL); return EX_OK; diff --git a/contrib/sendmail/src/deliver.c b/contrib/sendmail/src/deliver.c index 0322c95..acd977f 100644 --- a/contrib/sendmail/src/deliver.c +++ b/contrib/sendmail/src/deliver.c @@ -1,5 +1,5 @@ /* - * Copyright (c) 1998-2008 Sendmail, Inc. and its suppliers. + * Copyright (c) 1998-2010 Sendmail, Inc. and its suppliers. * All rights reserved. * Copyright (c) 1983, 1995-1997 Eric P. Allman. All rights reserved. * Copyright (c) 1988, 1993 @@ -14,7 +14,7 @@ #include <sendmail.h> #include <sm/time.h> -SM_RCSID("@(#)$Id: deliver.c,v 8.1020 2009/12/18 17:08:01 ca Exp $") +SM_RCSID("@(#)$Id: deliver.c,v 8.1024 2011/01/12 23:52:59 ca Exp $") #if HASSETUSERCONTEXT # include <login_cap.h> @@ -1850,7 +1850,7 @@ deliver(e, firstto) ** If we are running SMTP, we just need to clean up. */ - /* XXX this seems a bit wierd */ + /* XXX this seems a bit weird */ if (ctladdr == NULL && m != ProgMailer && m != FileMailer && bitset(QGOODUID, e->e_from.q_flags)) ctladdr = &e->e_from; @@ -2144,6 +2144,7 @@ tryhost: mci->mci_lastuse = curtime(); mci->mci_deliveries = 0; mci->mci_exitstat = i; + mci_clr_extensions(mci); # if NAMED_BIND mci->mci_herrno = h_errno; # endif /* NAMED_BIND */ @@ -3104,7 +3105,7 @@ reconnect: /* after switching to an encrypted connection */ mci->mci_state != MCIS_CLOSED) { SET_HELO(mci->mci_flags); - mci->mci_flags &= ~MCIF_EXTENS; + mci_clr_extensions(mci); goto reconnect; } } @@ -3157,7 +3158,7 @@ reconnect: /* after switching to an encrypted connection */ &mci->mci_out, mci->mci_conn, tmo) == 0) { - mci->mci_flags &= ~MCIF_EXTENS; + mci_clr_extensions(mci); mci->mci_flags |= MCIF_AUTHACT| MCIF_ONLY_EHLO; goto reconnect; @@ -6111,12 +6112,13 @@ starttls(m, mci, e) return EX_TEMPFAIL; # if USE_OPENSSL_ENGINE - if (!SSL_set_engine(NULL)) + if (!SSLEngineInitialized && !SSL_set_engine(NULL)) { sm_syslog(LOG_ERR, NOQID, "STARTTLS=client, SSL_set_engine=failed"); return EX_TEMPFAIL; } + SSLEngineInitialized = true; # endif /* USE_OPENSSL_ENGINE */ smtpmessage("STARTTLS", m, mci); diff --git a/contrib/sendmail/src/domain.c b/contrib/sendmail/src/domain.c index 394b0d3f..21442b3 100644 --- a/contrib/sendmail/src/domain.c +++ b/contrib/sendmail/src/domain.c @@ -1,5 +1,5 @@ /* - * Copyright (c) 1998-2004, 2006 Sendmail, Inc. and its suppliers. + * Copyright (c) 1998-2004, 2006, 2010 Sendmail, Inc. and its suppliers. * All rights reserved. * Copyright (c) 1986, 1995-1997 Eric P. Allman. All rights reserved. * Copyright (c) 1988, 1993 @@ -15,9 +15,9 @@ #include "map.h" #if NAMED_BIND -SM_RCSID("@(#)$Id: domain.c,v 8.202 2006/12/19 01:15:07 ca Exp $ (with name server)") +SM_RCSID("@(#)$Id: domain.c,v 8.204 2010/06/29 15:35:33 ca Exp $ (with name server)") #else /* NAMED_BIND */ -SM_RCSID("@(#)$Id: domain.c,v 8.202 2006/12/19 01:15:07 ca Exp $ (without name server)") +SM_RCSID("@(#)$Id: domain.c,v 8.204 2010/06/29 15:35:33 ca Exp $ (without name server)") #endif /* NAMED_BIND */ #if NAMED_BIND @@ -25,25 +25,6 @@ SM_RCSID("@(#)$Id: domain.c,v 8.202 2006/12/19 01:15:07 ca Exp $ (without name s # include <arpa/inet.h> -/* -** The standard udp packet size PACKETSZ (512) is not sufficient for some -** nameserver answers containing very many resource records. The resolver -** may switch to tcp and retry if it detects udp packet overflow. -** Also note that the resolver routines res_query and res_search return -** the size of the *un*truncated answer in case the supplied answer buffer -** it not big enough to accommodate the entire answer. -*/ - -# ifndef MAXPACKET -# define MAXPACKET 8192 /* max packet size used internally by BIND */ -# endif /* ! MAXPACKET */ - -typedef union -{ - HEADER qb1; - unsigned char qb2[MAXPACKET]; -} querybuf; - # ifndef MXHOSTBUFSIZE # define MXHOSTBUFSIZE (128 * MAXMXHOSTS) # endif /* ! MXHOSTBUFSIZE */ diff --git a/contrib/sendmail/src/envelope.c b/contrib/sendmail/src/envelope.c index 022c3ca..18defd2 100644 --- a/contrib/sendmail/src/envelope.c +++ b/contrib/sendmail/src/envelope.c @@ -13,7 +13,7 @@ #include <sendmail.h> -SM_RCSID("@(#)$Id: envelope.c,v 8.310 2009/12/18 17:08:01 ca Exp $") +SM_RCSID("@(#)$Id: envelope.c,v 8.312 2010/02/03 16:36:40 ca Exp $") /* ** CLRSESSENVELOPE -- clear session oriented data in an envelope @@ -246,12 +246,14 @@ dropenvelope(e, fulldrop, split) e->e_flags |= EF_FATALERRS|EF_CLRQUEUE; } + e->e_flags &= ~EF_QUEUERUN; for (q = e->e_sendqueue; q != NULL; q = q->q_next) { if (QS_IS_UNDELIVERED(q->q_state)) queueit = true; + /* see if a notification is needed */ if (bitset(QPINGONFAILURE, q->q_flags) && ((IS_MSG_ERR(msg_timeout) && diff --git a/contrib/sendmail/src/err.c b/contrib/sendmail/src/err.c index 5825666..baa355a 100644 --- a/contrib/sendmail/src/err.c +++ b/contrib/sendmail/src/err.c @@ -1,5 +1,5 @@ /* - * Copyright (c) 1998-2003 Sendmail, Inc. and its suppliers. + * Copyright (c) 1998-2003, 2010 Sendmail, Inc. and its suppliers. * All rights reserved. * Copyright (c) 1983, 1995-1997 Eric P. Allman. All rights reserved. * Copyright (c) 1988, 1993 @@ -13,7 +13,7 @@ #include <sendmail.h> -SM_RCSID("@(#)$Id: err.c,v 8.196 2006/11/10 23:14:08 ca Exp $") +SM_RCSID("@(#)$Id: err.c,v 8.205 2010/02/03 23:22:41 ca Exp $") #if LDAPMAP # include <lber.h> @@ -359,7 +359,7 @@ usrerr(fmt, va_alist) ** increments Errors. */ -/*VARARGS1*/ +/*VARARGS2*/ void #ifdef __STDC__ usrerrenh(char *enhsc, const char *fmt, ...) @@ -427,6 +427,7 @@ usrerrenh(enhsc, fmt, va_alist) if (QuickAbort) sm_exc_raisenew_x(&EtypeQuickAbort, 1); } + /* ** MESSAGE -- print message (not necessarily an error) ** @@ -473,11 +474,12 @@ message(msg, va_alist) case '5': if (CurEnv->e_rpool == NULL && CurEnv->e_message != NULL) sm_free(CurEnv->e_message); - CurEnv->e_message = - sm_rpool_strdup_x(CurEnv->e_rpool, errtxt); + CurEnv->e_message = sm_rpool_strdup_x(CurEnv->e_rpool, errtxt); break; } } + + /* ** NMESSAGE -- print message (not necessarily an error) ** diff --git a/contrib/sendmail/src/main.c b/contrib/sendmail/src/main.c index 1bbb070..4d2318f 100644 --- a/contrib/sendmail/src/main.c +++ b/contrib/sendmail/src/main.c @@ -1,5 +1,5 @@ /* - * Copyright (c) 1998-2006, 2008, 2009 Sendmail, Inc. and its suppliers. + * Copyright (c) 1998-2006, 2008, 2009, 2011 Sendmail, Inc. and its suppliers. * All rights reserved. * Copyright (c) 1983, 1995-1997 Eric P. Allman. All rights reserved. * Copyright (c) 1988, 1993 @@ -26,7 +26,7 @@ SM_UNUSED(static char copyright[]) = The Regents of the University of California. All rights reserved.\n"; #endif /* ! lint */ -SM_RCSID("@(#)$Id: main.c,v 8.971 2009/12/18 17:08:01 ca Exp $") +SM_RCSID("@(#)$Id: main.c,v 8.976 2011/03/15 23:14:36 ca Exp $") #if NETINET || NETINET6 @@ -304,6 +304,9 @@ main(argc, argv, envp) SubmitMode = SUBMIT_UNKNOWN; #if _FFR_LOCAL_DAEMON LocalDaemon = false; +# if NETINET6 + V6LoopbackAddrFound = false; +# endif /* NETINET6 */ #endif /* _FFR_LOCAL_DAEMON */ #if XDEBUG checkfd012("after openlog"); @@ -1308,7 +1311,7 @@ main(argc, argv, envp) (void) getfallbackmxrr(FallbackMX); #endif /* NAMED_BIND */ - if (SuperSafe == SAFE_INTERACTIVE && CurEnv->e_sendmode != SM_DELIVER) + if (SuperSafe == SAFE_INTERACTIVE && !SM_IS_INTERACTIVE(CurEnv->e_sendmode)) { (void) sm_io_fprintf(smioout, SM_TIME_DEFAULT, "WARNING: SuperSafe=interactive should only be used with\n DeliveryMode=interactive\n"); @@ -3190,7 +3193,7 @@ sigpipe(sig) ** may resend a message. ** ** Parameters: -** none. +** sig -- incoming signal. ** ** Returns: ** none. @@ -3201,8 +3204,6 @@ sigpipe(sig) ** NOTE: THIS CAN BE CALLED FROM A SIGNAL HANDLER. DO NOT ADD ** ANYTHING TO THIS ROUTINE UNLESS YOU KNOW WHAT YOU ARE ** DOING. -** -** XXX: More work is needed for this signal handler. */ /* ARGSUSED */ @@ -3217,38 +3218,34 @@ intsig(sig) errno = save_errno; CHECK_CRITICAL(sig); sm_allsignals(true); + IntSig = true; - if (sig != 0 && LogLevel > 79) - sm_syslog(LOG_DEBUG, CurEnv->e_id, "interrupt"); FileName = NULL; /* Clean-up on aborted stdin message submission */ - if (CurEnv->e_id != NULL && - (OpMode == MD_SMTP || + if (OpMode == MD_SMTP || OpMode == MD_DELIVER || - OpMode == MD_ARPAFTP)) + OpMode == MD_ARPAFTP) { - register ADDRESS *q; - - /* don't return an error indication */ - CurEnv->e_to = NULL; - CurEnv->e_flags &= ~EF_FATALERRS; - CurEnv->e_flags |= EF_CLRQUEUE; - - /* - ** Spin through the addresses and - ** mark them dead to prevent bounces - */ - - for (q = CurEnv->e_sendqueue; q != NULL; q = q->q_next) - q->q_state = QS_DONTSEND; - - drop = true; + if (CurEnv->e_id != NULL) + { + char *fn; + + fn = queuename(CurEnv, DATAFL_LETTER); + if (fn != NULL) + (void) unlink(fn); + fn = queuename(CurEnv, ANYQFL_LETTER); + if (fn != NULL) + (void) unlink(fn); + } + _exit(EX_OK); + /* NOTREACHED */ } - else if (OpMode != MD_TEST) - { + + if (sig != 0 && LogLevel > 79) + sm_syslog(LOG_DEBUG, CurEnv->e_id, "interrupt"); + if (OpMode != MD_TEST) unlockqueue(CurEnv); - } finis(drop, false, EX_OK); /* NOTREACHED */ diff --git a/contrib/sendmail/src/map.c b/contrib/sendmail/src/map.c index be88685..2eb6958 100644 --- a/contrib/sendmail/src/map.c +++ b/contrib/sendmail/src/map.c @@ -13,7 +13,7 @@ #include <sendmail.h> -SM_RCSID("@(#)$Id: map.c,v 8.705 2009/08/11 22:22:40 ca Exp $") +SM_RCSID("@(#)$Id: map.c,v 8.706 2010/07/27 03:35:42 ca Exp $") #if LDAPMAP # include <sm/ldap.h> @@ -5985,7 +5985,7 @@ stab_map_store(map, lhs, rhs) /* ** STAB_MAP_OPEN -- initialize (reads data file) ** -** This is a wierd case -- it is only intended as a fallback for +** This is a weird case -- it is only intended as a fallback for ** aliases. For this reason, opens for write (only during a ** "newaliases") always fails, and opens for read open the ** actual underlying text file instead of the database. diff --git a/contrib/sendmail/src/mci.c b/contrib/sendmail/src/mci.c index 2770117..7b17167 100644 --- a/contrib/sendmail/src/mci.c +++ b/contrib/sendmail/src/mci.c @@ -1,5 +1,5 @@ /* - * Copyright (c) 1998-2005 Sendmail, Inc. and its suppliers. + * Copyright (c) 1998-2005, 2010 Sendmail, Inc. and its suppliers. * All rights reserved. * Copyright (c) 1995-1997 Eric P. Allman. All rights reserved. * Copyright (c) 1988, 1993 @@ -13,7 +13,7 @@ #include <sendmail.h> -SM_RCSID("@(#)$Id: mci.c,v 8.221 2007/11/13 23:44:25 gshapiro Exp $") +SM_RCSID("@(#)$Id: mci.c,v 8.223 2010/03/10 04:35:28 ca Exp $") #if NETINET || NETINET6 # include <arpa/inet.h> @@ -288,6 +288,32 @@ mci_flush(doquit, allbut) mci_uncache(&MciCache[i], doquit); } } + +/* +** MCI_CLR_EXTENSIONS -- clear knowledge about SMTP extensions +** +** Parameters: +** mci -- the connection to clear. +** +** Returns: +** none. +*/ + +void +mci_clr_extensions(mci) + MCI *mci; +{ + if (mci == NULL) + return; + + mci->mci_flags &= ~MCIF_EXTENS; + mci->mci_maxsize = 0; + mci->mci_min_by = 0; +#if SASL + mci->mci_saslcap = NULL; +#endif /* SASL */ +} + /* ** MCI_GET -- get information about a particular host ** @@ -567,6 +593,7 @@ static struct mcifbits MciFlags[] = { MCIF_CVT7TO8, "CVT7TO8" }, { MCIF_INMIME, "INMIME" }, { MCIF_AUTH, "AUTH" }, + { MCIF_AUTH2, "AUTH2" }, { MCIF_AUTHACT, "AUTHACT" }, { MCIF_ENHSTAT, "ENHSTAT" }, { MCIF_PIPELINED, "PIPELINED" }, diff --git a/contrib/sendmail/src/parseaddr.c b/contrib/sendmail/src/parseaddr.c index 19bcf73..9135c22 100644 --- a/contrib/sendmail/src/parseaddr.c +++ b/contrib/sendmail/src/parseaddr.c @@ -13,7 +13,7 @@ #include <sendmail.h> -SM_RCSID("@(#)$Id: parseaddr.c,v 8.403 2008/02/08 02:27:35 ca Exp $") +SM_RCSID("@(#)$Id: parseaddr.c,v 8.404 2010/07/27 03:35:42 ca Exp $") #include <sm/sendmail.h> #include "map.h" @@ -319,7 +319,7 @@ delim: ** is invalid and should be "repaired". ** ** Returns: -** true -- if the address has any "wierd" characters or +** true -- if the address has any "weird" characters or ** non-printable characters or if a quote is unbalanced. ** false -- otherwise. */ diff --git a/contrib/sendmail/src/queue.c b/contrib/sendmail/src/queue.c index 194f525..16142d9 100644 --- a/contrib/sendmail/src/queue.c +++ b/contrib/sendmail/src/queue.c @@ -1,5 +1,5 @@ /* - * Copyright (c) 1998-2009 Sendmail, Inc. and its suppliers. + * Copyright (c) 1998-2009, 2011 Sendmail, Inc. and its suppliers. * All rights reserved. * Copyright (c) 1983, 1995-1997 Eric P. Allman. All rights reserved. * Copyright (c) 1988, 1993 @@ -14,7 +14,7 @@ #include <sendmail.h> #include <sm/sem.h> -SM_RCSID("@(#)$Id: queue.c,v 8.987 2009/12/18 17:08:01 ca Exp $") +SM_RCSID("@(#)$Id: queue.c,v 8.991 2011/03/15 23:14:36 ca Exp $") #include <dirent.h> @@ -203,7 +203,7 @@ static const char *FSPath[MAXFILESYS]; /* pathnames for file systems */ ** tag -- should be a unique id to avoid misinterpretations by others. ** idea: hash over configuration data that will be stored here. ** NumFileSys -- number of file systems. -** FileSys -- (arrary of) structure for used file systems. +** FileSys -- (array of) structure for used file systems. ** RSATmpCnt -- counter for number of uses of ephemeral RSA key. ** QShm -- (array of) structure for information about queue directories. */ @@ -633,7 +633,6 @@ queueup(e, announce, msync) } /* output inode number of data file */ - /* XXX should probably include device major/minor too */ if (e->e_dfino != -1) { (void) sm_io_fprintf(tfp, SM_TIME_DEFAULT, "I%ld/%ld/%llu\n", @@ -5195,7 +5194,11 @@ queuename(e, type) /* Assign an ID if needed */ if (e->e_id == NULL) + { + if (IntSig) + return NULL; assign_queueid(e); + } type = queue_letter(e, type); /* begin of filename */ @@ -5239,7 +5242,11 @@ queuename(e, type) else { if (e->e_qgrp == NOQGRP || e->e_qdir == NOQDIR) + { + if (IntSig) + return NULL; (void) setnewqueue(e); + } if (type == DATAFL_LETTER) { qd = e->e_dfqdir; @@ -5279,6 +5286,8 @@ queuename(e, type) break; default: + if (IntSig) + return NULL; sm_abort("queuename: bad queue file type %d", type); } diff --git a/contrib/sendmail/src/readcf.c b/contrib/sendmail/src/readcf.c index c6d48a8..7bc70c2 100644 --- a/contrib/sendmail/src/readcf.c +++ b/contrib/sendmail/src/readcf.c @@ -1,5 +1,5 @@ /* - * Copyright (c) 1998-2006, 2008, 2009 Sendmail, Inc. and its suppliers. + * Copyright (c) 1998-2006, 2008-2010 Sendmail, Inc. and its suppliers. * All rights reserved. * Copyright (c) 1983, 1995-1997 Eric P. Allman. All rights reserved. * Copyright (c) 1988, 1993 @@ -14,12 +14,13 @@ #include <sendmail.h> #include <sm/sendmail.h> -SM_RCSID("@(#)$Id: readcf.c,v 8.674 2009/10/26 17:47:00 ca Exp $") +SM_RCSID("@(#)$Id: readcf.c,v 8.684 2011/03/15 17:29:29 guenther Exp $") #if NETINET || NETINET6 # include <arpa/inet.h> #endif /* NETINET || NETINET6 */ + #define SECONDS #define MINUTES * 60 #define HOUR * 3600 @@ -114,7 +115,15 @@ readcf(cfname, safe, e) LineNumber = 0; #if STARTTLS - Srv_SSL_Options = Clt_SSL_Options = SSL_OP_ALL; + Srv_SSL_Options = SSL_OP_ALL; + Clt_SSL_Options = SSL_OP_ALL +#ifdef SSL_OP_NO_SSLv2 + | SSL_OP_NO_SSLv2 +#endif +#ifdef SSL_OP_NO_TICKET + | SSL_OP_NO_TICKET +#endif + ; #endif /* STARTTLS */ if (DontLockReadFiles) sff |= SFF_NOLOCK; @@ -2271,6 +2280,10 @@ static struct optioninfo # define O_RCPTTHROTDELAY 0xe6 { "BadRcptThrottleDelay", O_RCPTTHROTDELAY, OI_SAFE }, #endif /* _FFR_RCPTTHROTDELAY */ +#if 0 && _FFR_QOS && defined(SOL_IP) && defined(IP_TOS) +# define O_INETQOS 0xe7 /* reserved for FFR_QOS */ + { "InetQoS", O_INETQOS, OI_NONE }, +#endif { NULL, '\0', OI_NONE } }; @@ -2285,68 +2298,85 @@ static struct ssl_options /* these are turned on by default */ #ifdef SSL_OP_MICROSOFT_SESS_ID_BUG { "SSL_OP_MICROSOFT_SESS_ID_BUG", SSL_OP_MICROSOFT_SESS_ID_BUG }, -#endif /* SSL_OP_MICROSOFT_SESS_ID_BUG */ +#endif #ifdef SSL_OP_NETSCAPE_CHALLENGE_BUG { "SSL_OP_NETSCAPE_CHALLENGE_BUG", SSL_OP_NETSCAPE_CHALLENGE_BUG }, -#endif /* SSL_OP_NETSCAPE_CHALLENGE_BUG */ +#endif #ifdef SSL_OP_NETSCAPE_REUSE_CIPHER_CHANGE_BUG { "SSL_OP_NETSCAPE_REUSE_CIPHER_CHANGE_BUG", SSL_OP_NETSCAPE_REUSE_CIPHER_CHANGE_BUG }, -#endif /* SSL_OP_NETSCAPE_REUSE_CIPHER_CHANGE_BUG */ +#endif #ifdef SSL_OP_SSLREF2_REUSE_CERT_TYPE_BUG { "SSL_OP_SSLREF2_REUSE_CERT_TYPE_BUG", SSL_OP_SSLREF2_REUSE_CERT_TYPE_BUG }, -#endif /* SSL_OP_SSLREF2_REUSE_CERT_TYPE_BUG */ +#endif #ifdef SSL_OP_MICROSOFT_BIG_SSLV3_BUFFER { "SSL_OP_MICROSOFT_BIG_SSLV3_BUFFER", SSL_OP_MICROSOFT_BIG_SSLV3_BUFFER }, -#endif /* SSL_OP_MICROSOFT_BIG_SSLV3_BUFFER */ +#endif #ifdef SSL_OP_MSIE_SSLV2_RSA_PADDING { "SSL_OP_MSIE_SSLV2_RSA_PADDING", SSL_OP_MSIE_SSLV2_RSA_PADDING }, -#endif /* SSL_OP_MSIE_SSLV2_RSA_PADDING */ +#endif #ifdef SSL_OP_SSLEAY_080_CLIENT_DH_BUG { "SSL_OP_SSLEAY_080_CLIENT_DH_BUG", SSL_OP_SSLEAY_080_CLIENT_DH_BUG }, -#endif /* SSL_OP_SSLEAY_080_CLIENT_DH_BUG */ +#endif #ifdef SSL_OP_TLS_D5_BUG { "SSL_OP_TLS_D5_BUG", SSL_OP_TLS_D5_BUG }, -#endif /* SSL_OP_TLS_D5_BUG */ +#endif #ifdef SSL_OP_TLS_BLOCK_PADDING_BUG { "SSL_OP_TLS_BLOCK_PADDING_BUG", SSL_OP_TLS_BLOCK_PADDING_BUG }, -#endif /* SSL_OP_TLS_BLOCK_PADDING_BUG */ +#endif #ifdef SSL_OP_DONT_INSERT_EMPTY_FRAGMENTS { "SSL_OP_DONT_INSERT_EMPTY_FRAGMENTS", SSL_OP_DONT_INSERT_EMPTY_FRAGMENTS }, -#endif /* SSL_OP_DONT_INSERT_EMPTY_FRAGMENTS */ +#endif +#ifdef SSL_OP_ALL { "SSL_OP_ALL", SSL_OP_ALL }, +#endif +#ifdef SSL_OP_NO_QUERY_MTU + { "SSL_OP_NO_QUERY_MTU", SSL_OP_NO_QUERY_MTU }, +#endif +#ifdef SSL_OP_COOKIE_EXCHANGE + { "SSL_OP_COOKIE_EXCHANGE", SSL_OP_COOKIE_EXCHANGE }, +#endif +#ifdef SSL_OP_NO_TICKET + { "SSL_OP_NO_TICKET", SSL_OP_NO_TICKET }, +#endif #ifdef SSL_OP_NO_SESSION_RESUMPTION_ON_RENEGOTIATION { "SSL_OP_NO_SESSION_RESUMPTION_ON_RENEGOTIATION", SSL_OP_NO_SESSION_RESUMPTION_ON_RENEGOTIATION }, -#endif /* SSL_OP_NO_SESSION_RESUMPTION_ON_RENEGOTIATION */ +#endif +#ifdef SSL_OP_SINGLE_ECDH_USE + { "SSL_OP_SINGLE_ECDH_USE", SSL_OP_SINGLE_ECDH_USE }, +#endif +#ifdef SSL_OP_SINGLE_DH_USE + { "SSL_OP_SINGLE_DH_USE", SSL_OP_SINGLE_DH_USE }, +#endif #ifdef SSL_OP_EPHEMERAL_RSA { "SSL_OP_EPHEMERAL_RSA", SSL_OP_EPHEMERAL_RSA }, -#endif /* SSL_OP_EPHEMERAL_RSA */ +#endif #ifdef SSL_OP_CIPHER_SERVER_PREFERENCE { "SSL_OP_CIPHER_SERVER_PREFERENCE", SSL_OP_CIPHER_SERVER_PREFERENCE }, -#endif /* SSL_OP_CIPHER_SERVER_PREFERENCE */ +#endif #ifdef SSL_OP_TLS_ROLLBACK_BUG { "SSL_OP_TLS_ROLLBACK_BUG", SSL_OP_TLS_ROLLBACK_BUG }, -#endif /* SSL_OP_TLS_ROLLBACK_BUG */ +#endif #ifdef SSL_OP_NO_SSLv2 { "SSL_OP_NO_SSLv2", SSL_OP_NO_SSLv2 }, -#endif /* SSL_OP_NO_SSLv2 */ +#endif #ifdef SSL_OP_NO_SSLv3 { "SSL_OP_NO_SSLv3", SSL_OP_NO_SSLv3 }, -#endif /* SSL_OP_NO_SSLv3 */ +#endif #ifdef SSL_OP_NO_TLSv1 { "SSL_OP_NO_TLSv1", SSL_OP_NO_TLSv1 }, -#endif /* SSL_OP_NO_TLSv1 */ +#endif #ifdef SSL_OP_PKCS1_CHECK_1 { "SSL_OP_PKCS1_CHECK_1", SSL_OP_PKCS1_CHECK_1 }, -#endif /* SSL_OP_PKCS1_CHECK_1 */ +#endif #ifdef SSL_OP_PKCS1_CHECK_2 { "SSL_OP_PKCS1_CHECK_2", SSL_OP_PKCS1_CHECK_2 }, -#endif /* SSL_OP_PKCS1_CHECK_2 */ +#endif #ifdef SSL_OP_NETSCAPE_CA_DN_BUG { "SSL_OP_NETSCAPE_CA_DN_BUG", SSL_OP_NETSCAPE_CA_DN_BUG }, -#endif /* SSL_OP_NETSCAPE_CA_DN_BUG */ +#endif #ifdef SSL_OP_NETSCAPE_DEMO_CIPHER_CHANGE_BUG { "SSL_OP_NETSCAPE_DEMO_CIPHER_CHANGE_BUG", SSL_OP_NETSCAPE_DEMO_CIPHER_CHANGE_BUG }, -#endif /* SSL_OP_NETSCAPE_DEMO_CIPHER_CHANGE_BUG */ +#endif { NULL, 0 } }; #endif /* STARTTLS && _FFR_TLS_1 */ @@ -2639,6 +2669,7 @@ setoption(opt, val, safe, sticky, e) set_delivery_mode(*val, e); break; + default: syserr("Unknown delivery mode %c", *val); finis(false, true, EX_USAGE); @@ -3446,7 +3477,7 @@ setoption(opt, val, safe, sticky, e) ConnectOnlyTo.sa.sa_family = AF_UNSPEC; # if NETINET6 if (anynet_pton(AF_INET6, val, - &ConnectOnlyTo.sin6.sin6_addr) != 1) + &ConnectOnlyTo.sin6.sin6_addr) == 1) ConnectOnlyTo.sa.sa_family = AF_INET6; else # endif /* NETINET6 */ diff --git a/contrib/sendmail/src/sendmail.8 b/contrib/sendmail/src/sendmail.8 index e5ce9ae..5097f22 100644 --- a/contrib/sendmail/src/sendmail.8 +++ b/contrib/sendmail/src/sendmail.8 @@ -9,9 +9,9 @@ .\" the sendmail distribution. .\" .\" -.\" $Id: sendmail.8,v 8.59 2009/04/10 17:49:19 gshapiro Exp $ +.\" $Id: sendmail.8,v 8.60 2011/03/07 23:44:48 ca Exp $ .\" -.TH SENDMAIL 8 "$Date: 2009/04/10 17:49:19 $" +.TH SENDMAIL 8 "$Date: 2011/03/07 23:44:48 $" .SH NAME sendmail \- an electronic mail transport agent @@ -224,7 +224,9 @@ If not specified, ``Received:'' lines in the message are counted. .TP .B \-i -Ignore dots alone on lines by themselves in incoming messages. +Do not strip a leading dot from lines in incoming messages, +and do not treat a dot on a line by itself +as the end of an incoming message. This should be set if you are reading data from a file. .TP .BI "\-L " tag diff --git a/contrib/sendmail/src/sendmail.h b/contrib/sendmail/src/sendmail.h index b170c2b..39ba16c 100644 --- a/contrib/sendmail/src/sendmail.h +++ b/contrib/sendmail/src/sendmail.h @@ -1,5 +1,5 @@ /* - * Copyright (c) 1998-2009 Sendmail, Inc. and its suppliers. + * Copyright (c) 1998-2011 Sendmail, Inc. and its suppliers. * All rights reserved. * Copyright (c) 1983, 1995-1997 Eric P. Allman. All rights reserved. * Copyright (c) 1988, 1993 @@ -52,7 +52,7 @@ #ifdef _DEFINE # ifndef lint -SM_UNUSED(static char SmailId[]) = "@(#)$Id: sendmail.h,v 8.1068 2009/12/18 17:08:01 ca Exp $"; +SM_UNUSED(static char SmailId[]) = "@(#)$Id: sendmail.h,v 8.1089 2011/03/15 23:14:36 ca Exp $"; # endif /* ! lint */ #endif /* _DEFINE */ @@ -327,7 +327,7 @@ typedef struct address ADDRESS; (s) == QS_SENT || \ (s) == QS_DISCARDED) #define QS_IS_DEAD(s) ((s) >= QS_DONTSEND) - +#define QS_IS_TEMPFAIL(s) ((s) == QS_QUEUEUP || (s) == QS_RETRY) #define NULLADDR ((ADDRESS *) NULL) @@ -721,17 +721,20 @@ MCI #if STARTTLS #define MCIF_TLS 0x00100000 /* STARTTLS supported */ #define MCIF_TLSACT 0x00200000 /* STARTTLS active */ -#define MCIF_EXTENS (MCIF_EXPN | MCIF_SIZE | MCIF_8BITMIME | MCIF_DSN | MCIF_8BITOK | MCIF_AUTH | MCIF_ENHSTAT | MCIF_TLS) #else /* STARTTLS */ -#define MCIF_EXTENS (MCIF_EXPN | MCIF_SIZE | MCIF_8BITMIME | MCIF_DSN | MCIF_8BITOK | MCIF_AUTH | MCIF_ENHSTAT) +#define MCIF_TLS 0 +#define MCIF_TLSACT 0 #endif /* STARTTLS */ #define MCIF_DLVR_BY 0x00400000 /* DELIVERBY */ #if _FFR_IGNORE_EXT_ON_HELO # define MCIF_HELO 0x00800000 /* we used HELO: ignore extensions */ #endif /* _FFR_IGNORE_EXT_ON_HELO */ #define MCIF_INLONGLINE 0x01000000 /* in the middle of a long line */ +#define MCIF_AUTH2 0x02000000 /* got 2 AUTH lines */ #define MCIF_ONLY_EHLO 0x10000000 /* use only EHLO in smtpinit */ +#define MCIF_EXTENS (MCIF_EXPN | MCIF_SIZE | MCIF_8BITMIME | MCIF_DSN | MCIF_8BITOK | MCIF_AUTH | MCIF_ENHSTAT | MCIF_TLS | MCIF_AUTH2) + /* states */ #define MCIS_CLOSED 0 /* no traffic on this connection */ #define MCIS_OPENING 1 /* sending initial protocol */ @@ -749,6 +752,7 @@ extern void mci_close __P((MCI *, char *where)); extern void mci_dump __P((SM_FILE_T *, MCI *, bool)); extern void mci_dump_all __P((SM_FILE_T *, bool)); extern void mci_flush __P((bool, MCI *)); +extern void mci_clr_extensions __P((MCI *)); extern MCI *mci_get __P((char *, MAILER *)); extern int mci_lock_host __P((MCI *)); extern bool mci_match __P((char *, MAILER *)); @@ -1167,6 +1171,33 @@ struct hostsig_t typedef struct hostsig_t HOSTSIG_T; +/* +** The standard udp packet size PACKETSZ (512) is not sufficient for some +** nameserver answers containing very many resource records. The resolver +** may switch to tcp and retry if it detects udp packet overflow. +** Also note that the resolver routines res_query and res_search return +** the size of the *un*truncated answer in case the supplied answer buffer +** it not big enough to accommodate the entire answer. +*/ + +# ifndef MAXPACKET +# define MAXPACKET 8192 /* max packet size used internally by BIND */ +# endif /* ! MAXPACKET */ + +/* +** The resolver functions res_{send,query,querydomain} expect the +** answer buffer to be aligned, but some versions of gcc4 reverse +** 25 years of history and no longer align char buffers on the +** stack, resulting in crashes on strict-alignment platforms. Use +** this union when putting the buffer on the stack to force the +** alignment, then cast to (HEADER *) or (unsigned char *) as needed. +*/ +typedef union +{ + HEADER qb1; + unsigned char qb2[MAXPACKET]; +} querybuf; + /* functions */ extern bool getcanonname __P((char *, int, bool, int *)); extern int getmxrr __P((char *, char **, unsigned short *, bool, int *, bool, int *)); @@ -1246,11 +1277,15 @@ MAP #define MF_OPENBOGUS 0x00800000 /* open failed, don't call map_close */ #define MF_CLOSING 0x01000000 /* map is being closed */ -#define DYNOPENMAP(map) if (!bitset(MF_OPEN, (map)->map_mflags)) \ - { \ - if (!openmap(map)) \ - return NULL; \ - } +#define DYNOPENMAP(map) \ + do \ + { \ + if (!bitset(MF_OPEN, (map)->map_mflags)) \ + { \ + if (!openmap(map)) \ + return NULL; \ + } \ + } while (0) /* indices for map_actions */ @@ -1569,8 +1604,19 @@ extern void stabapply __P((void (*)(STAB *, int), int)); #if _FFR_LOCAL_DAEMON EXTERN bool LocalDaemon; +# if NETINET6 +EXTERN bool V6LoopbackAddrFound; /* found an IPv6 loopback address */ +# define SETV6LOOPBACKADDRFOUND(sa) \ + do \ + { \ + if (isloopback(sa)) \ + V6LoopbackAddrFound = true; \ + } while (0) +# endif /* NETINET6 */ #else /* _FFR_LOCAL_DAEMON */ # define LocalDaemon false +# define V6LoopbackAddrFound false +# define SETV6LOOPBACKADDRFOUND(sa) #endif /* _FFR_LOCAL_DAEMON */ /* Note: see also include/sendmail/pathnames.h: GET_CLIENT_CF */ @@ -1585,6 +1631,7 @@ EXTERN bool LocalDaemon; #define SM_DEFER 'd' /* defer map lookups as well as queue */ #define SM_VERIFY 'v' /* verify only (used internally) */ #define DM_NOTSET (-1) /* DeliveryMode (per daemon) option not set */ +# define SM_IS_INTERACTIVE(m) ((m) == SM_DELIVER) #define WILL_BE_QUEUED(m) ((m) == SM_QUEUE || (m) == SM_DEFER) @@ -2100,7 +2147,11 @@ extern void inittimeouts __P((char *, bool)); */ /* macros for debugging flags */ -#define tTd(flag, level) (tTdvect[flag] >= (unsigned char)level) +#if NOT_SENDMAIL +# define tTd(flag, level) (tTdvect[flag] >= (unsigned char)level) +#else +# define tTd(flag, level) (tTdvect[flag] >= (unsigned char)level && !IntSig) +#endif #define tTdlevel(flag) (tTdvect[flag]) /* variables */ @@ -2123,22 +2174,26 @@ extern unsigned char tTdvect[100]; /* trace vector */ */ /* set exit status */ -#define setstat(s) { \ - if (ExitStat == EX_OK || ExitStat == EX_TEMPFAIL) \ - ExitStat = s; \ - } +#define setstat(s) \ + do \ + { \ + if (ExitStat == EX_OK || ExitStat == EX_TEMPFAIL) \ + ExitStat = s; \ + } while (0) #define STRUCTCOPY(s, d) d = s /* free a pointer if it isn't NULL and set it to NULL */ #define SM_FREE_CLR(p) \ - if ((p) != NULL) \ - { \ - sm_free(p); \ - (p) = NULL; \ - } \ - else + do \ + { \ + if ((p) != NULL) \ + { \ + sm_free(p); \ + (p) = NULL; \ + } \ + } while (0) /* ** Update a permanent string variable with a new value. @@ -2185,6 +2240,15 @@ extern unsigned char tTdvect[100]; /* trace vector */ #define XS_DEFAULT 0 #define XS_STARTTLS 1 #define XS_AUTH 2 +#define XS_GREET 3 +#define XS_EHLO 4 +#define XS_MAIL 5 +#define XS_RCPT 6 +#define XS_DATA 7 +#define XS_EOM 8 +#define XS_DATA2 9 +#define XS_RCPT2 10 +#define XS_QUIT 15 /* ** Global variables. @@ -2363,6 +2427,7 @@ EXTERN char *RunAsUserName; /* user to become for bulk of run */ EXTERN char *SafeFileEnv; /* chroot location for file delivery */ EXTERN char *ServiceSwitchFile; /* backup service switch */ EXTERN char *volatile ShutdownRequest;/* a sendmail shutdown has been requested */ +EXTERN bool volatile IntSig; EXTERN char *SmtpGreeting; /* SMTP greeting message (old $e macro) */ EXTERN char *SmtpPhase; /* current phase in SMTP processing */ EXTERN char SmtpError[MAXLINE]; /* save failure error messages */ @@ -2390,6 +2455,9 @@ extern const SM_EXC_TYPE_T EtypeQuickAbort; /* type of a QuickAbort exception */ EXTERN int ConnectionRateWindowSize; +#if STARTTLS && USE_OPENSSL_ENGINE +EXTERN bool SSLEngineInitialized; +#endif /* STARTTLS && USE_OPENSSL_ENGINE */ /* ** Declarations of useful functions @@ -2442,6 +2510,8 @@ extern int smtprcpt __P((ADDRESS *, MAILER *, MCI *, ENVELOPE *, ADDRESS *, time extern void smtprset __P((MAILER *, MCI *, ENVELOPE *)); #define REPLYTYPE(r) ((r) / 100) /* first digit of reply code */ +#define REPLYCLASS(r) (((r) / 10) % 10) /* second digit of reply code */ +#define REPLYMINOR(r) ((r) % 10) /* last digit of reply code */ #define ISSMTPCODE(c) (isascii(c[0]) && isdigit(c[0]) && \ isascii(c[1]) && isdigit(c[1]) && \ isascii(c[2]) && isdigit(c[2])) diff --git a/contrib/sendmail/src/sm_resolve.c b/contrib/sendmail/src/sm_resolve.c index 6d9c28d..b8a1405 100644 --- a/contrib/sendmail/src/sm_resolve.c +++ b/contrib/sendmail/src/sm_resolve.c @@ -1,5 +1,5 @@ /* - * Copyright (c) 2000-2004 Sendmail, Inc. and its suppliers. + * Copyright (c) 2000-2004, 2010 Sendmail, Inc. and its suppliers. * All rights reserved. * * By using this file, you agree to the terms and conditions set @@ -44,9 +44,13 @@ #include <sendmail.h> #if DNSMAP # if NAMED_BIND +# if NETINET +# include <netinet/in_systm.h> +# include <netinet/ip.h> +# endif /* NETINET */ # include "sm_resolve.h" -SM_RCSID("$Id: sm_resolve.c,v 8.36 2008/02/11 23:04:16 ca Exp $") +SM_RCSID("$Id: sm_resolve.c,v 8.39 2010/06/29 15:35:33 ca Exp $") static struct stot { @@ -394,7 +398,13 @@ dns_lookup_int(domain, rr_class, rr_type, retrans, retry) time_t save_retrans = 0; int save_retry = 0; DNS_REPLY_T *r = NULL; - unsigned char reply[1024]; + querybuf reply_buf; + unsigned char *reply; + +#define SMRBSIZE sizeof(reply_buf) +#ifndef IP_MAXPACKET +# define IP_MAXPACKET 65535 +#endif if (tTd(8, 16)) { @@ -415,15 +425,44 @@ dns_lookup_int(domain, rr_class, rr_type, retrans, retry) } errno = 0; SM_SET_H_ERRNO(0); - len = res_search(domain, rr_class, rr_type, reply, sizeof(reply)); + reply = (unsigned char *)&reply_buf; + len = res_search(domain, rr_class, rr_type, reply, SMRBSIZE); + if (len >= SMRBSIZE) + { + if (len >= IP_MAXPACKET) + { + if (tTd(8, 4)) + sm_dprintf("dns_lookup: domain=%s, length=%d, default_size=%d, max=%d, status=response too long\n", + domain, len, (int) SMRBSIZE, + IP_MAXPACKET); + } + else + { + if (tTd(8, 6)) + sm_dprintf("dns_lookup: domain=%s, length=%d, default_size=%d, max=%d, status=response longer than default size, resizing\n", + domain, len, (int) SMRBSIZE, + IP_MAXPACKET); + reply = (unsigned char *)sm_malloc(IP_MAXPACKET); + if (reply == NULL) + SM_SET_H_ERRNO(TRY_AGAIN); + else + len = res_search(domain, rr_class, rr_type, + reply, IP_MAXPACKET); + } + } if (tTd(8, 16)) { _res.options = old_options; sm_dprintf("dns_lookup(%s, %d, %s) --> %d\n", domain, rr_class, dns_type_to_string(rr_type), len); } - if (len >= 0) + if (len >= 0 && len < IP_MAXPACKET && reply != NULL) r = parse_dns_reply(reply, len); + if (reply != (unsigned char *)&reply_buf && reply != NULL) + { + sm_free(reply); + reply = NULL; + } if (retrans > 0) _res.retrans = save_retrans; if (retry > 0) diff --git a/contrib/sendmail/src/srvrsmtp.c b/contrib/sendmail/src/srvrsmtp.c index 49016e4..1e6a5d2 100644 --- a/contrib/sendmail/src/srvrsmtp.c +++ b/contrib/sendmail/src/srvrsmtp.c @@ -1,5 +1,5 @@ /* - * Copyright (c) 1998-2008 Sendmail, Inc. and its suppliers. + * Copyright (c) 1998-2010 Sendmail, Inc. and its suppliers. * All rights reserved. * Copyright (c) 1983, 1995-1997 Eric P. Allman. All rights reserved. * Copyright (c) 1988, 1993 @@ -17,7 +17,7 @@ # include <libmilter/mfdef.h> #endif /* MILTER */ -SM_RCSID("@(#)$Id: srvrsmtp.c,v 8.989 2009/12/18 17:08:01 ca Exp $") +SM_RCSID("@(#)$Id: srvrsmtp.c,v 8.1008 2011/01/12 23:52:59 ca Exp $") #include <sm/time.h> #include <sm/fdset.h> @@ -875,10 +875,8 @@ smtp(nullserver, d_flags, e) /* XXX should these be options settable via .cf ? */ /* ssp.min_ssf = 0; is default due to memset() */ - { - ssp.max_ssf = MaxSLBits; - ssp.maxbufsize = MAXOUTLEN; - } + ssp.max_ssf = MaxSLBits; + ssp.maxbufsize = MAXOUTLEN; ssp.security_flags = SASLOpts & SASL_SEC_MASK; sasl_ok = sasl_setprop(conn, SASL_SEC_PROPS, &ssp) == SASL_OK; @@ -909,15 +907,6 @@ smtp(nullserver, d_flags, e) #endif /* SASL */ #if STARTTLS -# if USE_OPENSSL_ENGINE - if (tls_ok_srv && bitset(SRV_OFFER_TLS, features) && - !SSL_set_engine(NULL)) - { - sm_syslog(LOG_ERR, NOQID, - "STARTTLS=server, SSL_set_engine=failed"); - tls_ok_srv = false; - } -# endif /* USE_OPENSSL_ENGINE */ set_tls_rd_tmo(TimeOuts.to_nextcommand); @@ -1836,6 +1825,21 @@ smtp(nullserver, d_flags, e) break; } starttls: +# if USE_OPENSSL_ENGINE + if (!SSLEngineInitialized) + { + if (!SSL_set_engine(NULL)) + { + sm_syslog(LOG_ERR, NOQID, + "STARTTLS=server, SSL_set_engine=failed"); + tls_ok_srv = false; + message("454 4.3.3 TLS not available right now"); + break; + } + else + SSLEngineInitialized = true; + } +# endif /* USE_OPENSSL_ENGINE */ # if TLS_NO_RSA /* ** XXX do we need a temp key ? @@ -2260,8 +2264,7 @@ smtp(nullserver, d_flags, e) message("250-AUTH %s", mechlist); #endif /* SASL */ #if STARTTLS - if (tls_ok_srv && - bitset(SRV_OFFER_TLS, features)) + if (tls_ok_srv && bitset(SRV_OFFER_TLS, features)) message("250-STARTTLS"); #endif /* STARTTLS */ if (DeliverByMin > 0) @@ -2622,7 +2625,7 @@ smtp(nullserver, d_flags, e) goto rcpt_done; } - if (e->e_sendmode != SM_DELIVER + if (!SM_IS_INTERACTIVE(e->e_sendmode) #if _FFR_DM_ONE && (NotFirstDelivery || SM_DM_ONE != e->e_sendmode) #endif /* _FFR_DM_ONE */ @@ -3724,6 +3727,7 @@ smtp_data(smtp, e) _res.retrans = TimeOuts.res_retrans[RES_TO_FIRST]; #endif /* NAMED_BIND */ + for (ee = e; ee != NULL; ee = ee->e_sibling) { /* make sure we actually do delivery */ @@ -3767,18 +3771,18 @@ smtp_data(smtp, e) oldid = CurEnv->e_id; CurEnv->e_id = id; - /* issue success message */ + /* issue success message */ #if _FFR_MSG_ACCEPT - if (MessageAccept != NULL && *MessageAccept != '\0') - { - char msg[MAXLINE]; + if (MessageAccept != NULL && *MessageAccept != '\0') + { + char msg[MAXLINE]; - expand(MessageAccept, msg, sizeof(msg), e); - message("250 2.0.0 %s", msg); - } - else + expand(MessageAccept, msg, sizeof(msg), e); + message("250 2.0.0 %s", msg); + } + else #endif /* _FFR_MSG_ACCEPT */ - message("250 2.0.0 %s Message accepted for delivery", id); + message("250 2.0.0 %s Message accepted for delivery", id); CurEnv->e_id = oldid; /* if we just queued, poke it */ @@ -4687,7 +4691,8 @@ proxy_policy(conn, context, requested_user, rlen, auth_identity, alen, return SASL_FAIL; macdefine(&BlankEnvelope.e_macro, A_TEMP, - macid("{auth_authen}"), (char *) auth_identity); + macid("{auth_authen}"), + xtextify((char *) auth_identity, "=<>\")")); return SASL_OK; } diff --git a/contrib/sendmail/src/tls.c b/contrib/sendmail/src/tls.c index 7031994..a57a05d 100644 --- a/contrib/sendmail/src/tls.c +++ b/contrib/sendmail/src/tls.c @@ -1,5 +1,5 @@ /* - * Copyright (c) 2000-2006, 2008, 2009 Sendmail, Inc. and its suppliers. + * Copyright (c) 2000-2006, 2008, 2009, 2011 Sendmail, Inc. and its suppliers. * All rights reserved. * * By using this file, you agree to the terms and conditions set @@ -10,7 +10,7 @@ #include <sendmail.h> -SM_RCSID("@(#)$Id: tls.c,v 8.114 2009/08/10 15:11:09 ca Exp $") +SM_RCSID("@(#)$Id: tls.c,v 8.118 2011/03/07 23:20:47 ca Exp $") #if STARTTLS # include <openssl/err.h> @@ -1168,7 +1168,7 @@ tls_get_info(ssl, srv, host, mac, certreq) MACROS_T *mac; bool certreq; { - SSL_CIPHER *c; + const SSL_CIPHER *c; int b, r; long verifyok; char *s, *who; @@ -1213,12 +1213,14 @@ tls_get_info(ssl, srv, host, mac, certreq) macdefine(mac, A_TEMP, macid("{cert_issuer}"), xtextify(buf, "<>\")")); +# define LL_BADCERT 8 + #define CHECK_X509_NAME(which) \ do { \ if (r == -1) \ { \ sm_strlcpy(buf, "BadCertificateUnknown", sizeof(buf)); \ - if (LogLevel > 7) \ + if (LogLevel > LL_BADCERT) \ sm_syslog(LOG_INFO, NOQID, \ "STARTTLS=%s, relay=%.100s, field=%s, status=failed to extract CN", \ who, \ diff --git a/contrib/sendmail/src/udb.c b/contrib/sendmail/src/udb.c index 29470e7..22b198e 100644 --- a/contrib/sendmail/src/udb.c +++ b/contrib/sendmail/src/udb.c @@ -15,9 +15,9 @@ #include "map.h" #if USERDB -SM_RCSID("@(#)$Id: udb.c,v 8.164 2006/12/19 19:49:51 ca Exp $ (with USERDB)") +SM_RCSID("@(#)$Id: udb.c,v 8.165 2010/01/10 06:22:00 ca Exp $ (with USERDB)") #else /* USERDB */ -SM_RCSID("@(#)$Id: udb.c,v 8.164 2006/12/19 19:49:51 ca Exp $ (without USERDB)") +SM_RCSID("@(#)$Id: udb.c,v 8.165 2010/01/10 06:22:00 ca Exp $ (without USERDB)") #endif /* USERDB */ #if USERDB @@ -1219,7 +1219,7 @@ _udbx_close() # endif /* DB_VERSION_MAJOR < 2 */ } if (tTd(28, 1)) - sm_dprintf("_udbx_init: db->close(%s)\n", + sm_dprintf("_udbx_close: db->close(%s)\n", up->udb_dbname); # endif /* NEWDB */ } diff --git a/contrib/sendmail/src/usersmtp.c b/contrib/sendmail/src/usersmtp.c index 23278b0..0de839e 100644 --- a/contrib/sendmail/src/usersmtp.c +++ b/contrib/sendmail/src/usersmtp.c @@ -1,5 +1,5 @@ /* - * Copyright (c) 1998-2006, 2008, 2009 Sendmail, Inc. and its suppliers. + * Copyright (c) 1998-2006, 2008-2010 Sendmail, Inc. and its suppliers. * All rights reserved. * Copyright (c) 1983, 1995-1997 Eric P. Allman. All rights reserved. * Copyright (c) 1988, 1993 @@ -13,7 +13,7 @@ #include <sendmail.h> -SM_RCSID("@(#)$Id: usersmtp.c,v 8.473 2009/06/17 17:26:51 ca Exp $") +SM_RCSID("@(#)$Id: usersmtp.c,v 8.485 2010/07/23 21:09:38 ca Exp $") #include <sysexits.h> @@ -33,7 +33,6 @@ extern void sm_sasl_free __P((void *)); ** This protocol is described in RFC821. */ -#define REPLYCLASS(r) (((r) / 10) % 10) /* second digit of reply code */ #define SMTPCLOSING 421 /* "Service Shutting Down" */ #define ENHSCN(e, d) ((e) == NULL ? (d) : (e)) @@ -136,8 +135,7 @@ smtpinit(m, mci, e, onlyhelo) SmtpPhase = mci->mci_phase = "client greeting"; sm_setproctitle(true, e, "%s %s: %s", qid_printname(e), CurHostName, mci->mci_phase); - r = reply(m, mci, e, TimeOuts.to_initial, esmtp_check, NULL, - XS_DEFAULT); + r = reply(m, mci, e, TimeOuts.to_initial, esmtp_check, NULL, XS_GREET); if (r < 0) goto tempfail1; if (REPLYTYPE(r) == 4) @@ -183,7 +181,7 @@ tryhelo: r = reply(m, mci, e, bitnset(M_LMTP, m->m_flags) ? TimeOuts.to_lhlo : TimeOuts.to_helo, - helo_options, NULL, XS_DEFAULT); + helo_options, NULL, XS_EHLO); if (r < 0) goto tempfail1; else if (REPLYTYPE(r) == 5) @@ -336,7 +334,15 @@ str_union(s1, s2, rpool) l1 = strlen(s1); l2 = strlen(s2); rl = l1 + l2; - res = (char *) sm_rpool_malloc(rpool, rl + 2); + if (rl <= 0) + { + sm_syslog(LOG_WARNING, NOQID, + "str_union: stringlen1=%d, stringlen2=%d, sum=%d, status=overflow", + l1, l2, rl); + res = NULL; + } + else + res = (char *) sm_rpool_malloc(rpool, rl + 2); if (res == NULL) { if (l1 > l2) @@ -409,9 +415,7 @@ helo_options(line, firstline, m, mci, e) if (firstline) { -#if SASL - mci->mci_saslcap = NULL; -#endif /* SASL */ + mci_clr_extensions(mci); #if _FFR_IGNORE_EXT_ON_HELO logged = false; #endif /* _FFR_IGNORE_EXT_ON_HELO */ @@ -472,7 +476,8 @@ helo_options(line, firstline, m, mci, e) #if SASL else if (sm_strcasecmp(line, "auth") == 0) { - if (p != NULL && *p != '\0') + if (p != NULL && *p != '\0' && + !bitset(MCIF_AUTH2, mci->mci_flags)) { if (mci->mci_saslcap != NULL) { @@ -484,7 +489,7 @@ helo_options(line, firstline, m, mci, e) mci->mci_saslcap = str_union(mci->mci_saslcap, p, mci->mci_rpool); - mci->mci_flags |= MCIF_AUTH; + mci->mci_flags |= MCIF_AUTH2; } else { @@ -501,6 +506,9 @@ helo_options(line, firstline, m, mci, e) } } } + if (tTd(95, 5)) + sm_syslog(LOG_DEBUG, NOQID, "AUTH flags=%lx, mechs=%s", + mci->mci_flags, mci->mci_saslcap); } #endif /* SASL */ } @@ -1606,13 +1614,11 @@ attemptauth(m, mci, e, sai) (void) memset(&ssp, '\0', sizeof(ssp)); /* XXX should these be options settable via .cf ? */ - { - ssp.max_ssf = MaxSLBits; - ssp.maxbufsize = MAXOUTLEN; + ssp.max_ssf = MaxSLBits; + ssp.maxbufsize = MAXOUTLEN; # if 0 - ssp.security_flags = SASL_SEC_NOPLAINTEXT; + ssp.security_flags = SASL_SEC_NOPLAINTEXT; # endif /* 0 */ - } saslresult = sasl_setprop(mci->mci_conn, SASL_SEC_PROPS, &ssp); if (saslresult != SASL_OK) return EX_TEMPFAIL; @@ -2175,7 +2181,7 @@ smtpmailfrom(m, mci, e) SmtpPhase = mci->mci_phase = "client MAIL"; sm_setproctitle(true, e, "%s %s: %s", qid_printname(e), CurHostName, mci->mci_phase); - r = reply(m, mci, e, TimeOuts.to_mail, NULL, &enhsc, XS_DEFAULT); + r = reply(m, mci, e, TimeOuts.to_mail, NULL, &enhsc, XS_MAIL); if (r < 0) { /* communications failure */ @@ -2427,7 +2433,7 @@ smtprcptstat(to, m, mci, e) } enhsc = NULL; - r = reply(m, mci, e, TimeOuts.to_rcpt, NULL, &enhsc, XS_DEFAULT); + r = reply(m, mci, e, TimeOuts.to_rcpt, NULL, &enhsc, XS_RCPT); save_errno = errno; to->q_rstatus = sm_rpool_strdup_x(e->e_rpool, SmtpReplyBuffer); to->q_status = ENHSCN_RPOOL(enhsc, smtptodsn(r), e->e_rpool); @@ -2588,7 +2594,7 @@ smtpdata(m, mci, e, ctladdr, xstart) mci->mci_state = MCIS_DATA; sm_setproctitle(true, e, "%s %s: %s", qid_printname(e), CurHostName, mci->mci_phase); - r = reply(m, mci, e, TimeOuts.to_datainit, NULL, &enhsc, XS_DEFAULT); + r = reply(m, mci, e, TimeOuts.to_datainit, NULL, &enhsc, XS_DATA); if (r < 0 || REPLYTYPE(r) == 4) { if (r >= 0) @@ -2722,7 +2728,7 @@ smtpdata(m, mci, e, ctladdr, xstart) CurHostName, mci->mci_phase); if (bitnset(M_LMTP, m->m_flags)) return EX_OK; - r = reply(m, mci, e, TimeOuts.to_datafinal, NULL, &enhsc, XS_DEFAULT); + r = reply(m, mci, e, TimeOuts.to_datafinal, NULL, &enhsc, XS_EOM); if (r < 0) return EX_TEMPFAIL; if (mci->mci_state == MCIS_DATA) @@ -2807,7 +2813,7 @@ smtpgetstat(m, mci, e) enhsc = NULL; /* check for the results of the transaction */ - r = reply(m, mci, e, TimeOuts.to_datafinal, NULL, &enhsc, XS_DEFAULT); + r = reply(m, mci, e, TimeOuts.to_datafinal, NULL, &enhsc, XS_DATA2); if (r < 0) return EX_TEMPFAIL; xstat = EX_NOTSTICKY; @@ -2893,8 +2899,7 @@ smtpquit(m, mci, e) SmtpPhase = "client QUIT"; mci->mci_state = MCIS_QUITING; smtpmessage("QUIT", m, mci); - (void) reply(m, mci, e, TimeOuts.to_quit, NULL, NULL, - XS_DEFAULT); + (void) reply(m, mci, e, TimeOuts.to_quit, NULL, NULL, XS_QUIT); SuprErrs = oldSuprErrs; if (mci->mci_state == MCIS_CLOSED) goto end; @@ -3233,14 +3238,17 @@ reply(m, mci, e, timeout, pfunc, enhstat, rtype) if (pfunc != NULL) (*pfunc)(bufp, firstline, m, mci, e); - firstline = false; - /* decode the reply code */ r = atoi(bufp); /* extra semantics: 0xx codes are "informational" */ if (r < 100) + { + firstline = false; continue; + } + + firstline = false; /* if no continuation lines, return this line */ if (bufp[3] != '-') diff --git a/contrib/sendmail/src/version.c b/contrib/sendmail/src/version.c index cb94d0f..4f156c2 100644 --- a/contrib/sendmail/src/version.c +++ b/contrib/sendmail/src/version.c @@ -1,5 +1,5 @@ /* - * Copyright (c) 1998-2009 Sendmail, Inc. and its suppliers. + * Copyright (c) 1998-2011 Sendmail, Inc. and its suppliers. * All rights reserved. * Copyright (c) 1983 Eric P. Allman. All rights reserved. * Copyright (c) 1988, 1993 @@ -13,6 +13,6 @@ #include <sm/gen.h> -SM_RCSID("@(#)$Id: version.c,v 8.218 2009/12/23 04:43:09 ca Exp $") +SM_RCSID("@(#)$Id: version.c,v 8.227 2011/04/26 23:02:35 ca Exp $") -char Version[] = "8.14.4"; +char Version[] = "8.14.5"; |