Put the "@:@" trick on the "a" option. Also, move TrustedUsers into
authorEric Allman <eric@ucbvax.Berkeley.EDU>
Fri, 29 Oct 1982 09:41:39 +0000 (01:41 -0800)
committerEric Allman <eric@ucbvax.Berkeley.EDU>
Fri, 29 Oct 1982 09:41:39 +0000 (01:41 -0800)
sendmail.h (it should have gone here in the first place!)

SCCS-mr: usr.sbin/sendmail/src/alias.c 039,, 027
SCCS-mr: usr.sbin/sendmail/src/sendmail.h 039,, 027
SCCS-mr: usr.sbin/sendmail/src/version.c 039, 027
SCCS-mr: usr.sbin/sendmail/src/readcf.c 039,, 027
SCCS-vsn: usr.sbin/sendmail/src/alias.c 3.39
SCCS-vsn: usr.sbin/sendmail/src/sendmail.h 3.93
SCCS-vsn: usr.sbin/sendmail/src/version.c 3.230
SCCS-vsn: usr.sbin/sendmail/src/readcf.c 3.39

usr/src/usr.sbin/sendmail/src/alias.c
usr/src/usr.sbin/sendmail/src/readcf.c
usr/src/usr.sbin/sendmail/src/sendmail.h
usr/src/usr.sbin/sendmail/src/version.c

index c75e486..a51a9b4 100644 (file)
@@ -5,9 +5,9 @@
 # include "sendmail.h"
 
 # ifdef DBM
 # include "sendmail.h"
 
 # ifdef DBM
