[comp.unix.questions] Xenix mail system

jbayer@ispi.UUCP (Jonathan Bayer) (01/18/89)

Hello netlanders,

	I would like to totally replace the standard Xenix mail system. 
Currently I have smail running, with a few kludges in order to let it
work with Xenix.  What I need are copies of the local-transport-agents
(mail and mailx) and/or definitions of what they do.  I want to get rid
of the execmail program as well as all the other unexplained stuff that
SCO supplies.  

	UUCP currently calls rmail (linked to smail) which then calls
lmail.  lmail is the first program I want to replace.  I have received a
copy of an lmail replacement from Jon Zeeff.  It looks good, but I do
want some more input since the comments state that it has not been fully
checked out.

	The mailx program (known as mail on SCO systems) seems to call
execmail.  I assume that execmail is the local transport agent.  This is
the second program I want to replace (mailx).  I feel that mailx should
call either lmail or rmail, depending on where the mail is going.  This
would eliminate all calls to execmail, leaving a System V equivilent
system. 


JB

-- 
Jonathan Bayer				Beware: The light at the end of the
Intelligent Software Products, Inc.	        tunnel may be an oncoming dragon
19 Virginia Ave.				...uunet!ispi!jbayer
Rockville Centre, NY   11570	(516) 766-2867	jbayer@ispi

ccs@lazlo.UUCP (Clifford C. Skolnick) (01/18/89)

In article <417@ispi.UUCP> jbayer@ispi.UUCP (Jonathan Bayer) writes:
> [Discusion of Xenix mail system and desire to replace]
>...I have received a
>copy of an lmail replacement from Jon Zeeff.  It looks good, but I do
>want some more input since the comments state that it has not been fully
>checked out.

I checked it out, It looked secure except for two things.  I check that
in order for the program to send mail to a program, two things are checked.

   1) the program specified is a full path name
   2) the user being mailed to owns the file directing transfer to a
      program.

Here are the diffs to the version posted to the net:

-----Cut Here-----
#!/bin/sh
# shar:	Shell Archiver  (v1.22)
#
#	Run the following text with /bin/sh to create:
#	  lmail.diff
#
sed 's/^X//' << 'SHAR_EOF' > lmail.diff &&
X345a346,349
X> 				if (statbuf.st_uid!=pwd->pw_uid) {
X> 					fclose(in_file);
X> 					continue;
X> 				}
X366a371,374
X> 				if (statbuf.st_uid!=pwd->pw_uid) {
X> 					fclose(in_file);
X> 					continue;
X> 				}
X480a489,492
X> 			if (dest[1]!='/') {
X> 					(void) fprintf(stderr, "\nCan only pipe to a full path name.\n",dest);
X> 					return(8);
X> 			}
SHAR_EOF
chmod 0644 lmail.diff || echo "restore of lmail.diff fails"
exit 0
-----cut here-----
>-- 
>Jonathan Bayer				Beware: The light at the end of the
>Intelligent Software Products, Inc.	        tunnel may be an oncoming dragon
>19 Virginia Ave.				...uunet!ispi!jbayer
>Rockville Centre, NY   11570	(516) 766-2867	jbayer@ispi
-- 
Cliff Skolnick (ccs@lazlo)|  "You told me time makes it easy, but you never
Phone: (716) 427-8046     |   told me time stands still" - Gary Numan
TCP/IP: 44.68.0.195       | ...!rutgers!rochester!ritcv!ritcsh!sabin! lazlo!ccs
  ccs@lazlo.n1dph.ampr.org|                      \!kodak!pcid!gizzmo!/

jtc@tessera.UUCP (J.T. Conklin) (01/19/89)

[ followups redirected to comp.unix.xenix ]

In article <417@ispi.UUCP> jbayer@ispi.UUCP (Jonathan Bayer) writes:
>Hello netlanders,
>
>	I would like to totally replace the standard Xenix mail system. 
>Currently I have smail running, with a few kludges in order to let it
>work with Xenix.  What I need are copies of the local-transport-agents
>(mail and mailx) and/or definitions of what they do.  I want to get rid
>of the execmail program as well as all the other unexplained stuff that
>SCO supplies.

I dumped the Xenix mail system about one year ago and never regretted
the decision.  Since that date, my mail system has gone through
several stages.  It's still not perfect, but it is much better than
the stock system.

This is a brief history of my mail system.  It is not a "how to" guide.
If anyone wants details, mail me and I'll do my best to help.

1. Replaced execmail with sendmail.

   Execmail is basically a non-configurable subset of sendmail.  I
   grabbed sendmail from an archive site, whipped up a sendmail.cf
   file, and replaced execmail with sendmail.

   This change didn't add any extra functionality over SCO's mail, 
   but I felt a bit happier that I was in control. (source code, etc)

2. Used smail as a back end to sendmail.

3. Totally removed SCO mail.

   I decided that _I_ was interested in SysV mail behavior even
   if SCO wasn't.

   I wrote a new mail delivery program which used /usr/mail as spool
   directory and SysV style locks.  Because the spool directory was
   changed, login couldn't notify me of new mail, so I wrote my own
   login too!

   [ Bug waiting to happen department:  What is bound to happen sooner
     or later when two Xenix machines on a network share the /usr/spool/mail
     directory when they don't also share /tmp? ]

   I now use mush and elm as my user interface.  (mush is linked to mail)
   I am working on a port of the BSD Mail mailer, but not enough time.

   Moving the spool directory to /usr/mail and using SysV style locks
   has not been totally without problems.  For example, the ELM
   configuration script discovered I was on a Xenix box and blindly
   assumed I was using that standard Xenix methodology.  It didn't even
   ask for confirmation!
 
Good Luck,

	--jtc

-- 
J.T. Conklin
    ...!{ubc-cs,uunet}!van-bc!tessera!jtc