[alt.sources] Anonymous Contact Service software v1.1, Part01/08

csu@alembic.acs.com (Dave Mack) (07/16/90)

This is the second distribution of the Anonymous Contact Service
software. The distribution consists of 8 shar files. This will
(hopefully) be the last full distribution of the system - all
future versions will be distributed as patches. The patchlevel of
this version is 1.

The ACS software provides a mechanism for posting anonymous articles,
for receiving replies to those articles which are also anonymous, and
permits prolonged anonymous conversations in which neither writer knows
the other's actual e-mail address.

This software is currently being used to provide an anonymous personals
service in alt.personals.

Dave Mack
csu@alembic.ACS.COM

#! /bin/sh
# This is a shell archive.  Remove anything before this line, then unpack
# it by saving it into a file and typing "sh file".  To overwrite existing
# files, type "sh file -c".  You can also feed this as standard input via
# unshar, or by typing "sh <file", e.g..  If this archive is complete, you
# will see the following message at the end:
#		"End of archive 1 (of 8)."
# Contents:  CHANGES MANIFEST README addalias aliases anon-ping.c
#   anon-post.c anon-reply.c config.perl crontab dupalias fixit
#   listr2a mailer mailer/Contacts mailer/Makefile mailer/Makefile.acs
#   mailer/bindings mailer/lcasep.8 mailer/lcasep.c mailer/mkfnames.8
#   mailer/mkfnames.sh mailer/patchlevel mailer/pathproc.8
#   mailer/pathproc.sh mailer/smail.prompt mailer/str.c
#   mailer/sysexits.h nextalias patchlevel rmbyaddr rmbyalias
# Wrapped by csu@alembic on Sun Jul 15 12:46:40 1990
PATH=/bin:/usr/bin:/usr/ucb ; export PATH
if test -f 'CHANGES' -a "${1}" != "-c" ; then 
  echo shar: Will not clobber existing file \"'CHANGES'\"
else
echo shar: Extracting \"'CHANGES'\" \(773 characters\)
sed "s/^X//" >'CHANGES' <<'END_OF_FILE'
XAnonymous Contact Service software changes
X
X1.0 - 1.1
X
XChanged file names to bring them under the
X14 character limit some inferior operating systems are still saddled
Xwith, and reposted as shar files because some inferior operating
Xsystems don't have the necessary tools to deal with uuencoded compressed
Xtar files. The net can thank Rich Salz and his makekit package for the
Xlatter concession to antiquity.
X
XModified unspool to dump anything after a line containing "---" as 
Xsignature, in addition to the standard "^-- $" signature tag.
X
XAdded logging to rmby{addr,alias} so accidental removals can be undone.
X
XChanged the Makefile to make the perl scripts executable when a "make all"
Xis done. This is necessary since the package is now being distributed as
Xshar files.
END_OF_FILE
if test 773 -ne `wc -c <'CHANGES'`; then
    echo shar: \"'CHANGES'\" unpacked with wrong size!
fi
# end of 'CHANGES'
fi
if test -f 'MANIFEST' -a "${1}" != "-c" ; then 
  echo shar: Will not clobber existing file \"'MANIFEST'\"
else
echo shar: Extracting \"'MANIFEST'\" \(2036 characters\)
sed "s/^X//" >'MANIFEST' <<'END_OF_FILE'
X   File Name		Archive #	Description
X-----------------------------------------------------------
X CHANGES                    1	
X INSTALL                    2	
X Intro                      5	
X Intro-short                2	
X Intro2                     5	
X MANIFEST                   1	This shipping list
X Makefile                   2	
X README                     1	
X addalias                   1	
X aliases                    1	
X anon-ping.c                1	
X anon-post.c                1	
X anon-reply.c               1	
X config.perl                1	
X crontab                    1	
X dupalias                   1	
X fixit                      1	
X listr2a                    1	
X mailer                     1	
X mailer/Contacts            1	
X mailer/Domains             5	
X mailer/Flow.Diagram        2	
X mailer/Install             2	
X mailer/Makefile            1	
X mailer/Makefile.acs        1	
X mailer/Read.Me             4	
X mailer/alias.c             6	
X mailer/aliases.8           3	
X mailer/bindings            1	
X mailer/defs.h              6	
X mailer/deliver.c           7	
X mailer/getopt.c            2	
X mailer/getpath.c           2	
X mailer/headers.c           8	
X mailer/lcasep.8            1	
X mailer/lcasep.c            1	
X mailer/main.c              3	
X mailer/make.cf.sh          2	
X mailer/map.c               2	
X mailer/misc.c              3	
X mailer/mkfnames.8          1	
X mailer/mkfnames.sh         1	
X mailer/nptx.8              2	
X mailer/nptx.c              3	
X mailer/patch.dotname       2	
X mailer/patchlevel          1	
X mailer/pathproc.8          1	
X mailer/pathproc.sh         1	
X mailer/paths.8             2	
X mailer/pw.c                3	
X mailer/resolve.c           4	
X mailer/smail.8             6	
X mailer/smail.prompt        1	
X mailer/str.c               1	
X mailer/svbinmail.c         2	
X mailer/sysexits.h          1	
X mailer/template.cf         4	
X nextalias                  1	
X patchlevel                 1	
X rmbyaddr                   1	
X rmbyalias                  1	
X unspool                    7	
END_OF_FILE
if test 2036 -ne `wc -c <'MANIFEST'`; then
    echo shar: \"'MANIFEST'\" unpacked with wrong size!
fi
# end of 'MANIFEST'
fi
if test -f 'README' -a "${1}" != "-c" ; then 
  echo shar: Will not clobber existing file \"'README'\"