-SCCSID(@(#)alias.c     3.38            %G%     (with DBM));
+SCCSID(@(#)alias.c     3.39            %G%     (with DBM));
 # else DBM
 # else DBM
-SCCSID(@(#)alias.c     3.38            %G%     (without DBM));
+SCCSID(@(#)alias.c     3.39            %G%     (without DBM));
 # endif DBM
 
 /*
 # endif DBM
 
 /*
@@ -177,6 +177,7 @@ initaliases(aliasfile, init)
                return;
        }
 
                return;
        }
 
+# ifdef DBM
        /*
        **  Check to see that the alias file is complete.
        **      If not, we will assume that someone died, and it is up
        /*
        **  Check to see that the alias file is complete.
        **      If not, we will assume that someone died, and it is up
@@ -184,10 +185,10 @@ initaliases(aliasfile, init)
        */
 
        dbminit(aliasfile);
        */
 
        dbminit(aliasfile);
-       for (atcnt = 10; !init && atcnt-- >= 0 && aliaslookup("@") == NULL; )
+       atcnt = 10;
+       while (SafeAlias && !init && atcnt-- >= 0 && aliaslookup("@") == NULL)
                sleep(30);
 
                sleep(30);
 
-# ifdef DBM
        /*
        **  See if the DBM version of the file is out of date with
        **  the text version.  If so, go into 'init' mode automatically.
        /*
        **  See if the DBM version of the file is out of date with
        **  the text version.  If so, go into 'init' mode automatically.
index 7a150a3..350cb2f 100644 (file)
@@ -1,6 +1,6 @@
 # include "sendmail.h"
 
 # include "sendmail.h"
 
-SCCSID(@(#)readcf.c    3.38            %G%);
+SCCSID(@(#)readcf.c    3.39            %G%);
 
 /*
 **  READCF -- read control file.
 
 /*
 **  READCF -- read control file.
@@ -45,10 +45,6 @@ SCCSID(@(#)readcf.c  3.38            %G%);
 **             Builds several internal tables.
 */
 
 **             Builds several internal tables.
 */
 
-# define MAXTRUST      10              /* maximum number of trusted users */
-
-char   *TrustedUsers[MAXTRUST+1];      /* list of trusted users */
-
 readcf(cfname, safe)
        char *cfname;
        bool safe;
 readcf(cfname, safe)
        char *cfname;
        bool safe;
@@ -626,7 +622,7 @@ setoption(opt, val, safe, sticky)
                tval = convtime(val);
        else if (index("gLu", opt) != NULL)
                ival = atoi(val);
                tval = convtime(val);
        else if (index("gLu", opt) != NULL)
                ival = atoi(val);
-       else if (index("cfimosv", opt) != NULL)
+       else if (index("acfimosv", opt) != NULL)
                bval = atobool(val);
        else if (index("be", opt) != NULL)
                /* do nothing */ ;
                bval = atobool(val);
        else if (index("be", opt) != NULL)
                /* do nothing */ ;
@@ -647,6 +643,10 @@ setoption(opt, val, safe, sticky)
                        AliasFile = "aliases";
                break;
 
                        AliasFile = "aliases";
                break;
 
+         case 'a':             /* look for "@:@" in alias file */
+               SafeAlias = bval;
+               break;
+
          case 'b':             /* operations mode */
                Mode = *val;
                switch (Mode)
          case 'b':             /* operations mode */
                Mode = *val;
                switch (Mode)
index 4741321..b7bab25 100644 (file)
@@ -7,7 +7,7 @@
 # ifdef _DEFINE
 # define EXTERN
 # ifndef lint
 # ifdef _DEFINE
 # define EXTERN
 # ifndef lint
-static char SmailSccsId[] =    "@(#)sendmail.h 3.92            %G%";
+static char SmailSccsId[] =    "@(#)sendmail.h 3.93            %G%";
 # endif lint
 # else  _DEFINE
 # define EXTERN extern
 # endif lint
 # else  _DEFINE
 # define EXTERN extern
@@ -36,6 +36,7 @@ static char SmailSccsId[] =   "@(#)sendmail.h 3.92            %G%";
 # define MAXMAILERS    25              /* maximum mailers known to system */
 # define MAXRWSETS     30              /* max # of sets of rewriting rules */
 # define MAXPRIORITIES 25              /* max values for Precedence: field */
 # define MAXMAILERS    25              /* maximum mailers known to system */
 # define MAXRWSETS     30              /* max # of sets of rewriting rules */
 # define MAXPRIORITIES 25              /* max values for Precedence: field */
+# define MAXTRUST      30              /* maximum number of trusted users */
 # define SPACESUB      ('.'|0200)      /* substitution for <lwsp> */
 \f/*
 **  Address structure.
 # define SPACESUB      ('.'|0200)      /* substitution for <lwsp> */
 \f/*
 **  Address structure.
@@ -407,6 +408,7 @@ EXTERN bool ArpaMode;       /* set if running arpanet protocol */
 EXTERN bool    NoConnect;      /* don't connect to non-local mailers */
 EXTERN bool    FatalErrors;    /* set if fatal errors during processing */
 EXTERN bool    SuperSafe;      /* be extra careful, even if expensive */
 EXTERN bool    NoConnect;      /* don't connect to non-local mailers */
 EXTERN bool    FatalErrors;    /* set if fatal errors during processing */
 EXTERN bool    SuperSafe;      /* be extra careful, even if expensive */
+EXTERN bool    SafeAlias;      /* alias file must have "@:@" to be complete */
 EXTERN time_t  TimeOut;        /* time until timeout */
 EXTERN FILE    *InChannel;     /* input connection */
 EXTERN FILE    *OutChannel;    /* output connection */
 EXTERN time_t  TimeOut;        /* time until timeout */
 EXTERN FILE    *InChannel;     /* input connection */
 EXTERN FILE    *OutChannel;    /* output connection */
@@ -432,6 +434,7 @@ EXTERN char *AliasFile;     /* location of alias file */
 EXTERN char    *HelpFile;      /* location of SMTP help file */
 EXTERN char    *StatFile;      /* location of statistics summary */
 EXTERN char    *QueueDir;      /* location of queue directory */
 EXTERN char    *HelpFile;      /* location of SMTP help file */
 EXTERN char    *StatFile;      /* location of statistics summary */
 EXTERN char    *QueueDir;      /* location of queue directory */
+EXTERN char    *TrustedUsers[MAXTRUST+1];      /* list of trusted users */
 EXTERN jmp_buf TopFrame;       /* branch-to-top-of-loop-on-error frame */
 EXTERN bool    QuickAbort;     /*  .... but only if we want a quick abort */
 extern char    *XcriptFile;    /* template for Transcript [conf.c] */
 EXTERN jmp_buf TopFrame;       /* branch-to-top-of-loop-on-error frame */
 EXTERN bool    QuickAbort;     /*  .... but only if we want a quick abort */
 extern char    *XcriptFile;    /* template for Transcript [conf.c] */
index 929b06d..dcc85bc 100644 (file)
@@ -1,5 +1,5 @@
 # ifndef lint
 # ifndef lint
-static char    SccsId[] = "@(#)SendMail version 3.229 of %G%";
+static char    SccsId[] = "@(#)SendMail version 3.230 of %G%";
 # endif lint
 
 # endif lint
 
-char   Version[] = "3.229 [%G%]";
+char   Version[] = "3.230 [%G%]";