summaryrefslogtreecommitdiffstats
path: root/share
diff options
context:
space:
mode:
authorcjc <cjc@FreeBSD.org>2002-01-29 00:23:35 +0000
committercjc <cjc@FreeBSD.org>2002-01-29 00:23:35 +0000
commitb3b56d609a8e130ead3cf3de57be8e709508af25 (patch)
treeef387e917ce7624147339fadf5dd005483c5e2b5 /share
parentdc82fedb5a0b52746bb2b4a6d1fef7b198f963af (diff)
downloadFreeBSD-src-b3b56d609a8e130ead3cf3de57be8e709508af25.zip
FreeBSD-src-b3b56d609a8e130ead3cf3de57be8e709508af25.tar.gz
Put a complete set of pppd(8) sample configuration files in
/usr/share/examples/pppd. Update pppd(8) documentation to reflect this, usr.sbin/pppd/pppd.8. Remove the out-of-place pppd(8) configuration files in etc/ppp, ppp.shells.sample and ppp.deny. Make the appropriate changes to the build process, etc/Makefile and etc/mtree/BSD.usr.mtree, so it all works. The files from etc/ppp, ppp.shells.sample and ppp.deny, were moved with a repo copy. Note it in the logs with a forced commit to these two. Submitted by: Maxim Konovalov <maxim@macomnet.ru> provided the new samples.
Diffstat (limited to 'share')
-rw-r--r--share/examples/pppd/auth-down.sample7
-rw-r--r--share/examples/pppd/auth-up.sample7
-rw-r--r--share/examples/pppd/chap-secrets.sample17
-rw-r--r--share/examples/pppd/chat.sh.sample33
-rw-r--r--share/examples/pppd/ip-down.sample7
-rw-r--r--share/examples/pppd/ip-up.sample8
-rw-r--r--share/examples/pppd/options.sample16
-rw-r--r--share/examples/pppd/pap-secrets.sample17
8 files changed, 112 insertions, 0 deletions
diff --git a/share/examples/pppd/auth-down.sample b/share/examples/pppd/auth-down.sample
new file mode 100644
index 0000000..b2da150
--- /dev/null
+++ b/share/examples/pppd/auth-down.sample
@@ -0,0 +1,7 @@
+#!/bin/sh
+#
+# $FreeBSD$
+#
+# Example for /etc/ppp/auth-down file.
+
+/usr/bin/logger -p daemon.notice -t pppd "User $2 is logged off"
diff --git a/share/examples/pppd/auth-up.sample b/share/examples/pppd/auth-up.sample
new file mode 100644
index 0000000..3d9c07e
--- /dev/null
+++ b/share/examples/pppd/auth-up.sample
@@ -0,0 +1,7 @@
+#!/bin/sh
+#
+# $FreeBSD$
+#
+# Example for /etc/ppp/auth-up file.
+
+/usr/bin/logger -p daemon.notice -t pppd "User $2 is logged in"
diff --git a/share/examples/pppd/chap-secrets.sample b/share/examples/pppd/chap-secrets.sample
new file mode 100644
index 0000000..40d5dfd
--- /dev/null
+++ b/share/examples/pppd/chap-secrets.sample
@@ -0,0 +1,17 @@
+# $FreeBSD$
+#
+# Example for /etc/ppp/chap-secrets file.
+#
+# This file should be owned by root and not readable or
+# writable by any other user.
+#
+# Dialin format: <remote name> <our name> <password> <allowed IP addresses>
+#
+joe server password 192.168.0.0/24 192.168.2.2
+lisa server l1z4 * !192.168.0.1
+mike server secret *
+luser server nopass -
+#
+# Dialout format: <our name> <server name> <password>
+#
+jane isp password
diff --git a/share/examples/pppd/chat.sh.sample b/share/examples/pppd/chat.sh.sample
new file mode 100644
index 0000000..6418ebf
--- /dev/null
+++ b/share/examples/pppd/chat.sh.sample
@@ -0,0 +1,33 @@
+#!/bin/sh
+#
+# $FreeBSD$
+#
+# Example for chat.sh file.
+
+INIT='at&f'
+
+dial(){
+ /usr/bin/chat -v \
+ ABORT "ERROR" \
+ ABORT "NO DIALTONE" \
+ TIMEOUT 5 \
+ "" "AT" \
+ "OK" "${INIT}" \
+ "OK"-"+++"-"" "ATH" \
+ ABORT "BUSY" \
+ ABORT "NO ANSWER" \
+ ABORT "NO CARRIER" \
+ "OK" "ATDP$1" \
+ TIMEOUT 70 \
+ "ogin:" "username" \
+ "word:" "pasword" \
+ TIMEOUT 50 \
+ "PPP" "\c"
+
+ [ $? -eq 0 ] && exit 0
+
+ echo "$1 failed" 1>&2
+ exit 1
+}
+
+dial 1234567
diff --git a/share/examples/pppd/ip-down.sample b/share/examples/pppd/ip-down.sample
new file mode 100644
index 0000000..45b8eb4
--- /dev/null
+++ b/share/examples/pppd/ip-down.sample
@@ -0,0 +1,7 @@
+#!/bin/sh
+#
+# $FreeBSD$
+#
+# Example for /etc/ppp/ip-down file.
+
+/usr/bin/logger -p daemon.notice -t pppd "$1 is down"
diff --git a/share/examples/pppd/ip-up.sample b/share/examples/pppd/ip-up.sample
new file mode 100644
index 0000000..a0fc1b0
--- /dev/null
+++ b/share/examples/pppd/ip-up.sample
@@ -0,0 +1,8 @@
+#!/bin/sh
+#
+# $FreeBSD$
+#
+# Example for /etc/ppp/ip-up file.
+
+/usr/bin/logger -p daemon.notice -t pppd "$1 is up"
+/usr/sbin/ntpdate ntpserver
diff --git a/share/examples/pppd/options.sample b/share/examples/pppd/options.sample
new file mode 100644
index 0000000..fd861b7
--- /dev/null
+++ b/share/examples/pppd/options.sample
@@ -0,0 +1,16 @@
+# $FreeBSD$
+#
+# Example for /etc/ppp/options file.
+#
+/dev/cuaa4
+115200
+modem
+crtscts
+asyncmap 0
+connect '/etc/ppp/chat.sh'
+defaultroute
+noipdefault
+persist
+holdoff 5
+mtu 250
+mru 250
diff --git a/share/examples/pppd/pap-secrets.sample b/share/examples/pppd/pap-secrets.sample
new file mode 100644
index 0000000..8896bdd
--- /dev/null
+++ b/share/examples/pppd/pap-secrets.sample
@@ -0,0 +1,17 @@
+# $FreeBSD$
+#
+# Example for /etc/ppp/pap-secrets file.
+#
+# This file should be owned by root and not readable or
+# writable by any other user.
+#
+# Dialin format: <remote name> <our name> <password> <allowed IP addresses>
+#
+joe server password 192.168.0.1/24 192.168.2.2
+lisa server l1z4 * !192.168.0.1
+mike server secret *
+luser server nopass -
+#
+# Dialout format: <our name> <server name> <password>
+#
+jane isp password
OpenPOWER on IntegriCloud