Kliment Toshkov <sag@viket.net>
last modified 16.12.2000, 14:17 EET
The point of this document is not telling you how to install and run
properly any part of the software needed. I will assume you have it already
installed and running ok.
/AutoPPP/ - a_ppp /usr/sbin/pppd auth -chap +pap login modem crtscts lock ipparam 1At this point, we have configured mgetty to automagically recognise LCP configure request and start pppd. Otherwise, /bin/login is executed.
Second step, let's create the files that tell pppd which IP address belongs to a given tty (this is called dynamic IP addressing). If you are using ttyS16 through ttyS25 for dialin access (like I do), then the following should be fine for you: create /etc/ppp/options.ttyS16, /etc/ppp/options.ttyS17, etc, and then put this into each of them depending on it's name and desired IP address given to appropriate ttySxx:
62.176.81.4: this should be the ethernet IP address of the machine running pppds (note the semicolon at the end of IP) modem specifies that modem control lines should be used lock do old style UUCP locking login use /etc/passwd to log the user instead of /etc/ppp/pap-secrets noauth do not require authorization by default (useful when logging in with terminal window) ms-dns 62.176.81.1 I guess, you are serving MS Windows clients, so put your DNS address here. You may specify multiple DNS addreses. Also, if you are a linux user, giving pppd the option usepeerdns enables it to use the DNS specified. mru 576 maximum receive unit, 576 is suitable for slow async connections mtu 576 maximum transmit unit, 576 is suitable for slow async connections
Step three, in /etc/ppp/ip-up you need to run acua_login:
filename: contains: options.ttyS16 :62.176.81.17 - this is the IP address for that tty options.ttyS17 :62.176.81.18 - note the semicolon before IP address etc. etc.
#!/bin/bashFinally, it's required to teach pppd to authorize users against /etc/passwd (or shadow, if installed). Open /etc/ppp/pap-secrets and insert this:
/usr/sbin/acua_login || kill -HUP "$PPID"
* * "" *
#!/bin/bashEdit /etc/passwd and put this file as shell for appropriate users:
TTY=`tty`
case $TTY in
/dev/ttyS16) NO=17;;
/dev/ttyS17) NO=18;;
/dev/ttyS18) NO=19;;
/dev/ttyS19) NO=20;;
/dev/ttyS20) NO=21;;
/dev/ttyS21) NO=22;;
/dev/ttyS22) NO=23;;
/dev/ttyS23) NO=24;;
/dev/ttyS0) NO=25;;
/dev/ttyS1) NO=26;;
/dev/pts*) NO=147;;
*) echo Improper connection; logout;;
esacUSERIP=62.176.81.$NO
stty -echo
/usr/sbin/acua_login || logout
echo Press F7 now...
/usr/sbin/pppd 62.176.81.4:$USERIP crtscts lock ms-dns 62.176.81.1 modem mru 576 mtu 576 ipparam 1
logout
viket:x:728:728::/home/viket:/usr/local/bin/ppp
First, be sure to recompile pppd
so it supports your shadow libs.
Second, remember that /etc/ppp/pap-secrets
should be configured to allow every user to get in.
Third, at the stage of running pppd
a user called a_ppp
should appear in w
or who output. After
pppd has authorized
the user properly, it should change the utmp entry to the proper username.
If not, acua_login
will not allow the user login, and this is a sign that you need to recompile
your pppd program.
It is generally only Red Hat that is affected by this problem.
Kliment Toshkov <sag@viket.net>