summaryrefslogtreecommitdiffstats
path: root/etc/ppp
diff options
context:
space:
mode:
authorbrian <brian@FreeBSD.org>1997-02-23 14:04:23 +0000
committerbrian <brian@FreeBSD.org>1997-02-23 14:04:23 +0000
commit91c28b4ef9423c9f17b4c6095c75aef3d3f9be07 (patch)
tree36675e7cc487f5df8194153cdcf20a25585526c6 /etc/ppp
parentf1ea0f8b5a63cd8a23539a4beb85f66001175821 (diff)
downloadFreeBSD-src-91c28b4ef9423c9f17b4c6095c75aef3d3f9be07.zip
FreeBSD-src-91c28b4ef9423c9f17b4c6095c75aef3d3f9be07.tar.gz
Make the sample config files more understandable, correcting various
bits of grammar. Added a decent pmdemand example for dynamic IPs on both sides. Could this be a 2.2 candidate ?
Diffstat (limited to 'etc/ppp')
-rw-r--r--etc/ppp/ppp.conf.sample70
-rw-r--r--etc/ppp/ppp.linkup.sample42
2 files changed, 68 insertions, 44 deletions
diff --git a/etc/ppp/ppp.conf.sample b/etc/ppp/ppp.conf.sample
index 75c30ad..110aca4 100644
--- a/etc/ppp/ppp.conf.sample
+++ b/etc/ppp/ppp.conf.sample
@@ -4,11 +4,11 @@
#
# Written by Toshiharu OHNO
#
-# $Id$
+# $Id: ppp.conf.sample,v 1.8 1997/02/23 09:21:11 peter Exp $
#
#################################################################
-#
-# Default setup. Executed always when PPP is invoked.
+
+# Default setup. Always executed when PPP is invoked.
#
default:
set device /dev/cuaa1
@@ -16,18 +16,18 @@ default:
disable lqr
deny lqr
set dial "ABORT BUSY ABORT NO\\sCARRIER TIMEOUT 5 \"\" ATE1Q0 OK-AT-OK \\dATDT\\T TIMEOUT 40 CONNECT"
-#
+
# Example with login script
# o From PPP prompt,
# ppp> dial simplesite
-# will automatically dials and perform login procedure.
+# automatically dials and performs the login script.
#
# ppp> load simplesite
-# will also load and execute commands, but don't dial.
+# loads and executes commands, but doesn't dial.
#
# o From shell, invoke as
# % ppp simplesite
-# will load commands associated with the label. Use,
+# to load commands associated with the 'simplesite' label. Use,
# ppp> dial
# to establish the connection.
#
@@ -35,21 +35,22 @@ simplesite:
set phone 12345678
set login "TIMEOUT 5 login:-\\r-login: ppp word: ppp ocol: ppp"
set timeout 120
-#
+
# Multi-phone example
#
multiphone:
set phone 12345678:12345679:12345670:12345671
set login "TIMEOUT 5 login:-\\r-login: ppp word: ppp ocol: ppp"
+
+# If the peer requires to use CHAP, don't forget to supply authname
+# and authkey.
#
-# If peer requires to use CHAP, don't forget to supply authname and authkey.
-#
-# If you'd like to use CHAP to authentication peer, comment out the line
-# ``enable chap'' below. You also need to prepare /etc/ppp.secret.
+# If you'd like to use CHAP to authenticate with the peer, comment out
+# the line ``enable chap'' below. You also need to prepare /etc/ppp.secret.
#
-# If remote system sends its system name within CHAP packet and it is
-# found in /etc/ppp.secret, then secret key is taken from the file and
-# value of authkey is ignored.
+# If the remote system sends its system name within the CHAP packet and it
+# is found in /etc/ppp.secret, then the secret key is taken from that file
+# and value of authkey specified here is ignored.
#
chapsite:
set phone 12345678
@@ -59,8 +60,8 @@ chapsite:
# enable chap
set authname MySystemName
set authkey OurSecretKey
-#
-# To speak PAP is just similar to CHAP
+
+# Speaking PAP is like speaking CHAP
#
papsite:
set phone 12345678
@@ -70,13 +71,13 @@ papsite:
# enable pap
set authname MyUserName
set authkey MyPassword
-#
+
# On demand dialup example
# Here, we assume that local side use 192.244.185.226 and
# remote side use 192.244.176.44 as their IP address.
# You must supply -auto option to invoke PPP.
#
-# ex. % ppp -auto ondemand
+# $ ppp -auto ondemand
#
ondemand:
set phone 1234567
@@ -84,20 +85,30 @@ ondemand:
set timeout 120
set ifaddr 192.244.185.226 192.244.176.44 255.255.255.0
add 0 0 192.244.176.44
-#
+
# Another on demand example
-# If peer assign some IP address for us, and we can't predict it
-# until we make a connection, use 0 as local side address.
+# If the peer assigns us an arbitrary IP and we can't predict what their
+# IP will be either, take a wild guess at an some IPs that you can't
+# currently route to. Ensure that the "delete" and "add" lines are also
+# present in ppp.linkup so that when we connect, things will be put straight.
+#
+# The /0 bit says that we insist on 0 bits of the specified IP actually
+# being correct, therefore, the other side can assign any IP numbers.
+#
+# We also set openmode active - this makes us initiate ppp negotiation.
+# The default is to wait for the server to start talking.
#
pmdemend:
set phone 1234567
set login "TIMEOUT 5 login:-\\r-login: ppp word: ppp"
set timeout 120
- set ifaddr 0 192.244.176.44 255.255.255.0
- add 0 0 192.244.176.44
-#
+ set ifaddr 10.10.10.10/0 10.10.11.11/0 255.255.255.0
+ delete ALL
+ add 0 0 HISADDR
+ set openmode active
+
# Example to validate incoming user with CHAP
-# Invod as ``ppp -direct users'' from login script. User's system name
+# Invoke as ``ppp -direct users'' from login script. User's system name
# and secret-key must be registered into /etc/ppp.secret.
# IP address assigned to peer is registered in ppp.secret, then that
# value is used and value in ``ifaddr'' command has no effect.
@@ -108,14 +119,14 @@ users:
enable proxy
set authname ppp-server
set ifaddr 192.244.176.44 292.244.184.31
-#
+
# Example of Callback Request
#
# Here, we assume that peer will hangup the line and initiates a callback
# after successful authentication. We simply use chat script capability
# and wait for a "NO CARRIER" response from our modem.
#
-# % ppp callback
+# $ ppp callback
#
callback:
set phone 0312345678
@@ -123,10 +134,11 @@ callback:
set debug phase chat
dial
quit
-#
+
# Example for PPP/TELNET and PPP/TCP. Read doc for further details
#
ppptelnet:
set escape 0xff
+
ppptcp:
set device 192.244.191.33:2400
diff --git a/etc/ppp/ppp.linkup.sample b/etc/ppp/ppp.linkup.sample
index 1913c3d..514a6fe 100644
--- a/etc/ppp/ppp.linkup.sample
+++ b/etc/ppp/ppp.linkup.sample
@@ -3,35 +3,47 @@
# Example of ppp.linkup file
#
#
-# This file is checked when PPP establishes network level connection.
-# PPP command searches label in this file in following way and order.
+# This file is checked when PPP establishes a connection.
+# PPP searches the labels in this file as follows:
#
-# 1) At first, IP address assigned into our side is searched and execute
-# associated command.
+# 1) The label that matches the IP number assigned to our side.
#
-# 2) If it didn't found, then label name specified at startup time is
-# searched.
+# 2) The label specified on the command line to ppp.
#
-# 3) If given label name is not found, then label MYADDR is searched.
+# 3) If no label has been found, use MYADDR if it exists.
#
-# $Id$
+# $Id: ppp.linkup.sample,v 1.5 1997/02/23 09:21:11 peter Exp $
#
#########################################################################
-#
+
# If we've got 192.244.176.32 as our address, then regard peer as a gateway
# to 192.244.176.0 network.
#
-#192.244.176.32:
-# add 192.244.176.0 0 HISADDR
-#
-# If we are invoked with an argument ``iij-demand'', then
-# delete existing route entry and add peer as default gateway.
+192.244.176.32:
+ add 192.244.176.0 0 HISADDR
+
+# If we are invoked with an argument ``iij-demand'', then delete all
+# existing route entries and add the peer as the default gateway.
#
iij-demand:
delete ALL
add 0 0 HISADDR
-#
+
# Otherwise, simply add peer as default gateway.
#
MYADDR:
add 0 0 HISADDR
+
+# If we are invoked with an argument ``pmdemand'', then
+# delete all existing (wrong) routing entries and add the peer IP
+# as our default gateway.
+# This is vital if you don't already know either sides IP number.
+#
+# We also want to execute a script on startup. This script can do
+# nice things such as kick off "sendmail -q", "popclient my.isp" and
+# "slurp -d news".
+#
+pmdemand:
+ delete ALL
+ add 0 0 HISADDR
+ ! sh -c "/etc/ppp/ppp.etherup.pmdemand &"
OpenPOWER on IntegriCloud