diff options
Diffstat (limited to 'usr.sbin/sendmail')
-rw-r--r-- | usr.sbin/sendmail/RELEASE_NOTES | 103 | ||||
-rw-r--r-- | usr.sbin/sendmail/cf/m4/cfhead.m4 | 6 | ||||
-rw-r--r-- | usr.sbin/sendmail/cf/m4/proto.m4 | 6 | ||||
-rw-r--r-- | usr.sbin/sendmail/cf/m4/version.m4 | 4 | ||||
-rw-r--r-- | usr.sbin/sendmail/cf/ostype/mklinux.m4 | 4 | ||||
-rwxr-xr-x | usr.sbin/sendmail/contrib/etrn.pl | 301 | ||||
-rw-r--r-- | usr.sbin/sendmail/doc/op/op.me | 16 | ||||
-rw-r--r-- | usr.sbin/sendmail/src/READ_ME | 25 | ||||
-rw-r--r-- | usr.sbin/sendmail/src/clock.c | 30 | ||||
-rw-r--r-- | usr.sbin/sendmail/src/convtime.c | 5 | ||||
-rw-r--r-- | usr.sbin/sendmail/src/envelope.c | 10 | ||||
-rw-r--r-- | usr.sbin/sendmail/src/err.c | 6 | ||||
-rw-r--r-- | usr.sbin/sendmail/src/makesendmail | 9 | ||||
-rw-r--r-- | usr.sbin/sendmail/src/map.c | 11 | ||||
-rw-r--r-- | usr.sbin/sendmail/src/mci.c | 82 | ||||
-rw-r--r-- | usr.sbin/sendmail/src/queue.c | 86 | ||||
-rw-r--r-- | usr.sbin/sendmail/src/stab.c | 4 | ||||
-rw-r--r-- | usr.sbin/sendmail/src/version.c | 4 | ||||
-rw-r--r-- | usr.sbin/sendmail/test/Results | 2 |
19 files changed, 595 insertions, 119 deletions
diff --git a/usr.sbin/sendmail/RELEASE_NOTES b/usr.sbin/sendmail/RELEASE_NOTES index 203b61a..621cbcc 100644 --- a/usr.sbin/sendmail/RELEASE_NOTES +++ b/usr.sbin/sendmail/RELEASE_NOTES @@ -1,11 +1,110 @@ SENDMAIL RELEASE NOTES - @(#)RELEASE_NOTES 8.8.3.2 (Berkeley) 11/16/96 + @(#)RELEASE_NOTES 8.8.4.4 (Berkeley) 12/2/96 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.8.4/8.8.4 96/12/02 + SECURITY: under some circumstances, an attacker could get additional + permissions by hard linking to files that were group + writable by the attacker. The solution is to disallow any + files that have hard links -- this will affect .forward, + :include:, and output files. Problem noted by Terry + Kyriacopoulos of Interlog Internet Services. As a + workaround, set UnsafeGroupWrites -- always a good idea. + SECURITY: the TryNullMXList (w) option should not be safe -- if it + is, it is possible to do a denial-of-service attack on + MX hosts that rely on the use of the null MX list. There + is no danger if you have this option turned off (the default). + Problem noted by Dan Bernstein. Also, make the DontInitGroups + unsafe. I know of no specific attack against this, although + a denial-of-service attack is probably possible, but in theory + you should not be able to safely tweak anything that affects + the permissions that are used when mail is delivered. + Purgestat could go into an infinite loop if one of the host status + directories somehow became empty. Problem noted by Roy + Mongiovi of Georgia Tech. + Processes got "lost" when counting children due to a race condition. + This caused "proc_list_probe: lost pid" messages to be logged. + Problem noted by several people. + On systems with System V SIGCLD child signal semantics (notably AIX + and HP-UX), mail transactions would print the message "451 + SMTP-MAIL: lost child: No child processes". Problem noted + by several people. + Miscellaneous compiler warnings on picky compilers (or when setting + gcc to high warning levels). From Tom Moore of NCR Corp. + SMTP protocol errors, and most errors on MAIL FROM: lines should + not be persistent between runs, since they are based on the + message rather than the host. Problem noted by Matt Dillon + of Best Internet Communications. + The F=7 flag was ignored on SMTP mailers. Problem noted by Tom Moore + of NCR (a.k.a., AT&T Global Information Solutions). + Avoid the possibility of having a child daemon run to completion + (including closing the SMTP socket) before the parent has + had a chance to close the socket; this can cause the parent + to hang for a long time waiting for the socket to drain. + Patch from Don Lewis of TDK Semiconductor. + If the fork() failed in a queue run, the queue runners would not be + rescheduled (so queue runs would stop). Patch from Don Lewis. + Some error conditions in ETRN could cause output without an SMTP + status code. Problem noted by Don Lewis. + Multiple :maildrop addresses in the user database didn't work properly. + Patch from Roy Mongiovi of Georgia Tech. + Add ".db" automatically onto any user database spec that does not + already have it; this is for consistency with makemap, the + K line, and the documentation. Inconsistency pointed out + by Roy Mongiovi. + Allow sendmail to be properly called in nohup mode. Patch from + Kyle Jones of UUNET. + Change ETRN to ignore but still update host status files; previously + it would ignore them and not save the updated status, which + caused stale information to be maintained. Based on a patch + from Christopher Davis of Kapor Enterprises Inc. Also, have + ETRN ignore the MinQueueAge option. + Patch long term host status to recover more gracefully from an empty + host status file condition. Patch from NAKAMURA Motonori + of Kyoto University. + Several patches to signal handling code to fix potential race + conditions from Don Lewis. + Make it possible to compile with -DDAEMON=0 (previously it had some + compile errors). This turns DAEMON, QUEUE, and SMTP into + 0/1 compilation flags. Note that DAEMON is an obsolete + compile flag; use NETINET instead. Solution based on a + patch from Bryan Costales. + PORTABILITY FIXES: + AIX4: getpwnam() and getpwuid() do a sequential scan of the + /etc/security/passwd file when called as root. This + is very slow on some systems. To speed it up, use the + (undocumented) _getpw{nam,uid}_shadow() routines. + Patch from Chris Thomas of UCLA/OAC Systems Group. + SCO 5.x: include -lprot in the Makefile. Patch from Bill + Glicker of Burrelle's Information Service. + NEWS-OS 4.x: need a definition for MODE_T to compile. Patch + from Makoto MATSUSHITA of Osaka University. + SunOS 4.0.3: compile problems. Patches from Andrew Cole of + Leeds University and SASABE Tetsuro of the University + of Tokyo. + DG/UX 5.4.4.11 from Brian J. Murrell of InterLinx Support + Services, Inc. + Domain/OS from Don (Truck) Lewis of TDK Semiconductor Corp. + I believe this to have only been a problem if you + compiled with -DUSE_VENDOR_CF_PATH -- another reason + to stick with /etc/sendmail.cf as your One True Path. + Digital UNIX (OSF/1 on Alpha) load average computation from + Martin Laubach of the Technischen Universität Wien. + CONFIG: change default Received: line to be multiple lines rather + than one long one. By popular demand. + MAIL.LOCAL: warnings weren't being logged on some systems. Patch + from Jerome Berkman of U.C. Berkeley. + MAKEMAP: be sure to zero hinfo to avoid cruft that can cause runs + to take a very long time. Problem noted by Yoshiro YONEYA + of NTT Software Corporation. + CONTRIB: add etrn.pl, contributed by John Beck. + NEW FILES: + contrib/etrn.pl + 8.8.3/8.8.3 96/11/17 SECURITY: it was possible to get a root shell by lying to sendmail about argv[0] and then sending it a signal. Problem noted @@ -83,7 +182,7 @@ summary of the changes in that release. AIX4: use tzname[] vector to determine time zone name. Patch from NAKAMURA Motonori of Kyoto University. MkLinux: add Makefile.Linux.ppc and OSTYPE(mklinux) support. - Contributed by Paul DeBois <dubois@primate.wisc.edu>. + Contributed by Paul DuBois <dubois@primate.wisc.edu>. Solaris: kstat(3k) support for retrieving the load average. This adds the LA_KSTAT definition for LA_TYPE. The outline of the implementation was contributed diff --git a/usr.sbin/sendmail/cf/m4/cfhead.m4 b/usr.sbin/sendmail/cf/m4/cfhead.m4 index f152572..91d4b9a 100644 --- a/usr.sbin/sendmail/cf/m4/cfhead.m4 +++ b/usr.sbin/sendmail/cf/m4/cfhead.m4 @@ -128,7 +128,9 @@ define(`confMAILER_NAME', ``MAILER-DAEMON'') define(`confFROM_LINE', `From $g $d') define(`confOPERATORS', `.:%@!^/[]+') define(`confSMTP_LOGIN_MSG', `$j Sendmail $v/$Z; $b') -define(`confRECEIVED_HEADER', `$?sfrom $s $.$?_($?s$|from $.$_) $.by $j ($v/$Z)$?r with $r$. id $i$?u for $u$.; $b') +define(`confRECEIVED_HEADER', `$?sfrom $s $.$?_($?s$|from $.$_) + $.by $j ($v/$Z)$?r with $r$. + id $i$?u for $u$.; $b') define(`confSEVEN_BIT_INPUT', `False') define(`confEIGHT_BIT_HANDLING', `pass8') define(`confALIAS_WAIT', `10') @@ -154,4 +156,4 @@ define(`confMIME_FORMAT_ERRORS', `True') define(`confFORWARD_PATH', `$z/.forward.$w:$z/.forward') divert(0)dnl -VERSIONID(`@(#)cfhead.m4 8.6 (Berkeley) 6/19/96') +VERSIONID(`@(#)cfhead.m4 8.7 (Berkeley) 11/20/96') diff --git a/usr.sbin/sendmail/cf/m4/proto.m4 b/usr.sbin/sendmail/cf/m4/proto.m4 index 474dc7d..676aa35 100644 --- a/usr.sbin/sendmail/cf/m4/proto.m4 +++ b/usr.sbin/sendmail/cf/m4/proto.m4 @@ -34,7 +34,7 @@ divert(-1) # divert(0) -VERSIONID(`@(#)proto.m4 8.135 (Berkeley) 10/26/96') +VERSIONID(`@(#)proto.m4 8.136 (Berkeley) 11/24/96') MAILER(local)dnl @@ -428,7 +428,7 @@ _OPTION(OperatorChars, `confOPERATORS') # shall I avoid calling initgroups(3) because of high NIS costs? _OPTION(DontInitGroups, `confDONT_INIT_GROUPS') -# are group-writable :include: and .forward files (un)trustworthy? +# are group-writable `:include:' and .forward files (un)trustworthy? _OPTION(UnsafeGroupWrites, `confUNSAFE_GROUP_WRITES') # where do errors that occur when sending errors get sent? @@ -635,7 +635,7 @@ ifdef(`_USE_DECNET_SYNTAX_', R$+ @ $+ . DECNET $2 :: $1 u@h.DECNET => h::u', `dnl') # delete duplicate local names -R$+ % $=w @ $=w $1 @ $j u%host@host => u@host +R$+ % $=w @ $=w $1 @ $2 u%host@host => u@host diff --git a/usr.sbin/sendmail/cf/m4/version.m4 b/usr.sbin/sendmail/cf/m4/version.m4 index 0fe40a9..b3ee9a7 100644 --- a/usr.sbin/sendmail/cf/m4/version.m4 +++ b/usr.sbin/sendmail/cf/m4/version.m4 @@ -32,8 +32,8 @@ divert(-1) # OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF # SUCH DAMAGE. # -VERSIONID(`@(#)version.m4 8.8.3.1 (Berkeley) 11/16/96') +VERSIONID(`@(#)version.m4 8.8.4.2 (Berkeley) 11/26/96') # divert(0) # Configuration version number -DZ8.8.3`'ifdef(`confCF_VERSION', `/confCF_VERSION') +DZ8.8.4`'ifdef(`confCF_VERSION', `/confCF_VERSION') diff --git a/usr.sbin/sendmail/cf/ostype/mklinux.m4 b/usr.sbin/sendmail/cf/ostype/mklinux.m4 index 1da5928..00adedb 100644 --- a/usr.sbin/sendmail/cf/ostype/mklinux.m4 +++ b/usr.sbin/sendmail/cf/ostype/mklinux.m4 @@ -32,11 +32,11 @@ divert(-1) # OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF # SUCH DAMAGE. # -# MkLinux support contributed by Paul DeBois <dubois@primate.wisc.edu> +# MkLinux support contributed by Paul DuBois <dubois@primate.wisc.edu> # divert(0) -VERSIONID(`@(#)mklinux.m4 8.1 (Berkeley) 10/30/96') +VERSIONID(`@(#)mklinux.m4 8.2 (Berkeley) 11/17/96') ifdef(`STATUS_FILE',, `define(`STATUS_FILE', /var/log/sendmail.st)') ifdef(`PROCMAIL_MAILER_PATH',, diff --git a/usr.sbin/sendmail/contrib/etrn.pl b/usr.sbin/sendmail/contrib/etrn.pl new file mode 100755 index 0000000..b5fcc27 --- /dev/null +++ b/usr.sbin/sendmail/contrib/etrn.pl @@ -0,0 +1,301 @@ +#!/usr/local/bin/perl +'di '; +'ds 00 \\"'; +'ig 00 '; +# +# THIS PROGRAM IS ITS OWN MANUAL PAGE. INSTALL IN man & bin. +# + +# hardcoded constants, should work fine for BSD-based systems +require 'sys/socket.ph'; +$sockaddr = 'S n a4 x8'; + +# system requirements: +# must have 'hostname' program. + +############################################################################# +# Copyright (c) 1996 John T. Beck <john@beck.org> +# All rights reserved. +# +# Redistribution and use in source and binary forms, with or without +# modification, are permitted provided that the following conditions +# are met: +# 1. Redistributions of source code must retain the above copyright +# notice, this list of conditions and the following disclaimer. +# 2. Redistributions in binary form must reproduce the above copyright +# notice, this list of conditions and the following disclaimer in the +# documentation and/or other materials provided with the distribution. +# 3. All advertising materials mentioning features or use of this software +# must display the following acknowledgement: +# This product includes software developed by John T. Beck. +# 4. The name of John Beck may not be used to endorse or promote products +# derived from this software without specific prior written permission. +# +# THIS SOFTWARE IS PROVIDED BY JOHN T. BECK ``AS IS'' AND ANY EXPRESS OR +# IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES +# OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. +# IN NO EVENT SHALL JOHN T. BECK BE LIABLE FOR ANY DIRECT, INDIRECT, +# INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT +# NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, +# DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY +# OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING +# NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, +# EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. +# +# This copyright notice derived from material copyrighted by the Regents +# of the University of California. +# +# Contributions accepted. +############################################################################# +# Further disclaimer: the etrn.pl script was highly leveraged from the +# expn.pl script which is (C) 1993 David Muir Sharnoff. +############################################################################# + +$port = 'smtp'; +$av0 = $0; +select(STDERR); + +$0 = "$av0 - running hostname"; +chop($name = `hostname || uname -n`); + +$0 = "$av0 - lookup host FQDN and IP addr"; +($hostname,$aliases,$type,$len,$thisaddr) = gethostbyname($name); + +push(@hosts,$hostname); + +$0 = "$av0 - parsing sendmail.cf"; +open(CF, "</etc/sendmail.cf") || die "open /etc/sendmail.cf: $!"; +while (<CF>){ + if (/^Fw.*$/){ # look for a line starting with "Fw" + $cwfile = $_; + chop($cwfile); + $optional = /^Fw-o/; + $cwfile =~ s,^Fw[^/]*,,; # extract the file name + } +} +close(CF); + +$0 = "$av0 - reading $cwfile"; +if (open(CW, "<$cwfile")){ + while (<CW>){ + $thishost = $_; + chop($thishost); + push(@hosts, $thishost) unless $thishost =~ $hostname; + } + close(CW); +} else { + die "open $cwfile: $!" unless optional; +} + +$0 = "$av0 - parsing args"; +$usage = "Usage: $av0 [-wd] host"; +for $a (@ARGV) { + die $usage if $a eq "-"; + while ($a =~ s/^(-.*)([wd])/$1/) { + eval '$'."flag_$2 += 1"; + } + next if $a eq "-"; + die $usage if $a =~ /^-/; + $server = $a; +} +$watch = $flag_w; +$debug = $flag_d; + +die $usage unless $server; + +$0 = "$av0 - building local socket"; +($name,$aliases,$proto) = getprotobyname('tcp'); +($name,$aliases,$port) = getservbyname($port,'tcp') + unless $port =~ /^\d+/; +$this = pack($sockaddr, &AF_INET, 0, $thisaddr); + +# look it up +$0 = "$av0 - gethostbyname($server)"; + +($name,$aliases,$type,$len,$thataddr) = gethostbyname($server); + +# get a connection +$0 = "$av0 - socket to $server"; +$that = pack($sockaddr, &AF_INET, $port, $thataddr); +socket(S, &AF_INET, &SOCK_STREAM, $proto) + || die "socket: $!"; +$0 = "$av0 - bind to $server"; +bind(S, $this) + || die "bind $hostname,0: $!"; +$0 = "$av0 - connect to $server"; +print "debug = $debug server = $server\n" if $debug > 8; +if (! connect(S, $that)) { + $0 = "$av0 - $server: could not connect: $!\n"; +} +select((select(S),$| = 1)[0]); # don't buffer output to S + +# read the greeting +$0 = "$av0 - talking to $server"; +&alarm("greeting with $server",''); +while(<S>) { + alarm(0); + print if $watch; + if (/^(\d+)([- ])/) { + if ($1 != 220) { + $0 = "$av0 - bad numeric response from $server"; + &alarm("giving up after bad response from $server",''); + &read_response($2,$watch); + alarm(0); + print STDERR "$server: NOT 220 greeting: $_" + if ($debug || $watch); + } + last if ($2 eq " "); + } else { + $0 = "$av0 - bad response from $server"; + print STDERR "$server: NOT 220 greeting: $_" + if ($debug || $watch); + close(S); + } + &alarm("greeting with $server",''); +} +alarm(0); + +# if this causes problems, remove it +$0 = "$av0 - sending helo to $server"; +&alarm("sending ehlo to $server",""); +&ps("ehlo $hostname"); +$etrn_support = 0; +while(<S>) { + if (/^250([- ])ETRN(.+)$/){ + $etrn_support = 1; + } + print if $watch; + last if /^\d+ /; +} +alarm(0); + +if ($etrn_support){ + print "ETRN supported\n" if ($debug) + &alarm("sending etrn to $server",''); + while (@hosts) { + $server = shift(@hosts); + &ps("etrn $server"); + while(<S>) { + print if $watch; + last if /^\d+ /; + } + sleep(1); + } +} else { + print "\nETRN not supported\n\n" +} + +&alarm("sending 'quit' to $server",''); +$0 = "$av0 - sending 'quit' to $server"; +&ps("quit"); +while(<S>) { + print if $watch; + last if /^\d+ /; +} +close(S); +alarm(0); + +select(STDOUT); +exit(0); + +# print to the server (also to stdout, if -w) +sub ps +{ + local($p) = @_; + print ">>> $p\n" if $watch; + print S "$p\n"; +} + +sub alarm +{ + local($alarm_action,$alarm_redirect,$alarm_user) = @_; + alarm(3600); + $SIG{ALRM} = 'handle_alarm'; +} + +sub handle_alarm +{ + &giveup($alarm_redirect,"Timed out during $alarm_action",$alarm_user); +} + +# read the rest of the current smtp daemon's response (and toss it away) +sub read_response +{ + local($done,$watch) = @_; + local(@resp); + print $s if $watch; + while(($done eq "-") && ($s = <S>) && ($s =~ /^\d+([- ])/)) { + print $s if $watch; + $done = $1; + push(@resp,$s); + } + return @resp; +} +# to pass perl -w: +@tp; +$flag_a; +$flag_d; +&handle_alarm; +################### BEGIN PERL/TROFF TRANSITION +.00 ; + +'di +.nr nl 0-1 +.nr % 0 +.\\"'; __END__ +.\" ############## END PERL/TROFF TRANSITION +.TH ETRN 1 "November 16, 1996" +.AT 3 +.SH NAME +etrn \- start mail queue run +.SH SYNOPSIS +.B etrn +.RI [ -w ] +.RI [ -d ] +.IR hostname +.SH DESCRIPTION +.B etrn +will use the SMTP +.B etrn +command to start mail delivery from the host given on the command line. +.SH OPTIONS +.LP +The normal mode of operation for +.B etrn +is to do all of its work silently. +The following options make it more verbose. +It is not necessary to make it verbose to see what it is +doing because as it works, it changes its +.BR argv [0] +variable to reflect its current activity. +The +.IR -w , +watch, flag will cause +.B etrn +to show you its conversations with the mail daemons. +The +.IR -d , +debug, flag will expose many of the inner workings so that +it is possible to eliminate bugs. +.SH ENVIRONMENT +No enviroment variables are used. +.SH FILES +.B /etc/sendmail.cf +.SH SEE ALSO +.BR sendmail (8), +RFC 1985. +.SH BUGS +Not all mail daemons will implement +.B etrn . +.LP +It is assumed that you are running domain names. +.SH CREDITS +Leveraged from David Muir Sharnoff's expn.pl script. +.SH AVAILABILITY +The latest version of +.B etrn +is available in the contrib directory of the sendmail +distribution through anonymous ftp at +.IR ftp://ftp.sendmail.org/ucb/src/sendmail/ . +.SH AUTHOR +.I John T. Beck\ \ \ \ <john@beck.org> diff --git a/usr.sbin/sendmail/doc/op/op.me b/usr.sbin/sendmail/doc/op/op.me index 4bbcf88..4237497 100644 --- a/usr.sbin/sendmail/doc/op/op.me +++ b/usr.sbin/sendmail/doc/op/op.me @@ -30,7 +30,7 @@ .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF .\" SUCH DAMAGE. .\" -.\" @(#)op.me 8.98 (Berkeley) 11/16/96 +.\" @(#)op.me 8.100 (Berkeley) 12/1/96 .\" .\" eqn op.me | pic | troff -me .eh 'SMM:08-%''Sendmail Installation and Operation Guide' @@ -68,7 +68,7 @@ Eric Allman InReference, Inc. eric@Sendmail.ORG .sp -Version 8.98 +Version 8.100 .sp For Sendmail Version 8.8 .)l @@ -5845,7 +5845,7 @@ to the list of recognized vendors by editing the routine .i setvendor in .i conf.c . -Please send e-mail to sendmail@CS.Berkeley.EDU +Please send e-mail to sendmail@Sendmail.ORG to register your vendor dialect. .)f You may use @@ -6619,12 +6619,12 @@ you can set this flag to turn off special processing of UNIX-style .q "From " lines. -.ip QUEUE +.ip QUEUE\(dg This flag should be set to compile in the queueing code. If this is not set, mailers must accept the mail immediately or it will be returned to the sender. -.ip SMTP +.ip SMTP\(dg If set, the code to handle user and server SMTP will be compiled in. This is only necessary if your machine has some mailer @@ -7156,7 +7156,7 @@ If you are porting to a new environment you may need to add some new tweaks.\** .(f \**If you do, please send updates to -sendmail@CS.Berkeley.EDU. +sendmail@Sendmail.ORG. .)f .sh 2 "Configuration in src/daemon.c" .pp @@ -7686,7 +7686,7 @@ I appreciate their contribution as well. .pp Special thanks are reserved for Michael Corrigan and Christophe Wolfhugel, who besides being wonderful guinea pigs and contributors -have also consented to be added to the ``sendmail@CS.Berkeley.EDU'' list +have also consented to be added to the ``sendmail@Sendmail.ORG'' list and, by answering the bulk of the questions sent to that list, have freed me up to do other work. .++ A @@ -8150,7 +8150,7 @@ A transcript of the current session. .\"Eric Allman .\"InReference, Inc. .\".sp -.\"Version 8.98 +.\"Version 8.100 .\".ce 0 .bp 2 .rs diff --git a/usr.sbin/sendmail/src/READ_ME b/usr.sbin/sendmail/src/READ_ME index afeac1b..72e9a18 100644 --- a/usr.sbin/sendmail/src/READ_ME +++ b/usr.sbin/sendmail/src/READ_ME @@ -30,7 +30,7 @@ # OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF # SUCH DAMAGE. # -# @(#)READ_ME 8.130 (Berkeley) 11/10/96 +# @(#)READ_ME 8.132 (Berkeley) 12/1/96 # This directory contains the source files for sendmail. @@ -175,6 +175,10 @@ LDAPMAP Lightweight Directory Lookup Protocol support. You will >>> OVERRIDE calls to ndbm routines -- in particular, if you leave ndbm.h >>> in, you can find yourself using the new db package even if you don't >>> define NEWDB. +>>> +>>> Further note: DO NOT remove your existing /usr/include/ndbm.h -- +>>> you need that one. But do not install an updated ndbm.h in +>>> /usr/include, /usr/local/include, or anywhere else. If NEWDB and NDBM are defined (but not NIS), then sendmail will read NDBM format alias files, but the next time a newaliases is run the @@ -790,6 +794,23 @@ Ultrix IDENT on in the configuration file by setting the "ident" timeout to 30 seconds. +Solaris 2.5.1 (SunOS 5.5.1) + Apparently patch 103663-01 installs a new /usr/include/resolv.h + file that defines the __P macro without checking to see if it is + already defined. This causes compile warnings such as: + + In file included from daemon.c:51: + /usr/include/resolv.h:208: warning: `__P' redefined + cdefs.h:58: warning: this is the location of the previous definition + + If you are running with this patch, create a file in the + obj.SunOS.5.5.1.* directory that reads: + + #undef __P + #include "/usr/include/resolv.h" + + ... And then file a bug report with Sun. + OSF/1 If you are compiling on OSF/1 (DEC Alpha), you must use -L/usr/shlib (otherwise it core dumps on startup). You may also @@ -1377,4 +1398,4 @@ version.c The version number and information about this Eric Allman -(Version 8.130, last update 11/10/96 11:15:30) +(Version 8.132, last update 12/1/96 09:34:37) diff --git a/usr.sbin/sendmail/src/clock.c b/usr.sbin/sendmail/src/clock.c index 39862f1..281ee60 100644 --- a/usr.sbin/sendmail/src/clock.c +++ b/usr.sbin/sendmail/src/clock.c @@ -33,7 +33,7 @@ */ #ifndef lint -static char sccsid[] = "@(#)clock.c 8.13 (Berkeley) 2/21/96"; +static char sccsid[] = "@(#)clock.c 8.16 (Berkeley) 11/27/96"; #endif /* not lint */ # include "sendmail.h" @@ -98,8 +98,8 @@ setevent(intvl, func, arg) *evp = ev; if (tTd(5, 5)) - printf("setevent: intvl=%ld, for=%ld, func=%x, arg=%d, ev=%x\n", - intvl, now + intvl, func, arg, ev); + printf("setevent: intvl=%ld, for=%ld, func=%lx, arg=%d, ev=%lx\n", + intvl, now + intvl, (u_long) func, arg, (u_long) ev); tick(0); return (ev); @@ -124,7 +124,7 @@ clrevent(ev) register EVENT **evp; if (tTd(5, 5)) - printf("clrevent: ev=%x\n", ev); + printf("clrevent: ev=%lx\n", (u_long) ev); if (ev == NULL) return; @@ -191,8 +191,9 @@ tick(arg) ev = EventQueue; EventQueue = EventQueue->ev_link; if (tTd(5, 6)) - printf("tick: ev=%x, func=%x, arg=%d, pid=%d\n", ev, - ev->ev_func, ev->ev_arg, ev->ev_pid); + printf("tick: ev=%lx, func=%lx, arg=%d, pid=%d\n", + (u_long) ev, (u_long) ev->ev_func, + ev->ev_arg, ev->ev_pid); /* we must be careful in here because ev_func may not return */ f = ev->ev_func; @@ -211,17 +212,7 @@ tick(arg) /* restore signals so that we can take ticks while in ev_func */ (void) setsignal(SIGALRM, tick); -#ifdef SIG_UNBLOCK - /* unblock SIGALRM signal */ - sigemptyset(&ss); - sigaddset(&ss, SIGALRM); - sigprocmask(SIG_UNBLOCK, &ss, NULL); -#else -#if HASSIGSETMASK - /* reset 4.2bsd signal mask to allow future alarms */ - (void) sigsetmask(sigblock(0) & ~sigmask(SIGALRM)); -#endif /* HASSIGSETMASK */ -#endif /* SIG_UNBLOCK */ + (void) releasesignal(SIGALRM); /* call ev_func */ errno = olderrno; @@ -262,12 +253,17 @@ SLEEP_T sleep(intvl) unsigned int intvl; { + int was_held; + if (intvl == 0) return (SLEEP_T) 0; SleepDone = FALSE; (void) setevent((time_t) intvl, endsleep, 0); + was_held = releasesignal(SIGALRM); while (!SleepDone) pause(); + if (was_held > 0) + blocksignal(SIGALRM); return (SLEEP_T) 0; } diff --git a/usr.sbin/sendmail/src/convtime.c b/usr.sbin/sendmail/src/convtime.c index 807ae6c..65994f8 100644 --- a/usr.sbin/sendmail/src/convtime.c +++ b/usr.sbin/sendmail/src/convtime.c @@ -33,7 +33,7 @@ */ #ifndef lint -static char sccsid[] = "@(#)convtime.c 8.7 (Berkeley) 9/15/96"; +static char sccsid[] = "@(#)convtime.c 8.8 (Berkeley) 11/24/96"; #endif /* not lint */ # include "sendmail.h" @@ -149,7 +149,10 @@ pintvl(intvl, brief) hr = intvl % 24; intvl /= 24; if (brief) + { dy = intvl; + wk = 0; + } else { dy = intvl % 7; diff --git a/usr.sbin/sendmail/src/envelope.c b/usr.sbin/sendmail/src/envelope.c index 80e5ce6..6781522 100644 --- a/usr.sbin/sendmail/src/envelope.c +++ b/usr.sbin/sendmail/src/envelope.c @@ -33,7 +33,7 @@ */ #ifndef lint -static char sccsid[] = "@(#)envelope.c 8.96 (Berkeley) 11/11/96"; +static char sccsid[] = "@(#)envelope.c 8.99 (Berkeley) 12/1/96"; #endif /* not lint */ #include "sendmail.h" @@ -110,7 +110,7 @@ dropenvelope(e, fulldrop) { extern void printenvflags(); - printf("dropenvelope %x: id=", e); + printf("dropenvelope %lx: id=", (u_long) e); xputs(e->e_id); printf(", flags="); printenvflags(e); @@ -168,8 +168,8 @@ dropenvelope(e, fulldrop) queueit = TRUE; #if XDEBUG else if (bitset(QQUEUEUP, q->q_flags)) - syslog(LOG_DEBUG, "%s: q_flags = %x", - e->e_id, q->q_flags); + syslog(LOG_DEBUG, "dropenvelope: %s: q_flags = %x, paddr = %s", + e->e_id, q->q_flags, q->q_paddr); #endif /* see if a notification is needed */ @@ -349,7 +349,7 @@ simpledrop: } else if (queueit || !bitset(EF_INQUEUE, e->e_flags)) { -#ifdef QUEUE +#if QUEUE queueup(e, FALSE); #else /* QUEUE */ syserr("554 dropenvelope: queueup"); diff --git a/usr.sbin/sendmail/src/err.c b/usr.sbin/sendmail/src/err.c index 199fdd8..2e0f0b91 100644 --- a/usr.sbin/sendmail/src/err.c +++ b/usr.sbin/sendmail/src/err.c @@ -33,7 +33,7 @@ */ #ifndef lint -static char sccsid[] = "@(#)err.c 8.50 (Berkeley) 9/20/96"; +static char sccsid[] = "@(#)err.c 8.52 (Berkeley) 12/1/96"; #endif /* not lint */ # include "sendmail.h" @@ -432,7 +432,7 @@ putoutmsg(msg, holdmsg, heldmsg) else fprintf(OutChannel, "%s\n", &msg[4]); if (TrafficLogFile != NULL) - fprintf(TrafficLogFile, "%05d >>> %s\n", getpid(), + fprintf(TrafficLogFile, "%05d >>> %s\n", (int) getpid(), (OpMode == MD_SMTP || OpMode == MD_DAEMON) ? msg : &msg[4]); if (msg[3] == ' ') (void) fflush(OutChannel); @@ -631,7 +631,7 @@ errstring(errnum) extern char *sys_errlist[]; extern int sys_nerr; # endif -# ifdef SMTP +# if SMTP extern char *SmtpPhase; # endif /* SMTP */ diff --git a/usr.sbin/sendmail/src/makesendmail b/usr.sbin/sendmail/src/makesendmail index 1b266c3..838d891 100644 --- a/usr.sbin/sendmail/src/makesendmail +++ b/usr.sbin/sendmail/src/makesendmail @@ -32,7 +32,7 @@ # OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF # SUCH DAMAGE. # -# @(#)makesendmail 8.41 (Berkeley) 9/23/96 +# @(#)makesendmail 8.42 (Berkeley) 11/10/96 # # @@ -109,6 +109,13 @@ in esac # tweak operating system type and release +node=`uname -n | sed -e 's/\//-/g' -e 's/ //g'` +if [ "$os" = "$node" -a "$arch" = "i386" -a "$rel" = 3.2 -a "`uname -v`" = 2 ] +then + # old versions of SCO UNIX set uname -s the same as uname -n + os=SCO_SV +fi + case $os in DYNIX-ptx) os=PTX;; diff --git a/usr.sbin/sendmail/src/map.c b/usr.sbin/sendmail/src/map.c index 34e6fce..1b0f086 100644 --- a/usr.sbin/sendmail/src/map.c +++ b/usr.sbin/sendmail/src/map.c @@ -33,7 +33,7 @@ */ #ifndef lint -static char sccsid[] = "@(#)map.c 8.144 (Berkeley) 11/16/96"; +static char sccsid[] = "@(#)map.c 8.146 (Berkeley) 11/24/96"; #endif /* not lint */ #include "sendmail.h" @@ -1323,7 +1323,8 @@ db_map_store(map, lhs, rhs) data.size = data.size + old.size + 1; data.data = buf; if (tTd(38, 9)) - printf("db_map_store append=%s\n", data.data); + printf("db_map_store append=%s\n", + (char *) data.data); } } stat = db->put(db, &key, &data, 0); @@ -1344,7 +1345,7 @@ db_map_close(map) register DB *db = map->map_db2; if (tTd(38, 9)) - printf("db_map_close(%s, %s, %x)\n", + printf("db_map_close(%s, %s, %lx)\n", map->map_mname, map->map_file, map->map_mflags); if (bitset(MF_WRITABLE, map->map_mflags)) @@ -3406,7 +3407,7 @@ impl_map_close(map) MAP *map; { if (tTd(38, 9)) - printf("impl_map_close(%s, %s, %x)\n", + printf("impl_map_close(%s, %s, %lx)\n", map->map_mname, map->map_file, map->map_mflags); #ifdef NEWDB if (bitset(MF_IMPL_HASH, map->map_mflags)) @@ -3598,6 +3599,7 @@ prog_map_lookup(map, name, av, statp) printf(" %s", argv[i]); printf("\n"); } + (void) blocksignal(SIGCHLD); pid = prog_open(argv, &fd, CurEnv); if (pid < 0) { @@ -3646,6 +3648,7 @@ prog_map_lookup(map, name, av, statp) /* wait for the process to terminate */ close(fd); stat = waitfor(pid); + (void) releasesignal(SIGCHLD); if (stat == -1) { diff --git a/usr.sbin/sendmail/src/mci.c b/usr.sbin/sendmail/src/mci.c index 18e951a..a81e61de 100644 --- a/usr.sbin/sendmail/src/mci.c +++ b/usr.sbin/sendmail/src/mci.c @@ -33,7 +33,7 @@ */ #ifndef lint -static char sccsid[] = "@(#)mci.c 8.46 (Berkeley) 11/3/96"; +static char sccsid[] = "@(#)mci.c 8.54 (Berkeley) 12/1/96"; #endif /* not lint */ #include "sendmail.h" @@ -114,8 +114,8 @@ mci_cache(mci) mci_uncache(mcislot, TRUE); if (tTd(42, 5)) - printf("mci_cache: caching %x (%s) in slot %d\n", - mci, mci->mci_host, mcislot - MciCache); + printf("mci_cache: caching %lx (%s) in slot %d\n", + (u_long) mci, mci->mci_host, mcislot - MciCache); #ifdef LOG if (tTd(91, 100)) syslog(LOG_DEBUG, "%s: mci_cache: caching %x (%.100s) in slot %d", @@ -214,8 +214,8 @@ mci_uncache(mcislot, doquit) mci_unlock_host(mci); if (tTd(42, 5)) - printf("mci_uncache: uncaching %x (%s) from slot %d (%d)\n", - mci, mci->mci_host, mcislot - MciCache, doquit); + printf("mci_uncache: uncaching %lx (%s) from slot %d (%d)\n", + (u_long) mci, mci->mci_host, mcislot - MciCache, doquit); #ifdef LOG if (tTd(91, 100)) syslog(LOG_DEBUG, "%s: mci_uncache: uncaching %x (%.100s) from slot %d (%d)", @@ -223,7 +223,7 @@ mci_uncache(mcislot, doquit) mci, mci->mci_host, mcislot - MciCache, doquit); #endif -#ifdef SMTP +#if SMTP if (doquit) { message("Closing connection to %s", mci->mci_host); @@ -289,7 +289,7 @@ mci_get(host, m) register MCI *mci; register STAB *s; -#ifdef DAEMON +#if DAEMON extern SOCKADDR CurHostAddr; /* clear CurHostAddr so we don't get a bogus address with this name */ @@ -314,7 +314,7 @@ mci_get(host, m) mci->mci_exitstat, mci->mci_errno); } -#ifdef SMTP +#if SMTP if (mci->mci_state == MCIS_OPEN) { extern int smtpprobe __P((MCI *)); @@ -329,7 +329,7 @@ mci_get(host, m) mci->mci_exitstat = EX_OK; mci->mci_state = MCIS_CLOSED; } -# ifdef DAEMON +# if DAEMON else { /* get peer host address for logging reasons only */ @@ -377,7 +377,10 @@ mci_setstat(mci, xstat, dstat, rstat) char *dstat; char *rstat; { - mci->mci_exitstat = xstat; + /* protocol errors should never be interpreted as sticky */ + if (xstat != EX_NOTSTICKY && xstat != EX_PROTOCOL) + mci->mci_exitstat = xstat; + mci->mci_status = dstat; if (mci->mci_rstatus != NULL) free(mci->mci_rstatus); @@ -672,7 +675,6 @@ mci_load_persistent(mci) { int saveErrno = errno; FILE *fp; - int status; char fname[MAXPATHLEN+1]; if (mci == NULL) @@ -682,7 +684,7 @@ mci_load_persistent(mci) return; } - if (HostStatDir == NULL || mci->mci_host == NULL) + if (IgnoreHostStatus || HostStatDir == NULL || mci->mci_host == NULL) return; if (tTd(56, 1)) @@ -750,7 +752,7 @@ mci_read_persistent(fp, mci) syserr("mci_read_persistent: NULL mci"); if (tTd(56, 93)) { - printf("mci_read_persistent: fp=%x, mci=", fp); + printf("mci_read_persistent: fp=%lx, mci=", (u_long) fp); mci_dump(mci, FALSE); } @@ -760,6 +762,7 @@ mci_read_persistent(fp, mci) mci->mci_rstatus = NULL; rewind(fp); + ver = -1; while (fgets(buf, sizeof buf, fp) != NULL) { p = strchr(buf, '\n'); @@ -806,6 +809,8 @@ mci_read_persistent(fp, mci) return -1; } } + if (ver < 0) + return -1; return 0; } /* @@ -868,7 +873,6 @@ mci_store_persistent(mci) fflush(mci->mci_statfile); -cleanup: errno = saveErrno; return; } @@ -903,7 +907,7 @@ mci_traverse_persistent(action, pathname) { struct stat statbuf; DIR *d; - int ret = 0; + int ret; if (pathname == NULL) pathname = HostStatDir; @@ -961,13 +965,17 @@ mci_traverse_persistent(action, pathname) /* ** The following appears to be - ** necessary during purgest, since + ** necessary during purges, since ** we modify the directory structure */ if (action == mci_purge_persistent) rewinddir(d); } + + /* purge (or whatever) the directory proper */ + *--newptr = '\0'; + ret = (*action)(newpath, NULL); closedir(d); } else if (S_ISREG(statbuf.st_mode)) @@ -1031,12 +1039,14 @@ mci_print_persistent(pathname, hostname) { static int initflag = FALSE; FILE *fp; - int status; int width = Verbose ? 78 : 25; bool locked; - char *p; MCI mcib; + /* skip directories */ + if (hostname == NULL) + return 0; + if (!initflag) { initflag = TRUE; @@ -1101,6 +1111,7 @@ mci_print_persistent(pathname, hostname) ** Parameters: ** pathname -- path to the status file. ** hostname -- name of host corresponding to that file. +** NULL if this is a directory (domain). ** ** Returns: ** 0 @@ -1116,43 +1127,30 @@ mci_purge_persistent(pathname, hostname) if (tTd(56, 1)) printf("mci_purge_persistent: purging %s\n", pathname); - /* remove the file */ - if (unlink(pathname) < 0) + if (hostname != NULL) { - if (tTd(56, 2)) - printf("mci_purge_persistent: failed to unlink %s: %s\n", - pathname, errstring(errno)); - return -1; + /* remove the file */ + if (unlink(pathname) < 0) + { + if (tTd(56, 2)) + printf("mci_purge_persistent: failed to unlink %s: %s\n", + pathname, errstring(errno)); + } } - - /* - ** remove empty parent directories. - */ - - for (;;) + else { - while (*end != '/') - end--; - *(end--) = '\0'; - + /* remove the directory */ if (*end != '.') - break; + return 0; if (tTd(56, 1)) printf("mci_purge_persistent: dpurge %s\n", pathname); if (rmdir(pathname) < 0) { - if (errno == ENOENT || errno == EEXIST) - break; /* directory is not empty */ -#ifdef ENOTEMTPY - if (errno == ENOTEMPTY) - break; /* BSDism */ -#endif if (tTd(56, 2)) printf("mci_purge_persistent: rmdir %s: %s\n", pathname, errstring(errno)); - break; } } diff --git a/usr.sbin/sendmail/src/queue.c b/usr.sbin/sendmail/src/queue.c index 299a016..5d00b9f 100644 --- a/usr.sbin/sendmail/src/queue.c +++ b/usr.sbin/sendmail/src/queue.c @@ -35,17 +35,17 @@ # include "sendmail.h" #ifndef lint -#ifdef QUEUE -static char sccsid[] = "@(#)queue.c 8.131 (Berkeley) 11/8/96 (with queueing)"; +#if QUEUE +static char sccsid[] = "@(#)queue.c 8.145 (Berkeley) 12/2/96 (with queueing)"; #else -static char sccsid[] = "@(#)queue.c 8.131 (Berkeley) 11/8/96 (without queueing)"; +static char sccsid[] = "@(#)queue.c 8.145 (Berkeley) 12/2/96 (without queueing)"; #endif #endif /* not lint */ # include <errno.h> # include <dirent.h> -# ifdef QUEUE +# if QUEUE /* ** Work queue. @@ -195,7 +195,7 @@ queueup(e, announce) if (!bitset(EF_HAS_DF, e->e_flags)) { - register FILE *dfp; + register FILE *dfp = NULL; char dfname[20]; struct stat stbuf; @@ -300,8 +300,9 @@ queueup(e, announce) { #if XDEBUG if (bitset(QQUEUEUP, q->q_flags)) - syslog(LOG_DEBUG, "%s: q_flags = %x", - e->e_id, q->q_flags); + syslog(LOG_DEBUG, + "dropenvelope: %s: q_flags = %x, paddr = %s", + e->e_id, q->q_flags, q->q_paddr); #endif continue; } @@ -474,7 +475,6 @@ printctladdr(a, tfp) { char *uname; char *paddr; - register struct passwd *pw; register ADDRESS *q; uid_t uid; gid_t gid; @@ -531,9 +531,10 @@ printctladdr(a, tfp) ** forkflag -- TRUE if the queue scanning should be done in ** a child process. We double-fork so it is not our ** child and we don't have to clean up after it. +** verbose -- if TRUE, print out status information. ** ** Returns: -** none. +** TRUE if the queue run successfully began. ** ** Side Effects: ** runs things in the mail queue. @@ -541,15 +542,17 @@ printctladdr(a, tfp) ENVELOPE QueueEnvelope; /* the queue run envelope */ -void -runqueue(forkflag) +bool +runqueue(forkflag, verbose) bool forkflag; + bool verbose; { register ENVELOPE *e; int njobs; int sequenceno = 0; extern ENVELOPE BlankEnvelope; extern void clrdaemon __P((void)); + extern void runqueueevent __P((bool)); /* ** If no work will ever be selected, don't even bother reading @@ -562,15 +565,15 @@ runqueue(forkflag) { char *msg = "Skipping queue run -- load average too high"; - if (Verbose) - printf("%s\n", msg); + if (verbose) + message("458 %s\n", msg); #ifdef LOG if (LogLevel > 8) syslog(LOG_INFO, "runqueue: %s", msg); #endif if (forkflag && QueueIntvl != 0) - (void) setevent(QueueIntvl, runqueue, TRUE); - return; + (void) setevent(QueueIntvl, runqueueevent, TRUE); + return FALSE; } /* @@ -584,27 +587,49 @@ runqueue(forkflag) #ifdef SIGCHLD extern void reapchild(); + blocksignal(SIGCHLD); (void) setsignal(SIGCHLD, reapchild); #endif pid = dofork(); + if (pid == -1) + { + const char *msg = "Skipping queue run -- fork() failed"; + const char *err = errstring(errno); + + if (verbose) + message("458 %s: %s\n", msg, err); +#ifdef LOG + if (LogLevel > 8) + syslog(LOG_INFO, "runqueue: %s: %s", msg, err); +#endif + if (QueueIntvl != 0) + (void) setevent(QueueIntvl, runqueueevent, TRUE); + (void) releasesignal(SIGCHLD); + return FALSE; + } if (pid != 0) { /* parent -- pick up intermediate zombie */ #ifndef SIGCHLD (void) waitfor(pid); #else + (void) blocksignal(SIGALRM); proc_list_add(pid); + (void) releasesignal(SIGALRM); + releasesignal(SIGCHLD); #endif /* SIGCHLD */ if (QueueIntvl != 0) - (void) setevent(QueueIntvl, runqueue, TRUE); - return; + (void) setevent(QueueIntvl, runqueueevent, TRUE); + return TRUE; } /* child -- double fork and clean up signals */ + proc_list_clear(); #ifndef SIGCHLD if (fork() != 0) exit(EX_OK); #else /* SIGCHLD */ + releasesignal(SIGCHLD); (void) setsignal(SIGCHLD, SIG_DFL); #endif /* SIGCHLD */ (void) setsignal(SIGHUP, intsig); @@ -623,7 +648,7 @@ runqueue(forkflag) ** Release any resources used by the daemon code. */ -# ifdef DAEMON +# if DAEMON clrdaemon(); # endif /* DAEMON */ @@ -660,7 +685,10 @@ runqueue(forkflag) if (QueueLimitId != NULL || QueueLimitSender != NULL || QueueLimitRecipient != NULL) - HostStatDir = NULL; + { + IgnoreHostStatus = TRUE; + MinQueueAge = 0; + } /* ** Start making passes through the queue. @@ -719,6 +747,20 @@ runqueue(forkflag) /* exit without the usual cleanup */ e->e_id = NULL; finis(); + /*NOTREACHED*/ + return TRUE; +} + + +/* +** RUNQUEUEEVENT -- stub for use in setevent +*/ + +void +runqueueevent(forkflag) + bool forkflag; +{ + (void) runqueue(forkflag, FALSE); } /* ** ORDERQ -- order the work queue. @@ -1257,7 +1299,7 @@ workcmpf3(a, b) if (a->w_ctime > b->w_ctime) return 1; else if (a->w_ctime < b->w_ctime) - return 1; + return -1; else return 0; } @@ -1340,6 +1382,7 @@ dowork(id, forkflag, requeueflag, e) disconnect(1, e); OpMode = MD_DELIVER; } + setproctitle("%s: from queue", id); # ifdef LOG if (LogLevel > 76) syslog(LOG_DEBUG, "%s: dowork, pid=%d", e->e_id, @@ -2054,7 +2097,8 @@ queuename(e, type) e->e_id = newstr(&qf[2]); define('i', e->e_id, e); if (tTd(7, 1)) - printf("queuename: assigned id %s, env=%x\n", e->e_id, e); + printf("queuename: assigned id %s, env=%lx\n", + e->e_id, (u_long) e); if (tTd(7, 9)) { printf(" lockfd="); diff --git a/usr.sbin/sendmail/src/stab.c b/usr.sbin/sendmail/src/stab.c index 5f707b1..a9d8736 100644 --- a/usr.sbin/sendmail/src/stab.c +++ b/usr.sbin/sendmail/src/stab.c @@ -33,7 +33,7 @@ */ #ifndef lint -static char sccsid[] = "@(#)stab.c 8.9 (Berkeley) 10/17/96"; +static char sccsid[] = "@(#)stab.c 8.10 (Berkeley) 11/23/96"; #endif /* not lint */ # include "sendmail.h" @@ -131,7 +131,7 @@ stab(name, type, op) printf("entered\n"); /* determine size of new entry */ -#ifdef FFR_MEMORY_MISER +#ifdef _FFR_MEMORY_MISER if (type >= ST_MCI) len = sizeof s->s_mci; else diff --git a/usr.sbin/sendmail/src/version.c b/usr.sbin/sendmail/src/version.c index 8a53f29..617e11a 100644 --- a/usr.sbin/sendmail/src/version.c +++ b/usr.sbin/sendmail/src/version.c @@ -33,7 +33,7 @@ */ #ifndef lint -static char sccsid[] = "@(#)version.c 8.8.3.2 (Berkeley) 11/16/96"; +static char sccsid[] = "@(#)version.c 8.8.4.4 (Berkeley) 12/2/96"; #endif /* not lint */ -char Version[] = "8.8.3"; +char Version[] = "8.8.4"; diff --git a/usr.sbin/sendmail/test/Results b/usr.sbin/sendmail/test/Results index 9645d73..e889cad 100644 --- a/usr.sbin/sendmail/test/Results +++ b/usr.sbin/sendmail/test/Results @@ -25,6 +25,7 @@ Solaris 2.1 Solaris 2.2 FAIL 93.07.19 Bill Wisner Solaris 2.3 FAIL 95.11.22 Scott J. Kramer <sjk@lux.com> Solaris 2.5 OK 96.02.29 Carson Gaspar <carson@lehman.com> +Solaris 2.5.1 OK 96.11.29 Gregory Neil Shapiro <gshapiro@wpi.edu> OSF/1 T1.3-4 OK 93.07.19 eric (on DEC Alpha) OSF/1 1.3 OK 94.12.10 Jeff A. Earickson (on Intel Paragon) @@ -75,6 +76,7 @@ OPSYS VERSION STATUS DATE TESTER/NOTES Solaris 2.3 OK 95.11.22 Scott J. Kramer <sjk@lux.com> Solaris 2.4 OK 95.09.22 Thomas 'Mike' Michlmayr <mike@cosy.sbg.ac.at> Solaris 2.5 OK 96.02.29 Carson Gaspar <carson@lehman.com> +Solaris 2.5.1 OK 96.11.29 Gregory Neil Shapiro <gshapiro@wpi.edu> Linux 1.2.13 FAIL 95.11.02 Sven Neuhaus <sven@ping.de> Linux 2.0.17 FAIL 96.09.03 Horst von Brand <vonbrand@sleipnir.valparaiso.cl> |