Subject: Re: Demand-dial PPP
To: Aaron Mansheim <a-manshe@runet.edu>
From: The Great Mr. Kurtz \[David A. Gatwood\] <davagatw@Mars.utm.edU>
List: port-mac68k
Date: 10/08/1996 14:08:02
On Tue, 8 Oct 1996, Aaron Mansheim wrote:

> How do I get demand-dial PPP?

This may not be 100% accurate, but it should be helpful, based on my
experience with MkLinux, this should work... I hope....

Don't know how to get demand-dial, but you should be able to set up ppp to
work for non-root ppl.  If you have more than just you using the box, you
can restrict access to the stuff by making the scripts and the ppp program
itself only runnable by the ppp group (create one if it doesn't exist in
/etc/group).  Then, chown ppp and the shell scripts to root:ppp.
Finally, make pppd itself setuid with

chmod a+s pppd

That _should_work.  At least it does for mklinux.  If it doesn't work,then
setuid code needs to be added to pppd.  Wouldn't be hard to drop a
setuid(0); instruction into the beginning of the main() in the source
code.

> I have an SE/30 with the 1.2_BETA (GENERICSBC) #2 Jul 18 kernel,
> running on a Quantum ELS170 4.2 drive. If I have to replace my kernel,

Pretty much no reason to do that.  By running pppd setuid as root, it
should do exactly the same thing as if you had run it as root.

And depending on the dial script design (whether pppd runs the dial script
or the dial script dials and runs pppd), you may need to change the
priviledges on the appropriate port device (/dev/cua0 or cua1).  If you
directly run a script that calls tip to dial, and then calls pppd, you
must either set the scripts to be setuid or set the appropriate device to
be readable/writable for the ppp group (or world-readable/writable would
work as well).  However, if pppd calls the dial script, it should already
be running as root.... I _think_.

> I will need the SBC SCSI driver. (Wouldn't it be nice if there were
> a CGI somewhere that would tell what kernel your hardware requires?)

Sounds like a plan to me.  Any takers?  I'll cobble something together if
nobody else is interested, but beware, I only write CGI stuff in C.  :-)

Later,

 /---------------------------------------------------------------------\
|David A. Gatwood             And Richard Cory, one calm summer night,  |
|davagatw@mars              Went home and put a bullet through his head.|
|dgatwood@nyx.cs.du.edu              --Edwin Arlington Robinson         |
|http://mars.utm.edu/~davagatw -or- http://nox.cs.du.edu:8001/~dgatwood |
 \---------------------------------------------------------------------/