home *** CD-ROM | disk | FTP | other *** search
/ PC Welt 2006 November (DVD) / PCWELT_11_2006.ISO / casper / filesystem.squashfs / usr / share / doc / ppp / examples / scripts / ppp-on < prev    next >
Encoding:
Text File  |  1995-10-16  |  1.6 KB  |  37 lines

  1. #!/bin/sh
  2. #
  3. # Script to initiate a ppp connection. This is the first part of the
  4. # pair of scripts. This is not a secure pair of scripts as the codes
  5. # are visible with the 'ps' command.  However, it is simple.
  6. #
  7. # These are the parameters. Change as needed.
  8. TELEPHONE=555-1212    # The telephone number for the connection
  9. ACCOUNT=george        # The account name for logon (as in 'George Burns')
  10. PASSWORD=gracie        # The password for this account (and 'Gracie Allen')
  11. LOCAL_IP=0.0.0.0    # Local IP address if known. Dynamic = 0.0.0.0
  12. REMOTE_IP=0.0.0.0    # Remote IP address if desired. Normally 0.0.0.0
  13. NETMASK=255.255.255.0    # The proper netmask if needed
  14. #
  15. # Export them so that they will be available at 'ppp-on-dialer' time.
  16. export TELEPHONE ACCOUNT PASSWORD
  17. # This is the location of the script which dials the phone and logs
  18. # in.  Please use the absolute file name as the $PATH variable is not
  19. # used on the connect option.  (To do so on a 'root' account would be
  20. # a security hole so don't ask.)
  21. #
  22. DIALER_SCRIPT=/etc/ppp/ppp-on-dialer
  23. #
  24. # Initiate the connection
  25. # I put most of the common options on this command. Please, don't
  26. # forget the 'lock' option or some programs such as mgetty will not
  27. # work. The asyncmap and escape will permit the PPP link to work with
  28. # a telnet or rlogin connection. You are welcome to make any changes
  29. # as desired. Don't use the 'defaultroute' option if you currently
  30. # have a default route to an ethernet gateway.
  31. #
  32. exec /usr/sbin/pppd debug lock modem crtscts /dev/ttyS0 38400 \
  33.     asyncmap 20A0000 escape FF kdebug 0 $LOCAL_IP:$REMOTE_IP \
  34.     noipdefault netmask $NETMASK defaultroute connect $DIALER_SCRIPT
  35.