else
echo shar: Extracting \"'README'\" \(5783 characters\)
sed "s/^X//" >'README' <<'END_OF_FILE'
XThis package contains the beta distribution of the Anonymous Contact
XService (ACS) software. The software has been tested on only one system
X(a Sun-2/120 running SunOS3.4.) YOU USE IT ENTIRELY AT YOUR OWN RISK.
XThis software is hereby placed in the public domain EXCEPT for
Xsmail2.5, which carries its own copyright and distribution restrictions.
XSee the documentation in the mailer directory.
X
XThe ACS, in its current configuration, requires a system which has
Xeither the dbm or ndbm libraries, Perl3.0pl18, smail2.5 and its mutant
Xbrother, acsmail (provided in the distribution), a mail transport
Xagent which deals with /usr/lib/aliases properly (sendmail works,
Xsmail2.5 and smail3.1.18 probably do), elm2.3 (but it should be 
Xeasy to adapt other mail UA's to handle the bounced message handling),
Xand a news package which includes "inews" - Cnews works, B2.11.19
Xprobably works.
X
XWHAT IT DOES
X
XThe ACS provides two primary functions - it allows users to anonymously
Xpost articles, and to receive replies to those articles in which the
Xreplying party is also anonymous (the latter function extends to
Xgeneral two-way e-mail conversations in which neither party knows the
Xother's actual e-mail address.) Each user who posts an anonymous
Xarticle or sends an anonymous e-mail message is assigned an alias.
XThe site running the ACS software acts as the nameserver for those
Xaliases in a double-blind fashion. An e-mail message sent to
X"acs-post@<server-machine>" is treated as an article to be posted
Xanonymously. The ACS software assigns the user an alias (if they
Xdon't already have one), and rewrites the article header so that
Xthe message appears to come from "acs-alias@<server-machine>" and
Xposts the message to alt.personals. Anonymous e-mail messages come
Xto "acs-alias@<server-machine>" and are intercepted by the sendmail
X(or equiv.) aliasing feature. The sender's e-mail address is replaced
Xby an alias, the recipient's alias is replaced by their actual e-mail
Xaddress, and the message is forwarded.
X
XFor additional information on what the ACS does, read the "Intro"
Xdocument in this distribution.
X
XHOW IT WORKS
X
X/usr/lib/aliases contains aliases for acs-ping, acs-post, and each
Xanonymous user who has used the system. These aliases are pipes into
Xthree suid root programs in the ACS source directory: anon-ping,
Xanon-post, and anon-reply. These programs dump their stdin into
Xuniquely named files in the ACS spool directory, except for anon-reply,
Xwhich writes the user's alias into the first line of the spool file
Xbefore dumping its stdin into the spool file. The files in the spool
Xdirectory are named PING#####, POST#####, or REP#####, depending on
Xwhich type of message they contain. The ##### is the pid of the
Xinstance of anon-whatever that does the writing. (NOTE: there is a
Xpotential bug here: on a very fast system which wraps around on its
Xprocess ids very quickly and doesn't unspool the incoming messages
Xfrequently enough, older messages could be overwritten. Some better
X"unique" file naming strategy is needed.)
X
XThe workhorse of the system is a Perl script called "unspool". This
Xis invoked by cron at regular intervals (I run it every 15 minutes)
Xto scavenge the contents of the spool directory and process the files
Xaccording to their type. unspool processes the files in the spool
Xdirectory by their type (REP, POST, then PING). For each message,
Xit extracts the user's address from the From: line, and checks to
Xsee if that user has already been registered with the system. It does
Xthis using the address as the key to a dbm database called "real2alias".
XThe data corresponding to the key is the user's alias. If the user
Xhas not been registered, unspool creates an alias for the user of the
Xform "acs-..." where "..." is a sequential entry starting with "a" and
Xincrementing to "zzz" and beyond. (The last assigned alias is stored in
Xthe file "alias-index" which unspool reads, increments, and writes as
Xneeded.) unspool then adds the address:alias record to the real2alias
Xdatabase, and appends a line for that user to the /usr/lib/aliases file
Xof the form 'acs-xxx:"|/usr/personals/anon-reply acs-xxx"'.
X
XFor additional information on how unspool works, see the documentation
Xin the code.
X
XADMINISTRATIVE FUNCTIONS
X
XThere are a number of scripts in this directory to help the ACS
Xadministrator keep things running smoothly. They are:
X
Xaddalias - add a new record to the real2alias database.
X
Xrmbyalias - remove a database record given the user's alias.
X
Xrmbyaddr - remove a database record given a user's address.
X
Xdupalias - check the database for duplicate aliases. This is needed
X           if you accidentally delete unspool's lock file and 
X           another instance of unspool starts up. 
X
Xfixit - a modified version of dbmrmbyalias.perl which creates
X             a new instance of the database with one record removed.
X
Xlistr2a - write the contents of real2alias on stdout. Each line
X          contains a record of the form "alias:address".
X
Xnextalias - a pretty much useless way of finding out what the
X                 next alias assigned will be. It's easier to cat
X                 alias-index.
X
XMISCELLANEOUS
X
XThis directory includes three "Intro" files, which describe how to
Xuse the ACS. Each one includes a header so they can be posted simply
Xby typing "inews -h < <Intro-file>". While the config.perl script
Xprocesses them to change references to my system, you'll still
Xprobably need to tune them a bit for your purposes. "Intro" is the
Xlong (definitive) version of the file, which is posted to several
Xnewsgroups. "Intro2" is the same thing, but is only posted to
Xalt.personals. "Intro-short" is the short form version of the
Xinstructions.
X
XDave Mack
X{csu,acs-admin,acs-a}@alembic.ACS.COM
Xuunet!alembic!{csu,acs-admin,acs-a}
END_OF_FILE
if test 5783 -ne `wc -c <'README'`; then
    echo shar: \"'README'\" unpacked with wrong size!
fi
# end of 'README'
fi
if test -f 'addalias' -a "${1}" != "-c" ; then 
  echo shar: Will not clobber existing file \"'addalias'\"
else
echo shar: Extracting \"'addalias'\" \(421 characters\)
sed "s/^X//" >'addalias' <<'END_OF_FILE'
X#! /usr/local/bin/perl
X# 
X# addalias adds an entry to the real2addr database given the address
X# and alias
X#
X# Usage: addalias <address> <alias>
X#
Xif ( $#ARGV != 1 ) {
X	print STDERR "Usage: addalias <address> <alias>\n";
X	exit(1);
X}
X
X$address = $ARGV[0];
X$alias = $ARGV[1];
X
Xdbmopen(r2a,"/usr/personals/real2alias",0600) 
X	|| die "$0: can't dbmopen real2alias: $!\n";
X
X$r2a{"$address"} = $alias;
X
Xdbmclose(r2a);
Xexit(0);
END_OF_FILE
if test 421 -ne `wc -c <'addalias'`; then
    echo shar: \"'addalias'\" unpacked with wrong size!
fi
chmod +x 'addalias'
# end of 'addalias'
fi
if test -f 'aliases' -a "${1}" != "-c" ; then 
  echo shar: Will not clobber existing file \"'aliases'\"
else
echo shar: Extracting \"'aliases'\" \(91 characters\)
sed "s/^X//" >'aliases' <<'END_OF_FILE'
Xacs-admin:root
Xacs-post: "|/usr/personals/anon-post"
Xacs-ping: "|/usr/personals/anon-ping"
END_OF_FILE
if test 91 -ne `wc -c <'aliases'`; then
    echo shar: \"'aliases'\" unpacked with wrong size!
fi
# end of 'aliases'
fi
if test -f 'anon-ping.c' -a "${1}" != "-c" ; then 
  echo shar: Will not clobber existing file \"'anon-ping.c'\"
else
echo shar: Extracting \"'anon-ping.c'\" \(880 characters\)
sed "s/^X//" >'anon-ping.c' <<'END_OF_FILE'
X/* anon-ping.c - put ping messages in ACS spool directory */
X#include <stdio.h>
X#include <sys/file.h>
X#include <errno.h>
Xmain()
X{
X  char buf[512];
X  char fname[40];
X  char pbuf[6];
X  int mypid, fd, rdlen;
X  /* run as root */
X  if (setuid(0) != 0 ) {
X    perror("couldn\'t setuid root: ");
X    exit(1);
X  }
X  /* build the filename */
X  strcpy(fname,"/usr/personals/spool/PING");
X  sprintf(pbuf,"%05d",getpid());
X  strcat(fname,pbuf);
X  while (access(fname,F_OK) == 0) {
X    strcat(fname,".");
X    if (strlen(fname) == 39 ) break;
X  }
X  if ((fd = open(fname,O_WRONLY|O_CREAT,0600)) == -1) {
X    perror("can\'t open PING tmp file: ");
X    exit(1);
X  }
X  /* read the message on stdin and write it to fd */
X  while ( rdlen = read(0,buf,512) ) {
X    if (write(fd,buf,rdlen) != rdlen) {
X      perror("write to PING tmp file failed: ");
X      exit(1);
X    }
X  }
X  close(fd);
X  exit(0);
X}
END_OF_FILE
if test 880 -ne `wc -c <'anon-ping.c'`; then
    echo shar: \"'anon-ping.c'\" unpacked with wrong size!
fi
# end of 'anon-ping.c'
fi
if test -f 'anon-post.c' -a "${1}" != "-c" ; then 
  echo shar: Will not clobber existing file \"'anon-post.c'\"
else
echo shar: Extracting \"'anon-post.c'\" \(888 characters\)
sed "s/^X//" >'anon-post.c' <<'END_OF_FILE'
X/* anon-post.c - put articles to be posted in ACS spool directory */
X#include <stdio.h>
X#include <sys/file.h>
X#include <errno.h>
Xmain()
X{
X  char buf[512];
X  char fname[40];
X  char pbuf[6];
X  int mypid, fd, rdlen;
X  /* run as root */
X  if (setuid(0) != 0 ) {
X    perror("couldn\'t setuid root: ");
X    exit(1);
X  }
X  /* build the filename */
X  strcpy(fname,"/usr/personals/spool/POST");
X  sprintf(pbuf,"%05d",getpid());
X  strcat(fname,pbuf);
X  while (access(fname,F_OK) == 0) {
X    strcat(fname,".");
X    if (strlen(fname) == 39 ) break;
X  }
X  if ((fd = open(fname,O_WRONLY|O_CREAT,0600)) == -1) {
X    perror("can\'t open POST tmp file: ");
X    exit(1);
X  }
X  /* read the message on stdin and write it to fd */
X  while ( rdlen = read(0,buf,512) ) {
X    if (write(fd,buf,rdlen) != rdlen) {
X      perror("write to POST tmp file failed: ");
X      exit(1);
X    }
X  }
X  close(fd);
X  exit(0);
X}
END_OF_FILE
if test 888 -ne `wc -c <'anon-post.c'`; then
    echo shar: \"'anon-post.c'\" unpacked with wrong size!
fi
# end of 'anon-post.c'
fi
if test -f 'anon-reply.c' -a "${1}" != "-c" ; then 
  echo shar: Will not clobber existing file \"'anon-reply.c'\"
else
echo shar: Extracting \"'anon-reply.c'\" \(1070 characters\)
sed "s/^X//" >'anon-reply.c' <<'END_OF_FILE'
X/* anon-reply.c - put replies to be sent in ACS spool directory */
X#include <stdio.h>
X#include <sys/file.h>
X#include <errno.h>
Xmain(argc,argv)
Xint argc;
Xchar *argv[];
X{
X  char buf[512];
X  char fname[40];
X  char pbuf[6];
X  int mypid, fd, rdlen;
X  if ( argc != 2 ) {
X    exit(1);
X  }
X  /* run as root */
X  if (setuid(0) != 0 ) {
X    perror("couldn\'t setuid root: ");
X    exit(1);
X  }
X  /* build the filename */
X  strcpy(fname,"/usr/personals/spool/REP");
X  sprintf(pbuf,"%05d",getpid());
X  strcat(fname,pbuf);
X  while (access(fname,F_OK) == 0) {
X    strcat(fname,".");
X    if (strlen(fname) == 39 ) break;
X  }
X  if ((fd = open(fname,O_WRONLY|O_CREAT,0600)) == -1) {
X    perror("can\'t open REP tmp file: ");
X    exit(1);
X  }
X  /* write the alias in as the first line in the file */
X  write(fd,argv[1],strlen(argv[1]));
X  write(fd,"\012",1);
X  /* read the message on stdin and write it to fd */
X  while ( rdlen = read(0,buf,512) ) {
X    if (write(fd,buf,rdlen) != rdlen) {
X      perror("write to REP tmp file failed: ");
X      exit(1);
X    }
X  }
X  close(fd);
X  exit(0);
X}
END_OF_FILE
if test 1070 -ne `wc -c <'anon-reply.c'`; then
    echo shar: \"'anon-reply.c'\" unpacked with wrong size!
fi
# end of 'anon-reply.c'
fi
if test -f 'config.perl' -a "${1}" != "-c" ; then 
  echo shar: Will not clobber existing file \"'config.perl'\"
else
echo shar: Extracting \"'config.perl'\" \(1121 characters\)
sed "s/^X//" >'config.perl' <<'END_OF_FILE'
X#! /usr/local/bin/perl
X#
X# Modify the next three lines to suit your configuration
X$NEWBASEDIR = '/usr/tpers';		# absolute pathname of directory
X					# containing ACS source
X$NEWHOSTNAME = 'smersh';		# hostname of your system
X$NEWDOMAIN = '.kgb.comm';		# domain name of your system
X#
X# END OF CONFIGURABLE VARIABLES
X#
X$OLDBASEDIR = '/usr/personals';
X$OLDHOSTNAME = 'alembic';
X$OLDDOMAIN = '.ACS.COM';
X@FILELIST = ( 'anon-ping.c', 'anon-post.c','anon-reply.c','addalias',
X		'rmbyaddr','rmbyalias','fixit','listr2a',
X		'nextalias','unspool','crontab','aliases','Intro',
X		'Intro2','Intro-short','dupalias' ) ;
X
X
Xforeach $filename (@FILELIST) {
X	open(IN, "<$filename") || ((warn "Can't open $filename\n"), next);
X	@lines = <IN>;
X	for ( $line = 0; $line <= $#lines; $line++ ) {
X		$lines[$line] =~ s|$OLDBASEDIR|$NEWBASEDIR|go;
X		$lines[$line] =~ s|$OLDHOSTNAME|$NEWHOSTNAME|go;
X		$lines[$line] =~ s|$OLDDOMAIN|$NEWDOMAIN|go;
X	}
X	rename($filename,"$filename.bak");
X	open(OUT,">$filename") || ((warn "Can't open $filename\n"), next);
X	print OUT @lines;
X	close(OUT);
X	close(IN);
X	print STDERR "$filename reconfigured\n";
X}
Xexit;
END_OF_FILE
if test 1121 -ne `wc -c <'config.perl'`; then
    echo shar: \"'config.perl'\" unpacked with wrong size!
fi
chmod +x 'config.perl'
# end of 'config.perl'
fi
if test -f 'crontab' -a "${1}" != "-c" ; then 
  echo shar: Will not clobber existing file \"'crontab'\"
else
echo shar: Extracting \"'crontab'\" \(170 characters\)
sed "s/^X//" >'crontab' <<'END_OF_FILE'
X# Post the ACS Intro message
X20 20 18 * * 'inews -h < /usr/personals/Intro'
X40 20 * * 7 'inews -h < /usr/personals/Intro-short'
X0,15,30,45 * * * * /usr/personals/unspool
END_OF_FILE
if test 170 -ne `wc -c <'crontab'`; then
    echo shar: \"'crontab'\" unpacked with wrong size!
fi
# end of 'crontab'
fi
if test -f 'dupalias' -a "${1}" != "-c" ; then 
  echo shar: Will not clobber existing file \"'dupalias'\"
else
echo shar: Extracting \"'dupalias'\" \(944 characters\)
sed "s/^X//" >'dupalias' <<'END_OF_FILE'
X#! /usr/local/bin/perl
X#
X# Usage: dupalias
X# dupalias produces a sorted file containing the contents of the real2alias
X# database, then scans it for adjacent lines containing the same alias. It
X# reports duplicate aliases on stdout. When it is finished, it deletes the
X# file containing the sorted database records.
X#
X# You should probably run dupalias once a day to make sure nothing has
X# gotten screwed up in the alias assignment area. The only time this happened
X# to me was because I deleted the lock file when unspool was running, and
X# a second one started up, resulting in a dozen duplicate aliases, which
X# were subsequently lost.
X
Xumask 0077;
Xsystem("/usr/personals/listr2a | sort >sorted");
Xopen(SORTED,"<sorted") || die "can't open sorted: $!\n";
X
X$prevalias = '';
Xwhile (<SORTED>) {
X	($key,$value) = split(/:/);
X	if ( "$key" eq "$prevalias") {
X		print "duplicate alias: $key\n";
X	}
X	$prevalias = $key;
X}
Xunlink("sorted");
Xexit(0);
END_OF_FILE
if test 944 -ne `wc -c <'dupalias'`; then
    echo shar: \"'dupalias'\" unpacked with wrong size!
fi
chmod +x 'dupalias'
# end of 'dupalias'
fi
if test -f 'fixit' -a "${1}" != "-c" ; then 
  echo shar: Will not clobber existing file \"'fixit'\"
else
echo shar: Extracting \"'fixit'\" \(1154 characters\)
sed "s/^X//" >'fixit' <<'END_OF_FILE'
X#! /usr/local/bin/perl
X# 
X# fixit creates a new database called newreal2alias containing the
X# contents of the old data base except for the record corresponding 
X# to <alias>. This was necessary because of a bug in either dbm
X# or perl which failed to delete entries in the database if the key
X# was over 1024 characters long. Please don't ask how I managed to
X# create a key over 1024 characters long. You should never need to
X# use this, but it's here if you do. PLEASE DON'T DO THIS WHEN
X# UNSPOOL IS RUNNING. After you run this, you can delete the old
X# real2alias db and rename (NOT copy) newreal2alias.{dir,pag} to 
X# real2alias.{dir,pag}.
X#
X# Usage: fixit <target-alias>
X#
Xif ( $#ARGV != 0 ) {
X	print STDERR "Usage: fixit <alias>\n";
X	exit(1);
X}
X$target_alias = $ARGV[0];
Xdbmopen(r2a,"/usr/personals/real2alias",0600) 
X	|| die "$0: can't dbmopen real2alias: $!\n";
Xdbmopen(newr2a,"/usr/personals/newreal2alias",0600) 
X	|| die "$0: can't dbmopen newreal2alias: $!\n";
Xwhile (($key,$value) = each %r2a) {
X	if ( "$value" ne "$target_alias" ) {
X		$newr2a{$key} = $value;
X		print $key," = ",$value, "\n";
X	}
X}
Xdbmclose(r2a);
Xdbmclose(newr2a);
Xexit(0);
END_OF_FILE
if test 1154 -ne `wc -c <'fixit'`; then
    echo shar: \"'fixit'\" unpacked with wrong size!
fi
chmod +x 'fixit'
# end of 'fixit'
fi
if test -f 'listr2a' -a "${1}" != "-c" ; then 
  echo shar: Will not clobber existing file \"'listr2a'\"
else
echo shar: Extracting \"'listr2a'\" \(209 characters\)
sed "s/^X//" >'listr2a' <<'END_OF_FILE'
X#! /usr/local/bin/perl
Xdbmopen(r2a,"/usr/personals/real2alias",0600) || die "$0: can't dbmopen real2alias: $!\n";
Xwhile (($key,$value) = each %r2a) {
X#	print $key," = ",$value, "\n";
X	print "$value:$key\n";
X}
END_OF_FILE
if test 209 -ne `wc -c <'listr2a'`; then
    echo shar: \"'listr2a'\" unpacked with wrong size!
fi
chmod +x 'listr2a'
# end of 'listr2a'
fi
if test ! -d 'mailer' ; then
    echo shar: Creating directory \"'mailer'\"
    mkdir 'mailer'
fi
if test -f 'mailer/Contacts' -a "${1}" != "-c" ; then 
  echo shar: Will not clobber existing file \"'mailer/Contacts'\"
else
echo shar: Extracting \"'mailer/Contacts'\" \(714 characters\)
sed "s/^X//" >'mailer/Contacts' <<'END_OF_FILE'
X		Contact Information
X
XWe strongly encourage electronic mail for queries, updates, and
Xapplications.  This cuts down on our costs, and we can pass those
Xsavings along to you.  We currently do not have a telephone number
Xfor queries, although we hope to have one in the near future.  If
Xyou are unable to send and receive electronic mail, you will have
Xto wait until we are prepared for telephone calls or postal mail.
X
XFor queries:	uucp-query@Stargate.COM		cbosgd!stargate!uucp-query
X
XFor updates:	uucpmap@Stargate.COM		cbosgd!stargate!uucpmap
X
XFor problems:	uucp-problem@Stargate.COM	cbosgd!stargate!uucp-problem
X
XTo register:	registry@Stargate.COM		cbosgd!stargate!registry
X#
X#@(#)Contacts	2.5 (smail) 9/15/87
X#
END_OF_FILE
if test 714 -ne `wc -c <'mailer/Contacts'`; then
    echo shar: \"'mailer/Contacts'\" unpacked with wrong size!
fi
# end of 'mailer/Contacts'
fi
if test -f 'mailer/Makefile' -a "${1}" != "-c" ; then 
  echo shar: Will not clobber existing file \"'mailer/Makefile'\"
else
echo shar: Extracting \"'mailer/Makefile'\" \(1251 characters\)
sed "s/^X//" >'mailer/Makefile' <<'END_OF_FILE'
X# Makefile for smail (not a installation makefile)
X
X# @(#)Makefile	2.5 (smail) 9/15/87
X
XCFLAGS	=	-O
X#
X# System V Release 2.0 sites can use -lmalloc for a faster malloc
X#
X#LIBS	=	-lmalloc
X
XOBJECTS =	main.o map.o resolve.o deliver.o misc.o alias.o pw.o headers.o getpath.o str.o getopt.o
X
XDEST = /usr/local/bin
X
Xall: smail svbinmail lcasep pathproc mkfnames nptx
X
Xsmail:		$(OBJECTS)
X		cc $(CFLAGS) $(OBJECTS) -o smail $(LIBS)
X
X$(OBJECTS):	defs.h
X		cc $(CFLAGS) -c $<
X
Xsvbinmail:	svbinmail.c defs.h
X		cc $(CFLAGS) svbinmail.c -o svbinmail
X
Xlcasep:		lcasep.c
X		cc $(CFLAGS) lcasep.c -o lcasep
X
Xpathproc:	pathproc.sh
X		cp pathproc.sh pathproc
X		chmod 755 pathproc
X
Xmkfnames:	mkfnames.sh
X		cp mkfnames.sh mkfnames
X		chmod 755 mkfnames
X
Xnptx:		nptx.o pw.o str.o
X		cc $(CFLAGS) nptx.o pw.o str.o -o nptx $(LIBS)
X
Xnptx.o:		nptx.c
X		cc $(CFLAGS) -c nptx.c
X
Xinstall:	all
X		@echo read doc/Install
X
Xbinstall:	all
X		mv lcasep pathproc mkfnames nptx $(DEST)
X		cp smail /bin/smail
X		mv /usr/lib/sendmail.cf /usr/lib/OLDsendmail.cf
X		mv sendmail.cf /usr/lib/sendmail.cf
X		/usr/lib/sendmail -bz
X		mv /bin/rmail /bin/OLDrmail
X		ln -s /bin/smail /bin/rmail
X		
Xclean:
X		rm -f *.o *.ln a.out core
X
Xclobber:	clean
X		rm -f smail rmail lcasep pathproc mkfnames svbinmail nptx
END_OF_FILE
if test 1251 -ne `wc -c <'mailer/Makefile'`; then
    echo shar: \"'mailer/Makefile'\" unpacked with wrong size!
fi
# end of 'mailer/Makefile'
fi
if test -f 'mailer/Makefile.acs' -a "${1}" != "-c" ; then 
  echo shar: Will not clobber existing file \"'mailer/Makefile.acs'\"
else
echo shar: Extracting \"'mailer/Makefile.acs'\" \(602 characters\)
sed "s/^X//" >'mailer/Makefile.acs' <<'END_OF_FILE'
X# Makefile for acsmail (not a installation makefile)
X
X# @(#)Makefile	2.5 (smail) 9/15/87
X
XCFLAGS	=	-O -DACSMAIL
X#
X# System V Release 2.0 sites can use -lmalloc for a faster malloc
X#
X#LIBS	=	-lmalloc
X
XOBJECTS =	main.o map.o resolve.o deliver.o misc.o alias.o pw.o headers.o getpath.o str.o getopt.o
X
X#DEST = /usr/personals
XDEST = ..
X
Xall: acsmail
X
Xacsmail:	$(OBJECTS)
X		cc $(CFLAGS) $(OBJECTS) -o acsmail $(LIBS)
X
X$(OBJECTS):	defs.h
X		cc $(CFLAGS) -c $<
X
Xinstall:	all
X		cp acsmail $(DEST)
X
Xclean:
X		rm -f *.o *.ln a.out core
X
Xclobber:	clean
X		rm -f acsmail rmail lcasep pathproc mkfnames svbinmail nptx
END_OF_FILE
if test 602 -ne `wc -c <'mailer/Makefile.acs'`; then
    echo shar: \"'mailer/Makefile.acs'\" unpacked with wrong size!
fi
# end of 'mailer/Makefile.acs'
fi
if test -f 'mailer/bindings' -a "${1}" != "-c" ; then 
  echo shar: Will not clobber existing file \"'mailer/bindings'\"
else
echo shar: Extracting \"'mailer/bindings'\" \(357 characters\)
sed "s/^X//" >'mailer/bindings' <<'END_OF_FILE'
Xgrep = ruleset grep
XRULESET.*{$ = ruleset sendmail.ease = ruleset sendmail.ease
X| = ruleset |
Xcut = ruleset cut
X-d  = ruleset -d
X-f1 = ruleset -f1
XRULESET_3 = ruleset 3
XRULESET_0 = ruleset 0
XRULESET_10 = ruleset 10
XRULESET_20 = ruleset 20
XRULESET_14 = ruleset 14
XRULESET_24 = ruleset 24
XRULESET_11 = ruleset 11
XRULESET_21 = ruleset 21
XRULESET_4 = ruleset 4
END_OF_FILE
if test 357 -ne `wc -c <'mailer/bindings'`; then
    echo shar: \"'mailer/bindings'\" unpacked with wrong size!
fi
# end of 'mailer/bindings'
fi
if test -f 'mailer/lcasep.8' -a "${1}" != "-c" ; then 
  echo shar: Will not clobber existing file \"'mailer/lcasep.8'\"
else
echo shar: Extracting \"'mailer/lcasep.8'\" \(742 characters\)
sed "s/^X//" >'mailer/lcasep.8' <<'END_OF_FILE'
X.TH LCASEP 8
X.tr ~
X.SH NAME
Xlcasep \- convert first field to lower case
X.SH SYNOPSIS
X.B lcasep
X[ -f infile ] [ -o outfile ]
X.SH DESCRIPTION
X.I Lcasep
Xconverts all upper case characters
Xin the first field of each input line to lower case
Xand writes the line to its output.  By default,
X.I lcasep
Xreads from the standard input and writes to the standard output.
XFields are delimited by a tab (ascii~0x9) character.
XIt is used in preparation for sorting
X.IR smail "'s"
X.I paths
Xdatabase.  There is a bug in
X.I sort -f
Xthat causes non-alphanumeric keys to be sorted incorrectly.
XConversion before sorting avoids this bug.
X.SH SEE ALSO
Xpathalias - by Peter Honeyman
X.br
Xsmail(8), paths(8), pathproc(8)
X.SH VERSION
X@(#)lcasep.8	2.5 (smail) 9/15/87
END_OF_FILE
if test 742 -ne `wc -c <'mailer/lcasep.8'`; then
    echo shar: \"'mailer/lcasep.8'\" unpacked with wrong size!
fi
# end of 'mailer/lcasep.8'
fi
if test -f 'mailer/lcasep.c' -a "${1}" != "-c" ; then 
  echo shar: Will not clobber existing file \"'mailer/lcasep.c'\"
else
echo shar: Extracting \"'mailer/lcasep.c'\" \(1163 characters\)
sed "s/^X//" >'mailer/lcasep.c' <<'END_OF_FILE'
X/*
X** convert the host name on a pathalias line to lower case
X*/
X
X#ifndef lint
Xstatic char 	*sccsid="@(#)lcasep.c	2.5 (smail) 9/15/87";
X#endif
X
X#include <stdio.h>
X#include <ctype.h>
X
X# define lower(c) 		( isupper(c) ? c-'A'+'a' : c )
X
Xvoid exit(), perror();
X
Xmain(argc, argv)
Xint argc;
Xchar *argv[];
X{
X	FILE *ifp, *ofp;
X	char buf[BUFSIZ];
X	register char *p;
X	int c;
X
X	extern int optind;
X	extern char *optarg;
X
X	ifp = stdin;
X	ofp = stdout;
X
X	while((c = getopt(argc, argv, "f:o:")) != EOF) {
X		switch(c) {
X		case 'f':
X			if((ifp = fopen(optarg, "r")) == NULL) {
X				(void) fprintf(stderr, "%s: can't open %s: ",
X					argv[0], optarg);
X				perror("");
X				exit(1);
X			}
X			break;
X		case 'o':
X			if((ofp = fopen(optarg, "w")) == NULL) {
X				(void) fprintf(stderr, "%s: can't open %s: ",
X					argv[0], optarg);
X				perror("");
X				exit(1);
X			}
X			break;
X		default:
X			(void) fprintf(stderr,
X				"usage: %s [-f file] [-o outfile]\n", argv[0]);
X			exit(1);
X			/* NOTREACHED */
X			break;
X		}
X	}
X
X	while(fgets(buf, sizeof(buf), ifp) != NULL) {
X		for(p = buf; *p != '\t' && *p != '\0' ; p++) {
X			(void) fputc(lower(*p), ofp);
X		}
X		(void) fputs(p, ofp);
X	}
X	return(0);
X}
END_OF_FILE
if test 1163 -ne `wc -c <'mailer/lcasep.c'`; then
    echo shar: \"'mailer/lcasep.c'\" unpacked with wrong size!
fi
# end of 'mailer/lcasep.c'
fi
if test -f 'mailer/mkfnames.8' -a "${1}" != "-c" ; then 
  echo shar: Will not clobber existing file \"'mailer/mkfnames.8'\"
else
echo shar: Extracting \"'mailer/mkfnames.8'\" \(645 characters\)
sed "s/^X//" >'mailer/mkfnames.8' <<'END_OF_FILE'
X.TH MKFNAMES 8
X.tr ~
X.SH NAME
Xmkfnames \- create full name database
X.SH SYNOPSIS
X.B mkfnames [ file  ...]
X.SH DESCRIPTION
X.I mkfnames
Xuses the named
X.I files
Xas input and writes a sorted database suitable for
Xuse as the full name database for
X.IR smail (8)
Xon the standard output.
XThe format of an input line is defined by
X.IR nptx (8).
XIf no
X.I files
Xare specified, then the password file is
Xused to parsed and an attempt is made to
Xmunge it into the format needed by
X.I nptx.  No guarantees on this, since
Xthere are so many bizarre password file
Xformats.
X.SH SEE ALSO
Xsmail(8), paths(8), nptx(8)
X.SH VERSION
X@(#)mkfnames.8	2.5 (smail) 9/15/87
END_OF_FILE
if test 645 -ne `wc -c <'mailer/mkfnames.8'`; then
    echo shar: \"'mailer/mkfnames.8'\" unpacked with wrong size!
fi
# end of 'mailer/mkfnames.8'
fi
if test -f 'mailer/mkfnames.sh' -a "${1}" != "-c" ; then 
  echo shar: Will not clobber existing file \"'mailer/mkfnames.sh'\"
else
echo shar: Extracting \"'mailer/mkfnames.sh'\" \(236 characters\)
sed "s/^X//" >'mailer/mkfnames.sh' <<'END_OF_FILE'
X#! /bin/sh
X#
X# @(#)mkfnames.sh	2.5 (smail) 9/15/87
X#
Xif test $# = 0
Xthen
X	sed 's/\(.*\):.*:.*:.*:\(.*\):.*:.*/\1	\2/' /etc/passwd
Xelse
X	cat $*
Xfi	|	# at this point, we have a list of login\tFull Name pairs
Xnptx	|
Xlcasep	|
Xsort -u +0 -1
END_OF_FILE
if test 236 -ne `wc -c <'mailer/mkfnames.sh'`; then
    echo shar: \"'mailer/mkfnames.sh'\" unpacked with wrong size!
fi
# end of 'mailer/mkfnames.sh'
fi
if test -f 'mailer/patchlevel' -a "${1}" != "-c" ; then 
  echo shar: Will not clobber existing file \"'mailer/patchlevel'\"
else
echo shar: Extracting \"'mailer/patchlevel'\" \(12 characters\)
sed "s/^X//" >'mailer/patchlevel' <<'END_OF_FILE'
XPatch #: 00
END_OF_FILE
if test 12 -ne `wc -c <'mailer/patchlevel'`; then
    echo shar: \"'mailer/patchlevel'\" unpacked with wrong size!
fi
# end of 'mailer/patchlevel'
fi
if test -f 'mailer/pathproc.8' -a "${1}" != "-c" ; then 
  echo shar: Will not clobber existing file \"'mailer/pathproc.8'\"
else
echo shar: Extracting \"'mailer/pathproc.8'\" \(896 characters\)
sed "s/^X//" >'mailer/pathproc.8' <<'END_OF_FILE'
X.TH PATHPROC 8
X.SH NAME
Xpathproc \- pathalias post\-processor for smail routing database
X.SH DESCRIPTION
X.I Pathproc
Xtakes lines of the form
X.sp
X.ce
X\fIfirst_hop_cost	key	route\fP
X.sp
Xas produced by
X.I pathalias -f
Xand converts it to the form
X.sp
X.ce
X\fI key	route	cost\fP
X.sp
Xas described in
X.IR paths (8).
XOn the input, the
X.I route_cost
Xis
X.IR pathalias "'s"
Xtotal cost for the route.
XOn the output, the
X.I cost
Xis the cost for the
X.I first segment
Xof the route.
XThis represents the cost, to the local host,
Xof passing the mail to its neighbor.
X.PP
XThe output is sorted by
X.I key
Xin ascending order.
X.SH EXAMPLE
XHere's an example of how you might use
X.I pathproc:
X.sp
X.in+3
Xpathalias -f \fImap_files\fP | pathproc > newpaths
X.br
Xmv newpaths /usr/lib/uucp/paths
X.in
X.sp
X.SH SEE ALSO
Xpathalias - by Peter Honeyman
X.br
Xsmail(8), lcasep(8), paths(8)
X.SH VERSION
X@(#)pathproc.8	2.5 (smail) 9/15/87
END_OF_FILE
if test 896 -ne `wc -c <'mailer/pathproc.8'`; then
    echo shar: \"'mailer/pathproc.8'\" unpacked with wrong size!
fi
# end of 'mailer/pathproc.8'
fi
if test -f 'mailer/pathproc.sh' -a "${1}" != "-c" ; then 
  echo shar: Will not clobber existing file \"'mailer/pathproc.sh'\"
else
echo shar: Extracting \"'mailer/pathproc.sh'\" \(467 characters\)
sed "s/^X//" >'mailer/pathproc.sh' <<'END_OF_FILE'
X#
X#	@(#)pathproc.sh	2.5 (smail) 9/15/87
X#
X# This script will do all that's necessary for
X# transforming the output of pathalias -f into
X# the format of a 'paths' file for smail.
X#
X# format of the pathalias -f output is
X# cost	host	route
X#
X# format of a 'paths' file for smail is
X# host	route	first_hop_cost
X#
X# move cost field to end of line
X#
Xsed 's/\(.*\)	\(.*\)	\(.*\)/\2	\3	\1/'|
X#
X# convert target domain/host to lower case
X#
Xlcasep |
X#
X# sort the stream
X#
Xsort
END_OF_FILE
if test 467 -ne `wc -c <'mailer/pathproc.sh'`; then
    echo shar: \"'mailer/pathproc.sh'\" unpacked with wrong size!
fi
# end of 'mailer/pathproc.sh'
fi
if test -f 'mailer/smail.prompt' -a "${1}" != "-c" ; then 
  echo shar: Will not clobber existing file \"'mailer/smail.prompt'\"
else
echo shar: Extracting \"'mailer/smail.prompt'\" \(761 characters\)
sed "s/^X//" >'mailer/smail.prompt' <<'END_OF_FILE'
X#
X# @(#)smail.prompt	2.5 (smail) 9/15/87
X#
X
Xloop=true
Xwhile test $loop = true
Xdo 
X	case "$1" in
X	string)
X		echo "$2" 1>&2
X		read ans
X		if test ! -z "$ans"
X		then
X			echo $ans
X			loop=false;
X		fi
X	;;
X	file)
X		echo "$2" 1>&2
X		read ans
X		case "$ans" in
X		/*)
X			if test -f "$ans"
X			then
X				echo $ans
X				loop=false;
X			else
X				echo "file '$ans' not found" 1>&2
X			fi
X		;;
X		*)
X			echo "must give FULL PATH to file" 1>&2
X		;;
X		esac
X	;;
X	yesno)
X		echo "$2" 1>&2
X		read ans
X		case "$ans" in
X		y|Y|yes|Yes|YES)
X			echo "yes"
X			loop=false
X		;;
X		n|N|no|No|NO)
X			echo "no"
X			loop=false
X		;;
X		*)
X			echo "Please enter yes or no" 1>&2
X		;;
X		esac
X	;;
X	*)
X
X		echo "usage: $0 string|yesno prompt_message" 1>&2
X		echo BOGUS_PROMPT_STRING
X		loop=false
X	;;
X	esac
Xdone
END_OF_FILE
if test 761 -ne `wc -c <'mailer/smail.prompt'`; then
    echo shar: \"'mailer/smail.prompt'\" unpacked with wrong size!
fi
# end of 'mailer/smail.prompt'
fi
if test -f 'mailer/str.c' -a "${1}" != "-c" ; then 
  echo shar: Will not clobber existing file \"'mailer/str.c'\"
else
echo shar: Extracting \"'mailer/str.c'\" \(984 characters\)
sed "s/^X//" >'mailer/str.c' <<'END_OF_FILE'
X#ifndef lint
Xstatic char 	*sccsid="@(#)str.c	2.5 (smail) 9/15/87";
X#endif
X
X#include "defs.h"
X#include <ctype.h>
X
X/*
X**	strncmpic: string compare, ignore case, stop after 'n' chars
X*/
X
Xstrncmpic(s1, s2, n)
Xchar *s1, *s2;
Xint n;
X{
X	register char *u = s1;
X	register char *p = s2;
X
X	while((n > 0) && (*p != '\0')) {
X		/* chars match or only case different */
X		if(lower(*u) == lower(*p)) {
X			p++;	/* examine next char */
X			u++;
X		} else {
X			break;	/* no match - stop comparison */
X		}
X		n--;
X	}
X	if(n > 0) {
X		return(lower(*u) - lower(*p)); /* return "difference" */
X	} else {
X		return(0);
X	}
X}
X
X/*
X**	strcmpic: string compare, ignore case
X*/
X
Xstrcmpic(s1, s2)
Xchar *s1, *s2;
X{
X	register char *u = s1;
X	register char *p = s2;
X
X	while(*p != '\0') {
X		/* chars match or only case different */
X		if(lower(*u) == lower(*p)) {
X			p++;	/* examine next char */
X			u++;
X		} else {
X			break;	/* no match - stop comparison */
X		}
X	}
X
X	return(lower(*u) - lower(*p)); /* return "difference" */
X}
X
END_OF_FILE
if test 984 -ne `wc -c <'mailer/str.c'`; then
    echo shar: \"'mailer/str.c'\" unpacked with wrong size!
fi
# end of 'mailer/str.c'
fi
if test -f 'mailer/sysexits.h' -a "${1}" != "-c" ; then 
  echo shar: Will not clobber existing file \"'mailer/sysexits.h'\"
else
echo shar: Extracting \"'mailer/sysexits.h'\" \(482 characters\)
sed "s/^X//" >'mailer/sysexits.h' <<'END_OF_FILE'
X/*
X**	@(#)sysexits.h	2.5 (smail) 9/15/87
X*/
X
X# define EX_OK		0	/* successful termination */
X# define EX_USAGE	64	/* command line usage error */
X# define EX_NOHOST	68	/* host name unknown */
X# define EX_UNAVAILABLE	69	/* service unavailable */
X# define EX_SOFTWARE	70	/* internal software error */
X# define EX_OSFILE	72	/* critical OS file missing */
X# define EX_CANTCREAT	73	/* can't create (user) output file */
X# define EX_TEMPFAIL	75	/* temp failure; user is invited to retry */
END_OF_FILE
if test 482 -ne `wc -c <'mailer/sysexits.h'`; then
    echo shar: \"'mailer/sysexits.h'\" unpacked with wrong size!
fi
# end of 'mailer/sysexits.h'
fi
if test -f 'nextalias' -a "${1}" != "-c" ; then 
  echo shar: Will not clobber existing file \"'nextalias'\"
else
echo shar: Extracting \"'nextalias'\" \(199 characters\)
sed "s/^X//" >'nextalias' <<'END_OF_FILE'
X#! /usr/local/bin/perl
X	if (open(INDEX,'</usr/personals/alias-index')) {
X		$alias_index = <INDEX>;
X		close(INDEX);
X		$alias_index++;
X	}
X	else {
X		$alias_index = 'a';
X	}
Xprint "$alias_index\n";
Xexit;
END_OF_FILE
if test 199 -ne `wc -c <'nextalias'`; then
    echo shar: \"'nextalias'\" unpacked with wrong size!
fi
chmod +x 'nextalias'
# end of 'nextalias'
fi
if test -f 'patchlevel' -a "${1}" != "-c" ; then 
  echo shar: Will not clobber existing file \"'patchlevel'\"
else
echo shar: Extracting \"'patchlevel'\" \(2 characters\)
sed "s/^X//" >'patchlevel' <<'END_OF_FILE'
X1
END_OF_FILE
if test 2 -ne `wc -c <'patchlevel'`; then
    echo shar: \"'patchlevel'\" unpacked with wrong size!
fi
# end of 'patchlevel'
fi
if test -f 'rmbyaddr' -a "${1}" != "-c" ; then 
  echo shar: Will not clobber existing file \"'rmbyaddr'\"
else
echo shar: Extracting \"'rmbyaddr'\" \(518 characters\)
sed "s/^X//" >'rmbyaddr' <<'END_OF_FILE'
X#! /usr/local/bin/perl
X# 
X# rmbyaddr deletes an entry from real2addr database given the addr
X#
X# Usage: rmbyaddr <target-addr>
X#
Xif ( $#ARGV != 0 ) {
X	print STDERR "Usage: rmbyaddr <address>\n";
X	exit(1);
X}
X
X$target_addr = $ARGV[0];
X
Xdbmopen(r2a,"/usr/personals/real2alias",0600) 
X	|| die "$0: can't dbmopen real2alias: $!\n";
Xopen(LOG,">>/usr/personals/REMOVED");
X$value = $r2a{$target_addr};
Xdelete $r2a{$target_addr};
Xif (defined($value)) {
X	print LOG "$value:$target_addr\n";
X}
Xdbmclose(r2a);
Xclose(LOG);
Xexit(0);
END_OF_FILE
if test 518 -ne `wc -c <'rmbyaddr'`; then
    echo shar: \"'rmbyaddr'\" unpacked with wrong size!
fi
chmod +x 'rmbyaddr'
# end of 'rmbyaddr'
fi
if test -f 'rmbyalias' -a "${1}" != "-c" ; then 
  echo shar: Will not clobber existing file \"'rmbyalias'\"
else
echo shar: Extracting \"'rmbyalias'\" \(542 characters\)
sed "s/^X//" >'rmbyalias' <<'END_OF_FILE'
X#! /usr/local/bin/perl
X# 
X# rmbyalias deletes an entry from real2alias database given the alias
X#
X# Usage: rmbyalias <alias>
X#
Xumask 0077;
Xif ( $#ARGV != 0 ) {
X	print STDERR "Usage: rmbyalias <alias>\n";
X	exit(1);
X}
X
X$target_alias = $ARGV[0];
X
Xdbmopen(r2a,"/usr/personals/real2alias",0600) 
X	|| die "$0: can't dbmopen real2alias: $!\n";
Xopen(LOG,">>/usr/personals/REMOVED");
X
Xwhile (($key,$value) = each %r2a) {
X	if ( "$value" eq "$target_alias" ) {
X		delete $r2a{$key};
X		print LOG "$value:$key\n";
X	}
X}
X
Xdbmclose(r2a);
Xclose(LOG);
Xexit(0);
END_OF_FILE
if test 542 -ne `wc -c <'rmbyalias'`; then
    echo shar: \"'rmbyalias'\" unpacked with wrong size!
fi
chmod +x 'rmbyalias'
# end of 'rmbyalias'
fi
echo shar: End of archive 1 \(of 8\).
cp /dev/null ark1isdone
MISSING=""
for I in 1 2 3 4 5 6 7 8 ; do
    if test ! -f ark${I}isdone ; then
	MISSING="${MISSING} ${I}"
    fi
done
if test "${MISSING}" = "" ; then
    echo You have unpacked all 8 archives.
    rm -f ark[1-9]isdone
else
    echo You still need to unpack the following archives:
    echo "        " ${MISSING}
fi
##  End of shell archive.
exit 0