Update of /cvsroot/leaf/src/The_UnNamed_One/apps/ppp
In directory sc8-pr-cvs6.sourceforge.net:/tmp/cvs-serv15247
Added Files:
buildtool.cfg buildtool.mk common.cfg dsl-provider.atm
dsl-provider.pppoe ip-down ip-up ipv6-down ipv6-up options
pap-secrets plog poff pon ppp-2.4.4.tar.gz ppp-libpcap.patch
pppoatm-no-modprobe.patch pppol2tp.patch.gz
ppp_pathnames.h.patch ppp_syslog_local2.patch provider.chat
provider.peer
Log Message:
add ppp support
only tested if it compiles and starts on the qemu image yet
--- NEW FILE: dsl-provider.atm ---
#
# Adjust here VP/VC - depends on country & ISP
# UK/BT: 0.38 - US/BE/FR: 8.35
#
plugin /usr/lib/pppd/pppoatm.so 0.38
#
# If chap or pap identification uncomment the #name "ISPUserID" line
# and replace ISPUserID with your ISP user name
# There should be a matching entry in /etc/ppp/pap-secrets or chap-secrets
#
#name "ISPUserID"
lock
noipdefault
noauth
defaultroute
hide-password
lcp-echo-interval 20
lcp-echo-failure 3
maxfail 0
persist
--- NEW FILE: ip-up ---
#!/bin/sh
#
# $Id: ip-up,v 1.1 2008/03/01 18:39:13 kapeka Exp $
#
# This script is run by the pppd after the link is established.
# It uses run-parts to run scripts in /etc/ppp/ip-up.d, so to add routes,
# set IP address, run the mailq etc. you should create script(s) there.
#
# Be aware that other packages may include /etc/ppp/ip-up.d scripts (named
# after that package), so choose local script names with that in mind.
#
# This script is called with the following arguments:
# Arg Name Example
# $1 Interface name ppp0
# $2 The tty ttyS1
# $3 The link speed 38400
# $4 Local IP number 12.34.56.78
# $5 Peer IP number 12.34.56.99
# $6 Optional ``ipparam'' value foo
# The environment is cleared before executing this script
# so the path must be reset
PATH=/usr/local/sbin:/usr/sbin:/sbin:/usr/local/bin:/usr/bin:/bin
export PATH
# These variables are for the use of the scripts run by run-parts
PPP_IFACE="$1"
PPP_TTY="$2"
PPP_SPEED="$3"
PPP_LOCAL="$4"
PPP_REMOTE="$5"
PPP_IPPARAM="$6"
export PPP_IFACE PPP_TTY PPP_SPEED PPP_LOCAL PPP_REMOTE PPP_IPPARAM
# as an additional convenience, $PPP_TTYNAME is set to the tty name,
# stripped of /dev/ (if present) for easier matching.
PPP_TTYNAME=`/usr/bin/basename "$2"`
export PPP_TTYNAME
# Main Script starts here
run-parts /etc/ppp/ip-up.d
[ -x /bin/beep ] && /bin/beep -f 600 -n -f 900 -n -f1200 -n -f1800
# last line
--- NEW FILE: ip-down ---
#!/bin/sh
#
# $Id: ip-down,v 1.1 2008/03/01 18:39:13 kapeka Exp $
#
# This script is run by the pppd _after_ the link is brought down.
# It uses run-parts to run scripts in /etc/ppp/ip-down.d, so to delete
# routes, unset IP addresses etc. you should create script(s) there.
#
# Be aware that other packages may include /etc/ppp/ip-down.d scripts (named
# after that package), so choose local script names with that in mind.
#
# This script is called with the following arguments:
# Arg Name Example
# $1 Interface name ppp0
# $2 The tty ttyS1
# $3 The link speed 38400
# $4 Local IP number 12.34.56.78
# $5 Peer IP number 12.34.56.99
# $6 Optional ``ipparam'' value foo
# The environment is cleared before executing this script
# so the path must be reset
PATH=/usr/local/sbin:/usr/sbin:/sbin:/usr/local/bin:/usr/bin:/bin
export PATH
# These variables are for the use of the scripts run by run-parts
PPP_IFACE="$1"
PPP_TTY="$2"
PPP_SPEED="$3"
PPP_LOCAL="$4"
PPP_REMOTE="$5"
PPP_IPPARAM="$6"
export PPP_IFACE PPP_TTY PPP_SPEED PPP_LOCAL PPP_REMOTE PPP_IPPARAM
# as an additional convenience, $PPP_TTYNAME is set to the tty name,
# stripped of /dev/ (if present) for easier matching.
PPP_TTYNAME=`/usr/bin/basename "$2"`
export PPP_TTYNAME
# Main Script starts here
run-parts /etc/ppp/ip-down.d
[ -x /bin/beep ] && /bin/beep -f 1800 -n -f1200 -n -f900 -n -f600
# last line
--- NEW FILE: pppoatm-no-modprobe.patch ---
diff -urN ppp-2.4.4.orig/pppd/plugins/pppoatm/pppoatm.c
ppp-2.4.4/pppd/plugins/pppoatm/pppoatm.c
--- ppp-2.4.4.orig/pppd/plugins/pppoatm/pppoatm.c 2006-05-21
14:44:41.000000000 +0200
+++ ppp-2.4.4/pppd/plugins/pppoatm/pppoatm.c 2006-06-30 23:00:25.000000000
+0200
@@ -132,9 +132,9 @@
{
int fd;
struct atm_qos qos;
-
+/*
system ("/sbin/modprobe -q pppoatm");
-
+*/
if (!device_got_set)
no_device_given_pppoatm();
fd = socket(AF_ATMPVC, SOCK_DGRAM, 0);
--- NEW FILE: pon ---
#!/bin/sh
case "$1" in
-*) echo "
Usage: pon [provider] [arguments]
If pon is invoked without arguments, a PPP connection will be started
using settings from /etc/ppp/peers/provider. If you specify one argument,
a PPP connection will be started using settings from the appropriate
file in the /etc/ppp/peers/ directory, and any additional arguments
supplied will be passed as extra arguments to pppd.
"
exit 0
;;
esac
if [ -z "$1" -a ! -f /etc/ppp/peers/provider ]; then
echo "
Please configure /etc/ppp/peers/provider or use a command line argument to
use another file in /etc/ppp/peers/ directory.
"
exit 1
fi
if [ "$1" -a ! -f "/etc/ppp/peers/$1" ]; then
echo "
The file /etc/ppp/peers/$1 does not exist.
"
exit 1
fi
exec /usr/sbin/pppd call ${@:-provider}
--- NEW FILE: common.cfg ---
<File>
Source = etc/ppp/peers/provider
Filename = etc/ppp/peers/provider
Description = ISP pppd options
Type = conf
Type = binary
Permissions = 755
</File>
<File>
Source = etc/chatscripts/provider
Filename = etc/chatscripts/provider
Description = ISP login script
Type = conf
Type = binary
Permissions = 755
</File>
<File>
Source = etc/ppp/options
Filename = etc/ppp/options
Description = System wide pppd options
Type = conf
Type = binary
Permissions = 644
</File>
<File>
Source = etc/ppp/chap-secrets
Filename = etc/ppp/chap-secrets
Description = chap secret
Type = conf
Type = binary
Permissions = 600
</File>
<File>
Source = etc/ppp/pap-secrets
Filename = etc/ppp/pap-secrets
Description = pap secret
Type = conf
Type = binary
Permissions = 600
</File>
<File>
Source = etc/ppp/ip-down
Filename = etc/ppp/ip-down
Type = binary
Permissions = 755
</File>
<File>
Source = etc/ppp/ip-up
Filename = etc/ppp/ip-up
Type = binary
Permissions = 755
</File>
<File>
Source = etc/ppp/ipv6-down
Filename = etc/ppp/ipv6-down
Type = binary
Permissions = 755
</File>
<File>
Source = etc/ppp/ipv6-up
Filename = etc/ppp/ipv6-up
Type = binary
Permissions = 755
</File>
<File>
Source = etc/ppp/ip-down.d
Filename = etc/ppp/ip-down.d
Type = directory
Permissions = 755
</File>
<File>
Source = etc/ppp/ip-up.d
Filename = etc/ppp/ip-up.d
Type = directory
Permissions = 755
</File>
<File>
Source = etc/ppp/ipv6-down.d
Filename = etc/ppp/ipv6-down.d
Type = directory
Permissions = 755
</File>
<File>
Source = etc/ppp/ipv6-up.d
Filename = etc/ppp/ipv6-up.d
Type = directory
Permissions = 755
</File>
<File>
Source = usr/bin/pon
Filename = usr/bin/pon
Type = binary
Permissions = 755
</File>
<File>
Source = usr/bin/poff
Filename = usr/bin/poff
Type = binary
Permissions = 755
</File>
<File>
Source = usr/bin/plog
Filename = usr/bin/plog
Type = binary
Permissions = 755
</File>
<File>
Source = usr/sbin/chat
Filename = usr/sbin/chat
Type = binary
Permissions = 755
</File>
<File>
Source = usr/sbin/pppd
Filename = usr/sbin/pppd
Type = binary
Permissions = 755
</File>
<File>
Source = usr/sbin/pppstats
Filename = usr/sbin/pppstats
Type = binary
Permissions = 755
</File>
<File>
Source = usr/lib/pppd
Filename = usr/lib/pppd
Type = directory
Permissions = 755
</File>
<File>
Filename = etc/ppp
Type = local
</File>
<File>
Filename = etc/chatscripts
Type = local
</File>
--- NEW FILE: plog ---
#!/bin/sh
if [ -s /var/log/ppp.log ]; then
exec tail "$@" /var/log/ppp.log
else
exec tail "$@" /var/log/syslog | grep ' \(pppd\|chat\)\['
fi
--- NEW FILE: buildtool.cfg ---
<File buildtool.mk>
Server = cvs-sourceforge
Revision = HEAD
Directory = ppp
</File>
<File common.cfg>
Server = cvs-sourceforge
Revision = HEAD
Directory = ppp
</File>
<File ppp-2.4.4.tar.gz>
Server = cvs-sourceforge
Revision = HEAD
envname = PPP_SOURCE
Directory = ppp
</File>
<File pppoatm-no-modprobe.patch>
Server = cvs-sourceforge
Revision = HEAD
envname = PPP_PATCH1
Directory = ppp
</File>
<File ppp-libpcap.patch>
Server = cvs-sourceforge
Revision = HEAD
envname = PPP_PATCH2
Directory = ppp
</File>
<File ppp_syslog_local2.patch>
Server = cvs-sourceforge
Revision = HEAD
envname = PPP_PATCH3
Directory = ppp
</File>
<File ppp_pathnames.h.patch>
Server = cvs-sourceforge
Revision = HEAD
envname = PPP_PATCH4
Directory = ppp
</File>
<File pppol2tp.patch.gz>
Server = cvs-sourceforge
Revision = HEAD
envname = PPP_PATCH5
Directory = ppp
</File>
<File dsl-provider.atm>
Server = cvs-sourceforge
Revision = HEAD
Directory = ppp
</File>
<File dsl-provider.pppoe>
Server = cvs-sourceforge
Revision = HEAD
Directory = ppp
</File>
<File ip-down>
Server = cvs-sourceforge
Revision = HEAD
Directory = ppp
</File>
<File ip-up>
Server = cvs-sourceforge
Revision = HEAD
Directory = ppp
</File>
<File ipv6-down>
Server = cvs-sourceforge
Revision = HEAD
Directory = ppp
</File>
<File ipv6-up>
Server = cvs-sourceforge
Revision = HEAD
Directory = ppp
</File>
<File options>
Server = cvs-sourceforge
Revision = HEAD
Directory = ppp
</File>
<File pap-secrets>
Server = cvs-sourceforge
Revision = HEAD
Directory = ppp
</File>
<File pon>
Server = cvs-sourceforge
Revision = HEAD
Directory = ppp
</File>
<File poff>
Server = cvs-sourceforge
Revision = HEAD
Directory = ppp
</File>
<File plog>
Server = cvs-sourceforge
Revision = HEAD
Directory = ppp
</File>
<File provider.chat>
Server = cvs-sourceforge
Revision = HEAD
Directory = ppp
</File>
<File provider.peer>
Server = cvs-sourceforge
Revision = HEAD
Directory = ppp
</File>
<Package>
<ppp>
Version = 2.4.4
Revision = 3
Help <<EOF
Point-to-Point Protocol (PPP) daemon, ipv6 enabled
Includes support for rp-pppoe and pppoatm
Homepage: ftp://ftp.samba.org/pub/ppp
LEAF package by __PACKAGER__, __BUILDDATE__
EOF
<Permissions>
Files = 644
Directories = 755
</Permissions>
<Owner>
Files = root:root
Directories = root:root
</Owner>
<Contents>
#include <common.cfg>
<File>
Source = usr/sbin/pppd
Filename = usr/sbin/pppd
Type = binary
Permissions = 755
</File>
</Contents>
</ppp>
<ppp-filter>
packagename = ppp
Version = 2.4.4
Revision = 4
Help <<EOF
Point-to-Point Protocol (PPP) daemon with filter support, ipv6
enabled
Includes support for rp-pppoe and pppoatm.
Homepage: ftp://ftp.samba.org/pub/ppp
Requires: libpcap.lrp
LEAF package by __PACKAGER__, __BUILDDATE__
EOF
<Permissions>
Files = 644
Directories = 755
</Permissions>
<Owner>
Files = root:root
Directories = root:root
</Owner>
<Contents>
#include <common.cfg>
<File>
Source = usr/sbin/pppd-filter
Filename = usr/sbin/pppd
Type = binary
Permissions = 755
</File>
</Contents>
</ppp-filter>
<pppoe>
Version = 2.4.4
Revision = 2
Help <<EOF
rp-pppoe plugin for pppd
Homepage: ftp://ftp.samba.org/pub/ppp
Requires: ppp.lrp
LEAF package by __PACKAGER__, __BUILDDATE__
EOF
<Permissions>
Files = 644
Directories = 755
</Permissions>
<Owner>
Files = root:root
Directories = root:root
</Owner>
<Contents>
<File>
Source = etc/ppp/peers/dsl-provider
Filename = etc/ppp/peers/dsl-provider
Description = DSL pppd options
Type = conf
Type = local
Type = binary
Permissions = 644
</File>
<File>
Source = usr/lib/pppd/rp-pppoe.so
Filename = usr/lib/pppd/rp-pppoe.so
Type = binary
Permissions = 755
</File>
</Contents>
</pppoe>
<pppoatm>
Version = 2.4.4
Revision = 2
Help <<EOF
pppoatm plugin for pppd
Homepage: ftp://ftp.samba.org/pub/ppp
Requires: ppp.lrp
LEAF package by __PACKAGER__, __BUILDDATE__
EOF
<Permissions>
Files = 644
Directories = 755
</Permissions>
<Owner>
Files = root:root
Directories = root:root
</Owner>
<Contents>
<File>
Source = etc/ppp/peers/dsl-provider.atm
Filename = etc/ppp/peers/dsl-provider
Description = DSL pppd options
Type = conf
Type = local
Type = binary
Permissions = 644
</File>
<File>
Source = usr/lib/pppd/pppoatm.so
Filename = usr/lib/pppd/pppoatm.so
Type = binary
Permissions = 755
</File>
</Contents>
</pppoatm>
<ppp-rad>
Version = 2.4.4
Revision = 2
Help <<EOF
radius plugin for pppd
Homepage: ftp://ftp.samba.org/pub/ppp
Requires: ppp.lrp
LEAF package by __PACKAGER__, __BUILDDATE__
EOF
<Permissions>
Files = 644
Directories = 755
</Permissions>
<Owner>
Files = root:root
Directories = root:root
</Owner>
<Contents>
<File>
Source = etc/radiusclient/*
Filename = etc/radiusclient
Type = local
Type = binary
</File>
<File>
Filename =
etc/radiusclient/radiusclient.conf
Description = RADIUS client options
Type = conf
</File>
<File>
Filename = etc/radiusclient/servers
Description = RADIUS server secrets
Type = conf
Permissions = 600
</File>
<File>
Source = usr/lib/pppd/radius.so
Filename = usr/lib/pppd/radius.so
Type = binary
Permissions = 755
</File>
<File>
Source = usr/lib/pppd/radattr.so
Filename = usr/lib/pppd/radattr.so
Type = binary
Permissions = 755
</File>
<File>
Source = usr/lib/pppd/radrealms.so
Filename = usr/lib/pppd/radrealms.so
Type = binary
Permissions = 755
</File>
</Contents>
</ppp-rad>
<pppol2tp>
Version = 0.13
Revision = 1
Help <<EOF
pppol2tp plugin for pppd
Homepage: http://opensource.katalix.com/openl2tp/
Requires: ppp.lrp
LEAF package by __PACKAGER__, __BUILDDATE__
EOF
<Permissions>
Files = 644
Directories = 755
</Permissions>
<Owner>
Files = root:root
Directories = root:root
</Owner>
<Contents>
<File>
Source = usr/lib/pppd/pppol2tp.so
Filename = usr/lib/pppd/pppol2tp.so
Type = binary
Permissions = 755
</File>
</Contents>
</pppol2tp>
</Package>
--- NEW FILE: provider.chat ---
# ISP login script
# What follows is OK for PAP/CHAP ISP's
# Adjust to your taste
REPORT CONNECT
ABORT "BUSY"
ABORT "NO CARRIER"
ABORT "VOICE"
ABORT "NO DIALTONE"
ABORT "NO ANSWER"
"" ATZ
# ISP telephone number: 1245678
OK ATDT12345678
CONNECT ""
--- NEW FILE: ipv6-down ---
#!/bin/sh
# These variables are for the use of the scripts run by run-parts.
PPP_IFACE="$1"
PPP_TTY="$2"
PPP_SPEED="$3"
PPP_LOCAL="$4"
PPP_REMOTE="$5"
PPP_IPPARAM="$6"
export PPP_IFACE PPP_TTY PPP_SPEED PPP_LOCAL PPP_REMOTE PPP_IPPARAM
# The environment is cleared before executing this script.
PATH=/usr/local/sbin:/usr/sbin:/sbin:/usr/local/bin:/usr/bin:/bin
export PATH
run-parts /etc/ppp/ipv6-down.d
--- NEW FILE: ppp-2.4.4.tar.gz ---
(This appears to be a binary file; contents omitted.)
--- NEW FILE: ipv6-up ---
#!/bin/sh
# These variables are for the use of the scripts run by run-parts.
PPP_IFACE="$1"
PPP_TTY="$2"
PPP_SPEED="$3"
PPP_LOCAL="$4"
PPP_REMOTE="$5"
PPP_IPPARAM="$6"
export PPP_IFACE PPP_TTY PPP_SPEED PPP_LOCAL PPP_REMOTE PPP_IPPARAM
# The environment is cleared before executing this script.
PATH=/usr/local/sbin:/usr/sbin:/sbin:/usr/local/bin:/usr/bin:/bin
export PATH
run-parts /etc/ppp/ipv6-up.d
--- NEW FILE: pppol2tp.patch.gz ---
(This appears to be a binary file; contents omitted.)
--- NEW FILE: ppp_pathnames.h.patch ---
--- ppp-2.4.0b4.orig/pppd/pathnames.h
+++ ppp-2.4.0b4/pppd/pathnames.h
@@ -26,7 +26,7 @@
#define _PATH_AUTHUP _ROOT_PATH "/etc/ppp/auth-up"
#define _PATH_AUTHDOWN _ROOT_PATH "/etc/ppp/auth-down"
#define _PATH_TTYOPT _ROOT_PATH "/etc/ppp/options."
-#define _PATH_CONNERRS _ROOT_PATH "/etc/ppp/connect-errors"
+#define _PATH_CONNERRS _ROOT_PATH "/var/log/ppp-connect-errors"
#define _PATH_PEERFILES _ROOT_PATH "/etc/ppp/peers/"
#define _PATH_RESOLV _ROOT_PATH "/etc/ppp/resolv.conf"
@@ -57,7 +57,7 @@
#ifdef PLUGIN
#ifdef __STDC__
-#define _PATH_PLUGIN DESTDIR "/lib/pppd/" VERSION
+#define _PATH_PLUGIN DESTDIR "/lib/pppd/"
#else /* __STDC__ */
#define _PATH_PLUGIN "/usr/lib/pppd"
#endif /* __STDC__ */
--- NEW FILE: provider.peer ---
# ISP pppd options file
# What follows is OK for PAP/CHAP ISP's
#
noauth
debug # log transaction to /var/log/messages
/dev/ttyS0 # (ttyS0=com1, ttyS1=com2, ...)
115200 # baud rate
modem
crtscts # use hardware flow control
asyncmap 0
defaultroute # ppp becomes default route to the internet
noipdefault
lock # don't let other processes besides PPP use the device
#MUST CHANGE
user your_ISP_login
connect "/usr/sbin/chat -v -f /etc/chatscripts/provider"
--- NEW FILE: ppp-libpcap.patch ---
diff -urN ppp-2.4.3.orig/pppd/Makefile.linux ppp-2.4.3/pppd/Makefile.linux
--- ppp-2.4.3.orig/pppd/Makefile.linux Sat Nov 13 13:02:22 2004
+++ ppp-2.4.3/pppd/Makefile.linux Wed Nov 24 14:52:27 2004
@@ -171,10 +171,8 @@
endif
ifdef FILTER
-ifneq ($(wildcard /usr/include/pcap-bpf.h),)
LIBS += -lpcap
CFLAGS += -DPPP_FILTER
-endif
endif
ifdef HAVE_INET6
--- NEW FILE: ppp_syslog_local2.patch ---
diff -ruN ppp.orig/pppd/pppd.h ppp/pppd/pppd.h
--- ppp.orig/pppd/pppd.h 2003-11-28 00:30:27.000000000 +0100
+++ ppp/pppd/pppd.h 2003-11-28 00:30:20.000000000 +0100
@@ -812,7 +812,7 @@
|| defined(DEBUGCHAP) || defined(DEBUG) || defined(DEBUGIPV6CP)
#define LOG_PPP LOG_LOCAL2
#else
-#define LOG_PPP LOG_DAEMON
+#define LOG_PPP LOG_LOCAL2
#endif
#endif /* LOG_PPP */
--- NEW FILE: poff ---
#!/bin/sh
# $Id: poff,v 1.1 2008/03/01 18:39:13 kapeka Exp $
# Written by John Hasler <[EMAIL PROTECTED]> and based on work
# by Phil Hands <[EMAIL PROTECTED]>. Distributed under the GNU GPL
if [ -x /usr/bin/kill ]; then
KILL="/usr/bin/kill"
else
KILL="/bin/kill"
fi
SIG=TERM
DONE="stopped"
MODE=""
usage ()
{
cat <<!EOF!
usage: $0 [option] [provider]
options:
-r Cause pppd to drop the line and redial.
-d Toggle the state of pppd's debug option.
-c Cause pppd to renegotiate compression.
-a Stop all pppd's. 'provider' will be ignored.
-h Print this help summary and exit.
-v Print version and exit.
none Stop pppd.
Options may not be combined.
If 'provider' is omitted pppd will be stopped or signalled if and only if
there is exactly one running unless the '-a' option was given. If
'provider' is supplied the pppd controlling the connection to that
provider will be stopped or signalled.
!EOF!
}
# Get option. If there are none replace the "?" that getopts puts in
# FLAG on error with "null".
getopts rdcavh FLAG
if [ "$?" -ne 0 ]; then
FLAG="null"
fi
# Check for additional options. Should be none.
getopts :rdcavh DUMMY
if [ "$?" -eq 0 ]; then
echo "$0: Illegal option -- ${OPTARG}."
exit 1
fi
case $FLAG in
"r") SIG=HUP; DONE=signalled; shift ;;
"d") SIG=USR1; DONE=signalled; shift ;;
"c") SIG=USR2; DONE=signalled; shift ;;
"a") MODE="all"; shift ;;
"v") echo "$0$Revision: 1.1 $_TrickToPrint_RCS_Revision"; exit 0 ;;
"h") usage; exit 0 ;;
"?") exit 1;
esac
# Get the PIDs of all the pppds running. Could also get these from
# /var/run, but pppd doesn't create .pid files until ppp is up.
PIDS=`pidof pppd`
# poff is pointless if pppd isn't running.
if test -z "$PIDS"; then
echo "$0: No pppd is running. None ${DONE}."
exit 1
fi
# Find out how many pppd's are running.
N=`echo "$PIDS" | wc -w`
# If there are no arguments we can't do anything if there is more than one
# pppd running.
if test "$#" -eq 0 -a "$N" -gt 1 -a $FLAG != "a" ; then
echo "$0: More than one pppd running and no "-a" option and
no arguments supplied. Nothing ${DONE}."
exit 1
fi
# If either there are no arguments or '-a' was specified kill all the
# pppd's.
if test "$#" -eq 0 -o "$MODE" = "all" ; then
$KILL -$SIG $PIDS || {
echo "$0: $KILL failed. None ${DONE}."
exit 1
}
exit 0
fi
# There is an argument, so kill the pppd started on that provider.
PID=`ps axw | grep "[ /]pppd call $1 .*\$" | sed 's/ *//;s/ .*//'`
if test -n "$PID" ; then
$KILL -$SIG $PID || {
echo "$0: $KILL failed. None ${DONE}."
exit 1
}
else
echo "$0: I could not find a pppd process for provider '$1'. None ${DONE}."
exit 1
fi
exit 0
--- NEW FILE: buildtool.mk ---
# makefile for ppp, ppp-filter, pppoe and pppoatm
include $(MASTERMAKEFILE)
PPP_DIR:=ppp-2.4.4
PPP_TARGET_DIR:=$(BT_BUILD_DIR)/ppp
$(PPP_DIR)/.source:
zcat $(PPP_SOURCE) | tar -xvf -
cat $(PPP_PATCH1) | patch -d $(PPP_DIR) -p1
cat $(PPP_PATCH2) | patch -d $(PPP_DIR) -p1
cat $(PPP_PATCH3) | patch -d $(PPP_DIR) -p1
cat $(PPP_PATCH4) | patch -d $(PPP_DIR) -p1
zcat $(PPP_PATCH5) | patch -d $(PPP_DIR) -p1
touch $(PPP_DIR)/.source
source: $(PPP_DIR)/.source
$(PPP_DIR)/.configured: $(PPP_DIR)/.source
(cd $(PPP_DIR) ; CC=$(TARGET_CC) LD=$(TARGET_LD) ./configure
--prefix=/usr)
touch $(PPP_DIR)/.configured
$(PPP_DIR)/.build: $(PPP_DIR)/.configured
mkdir -p $(PPP_TARGET_DIR)
mkdir -p $(PPP_TARGET_DIR)/etc/chatscripts
mkdir -p $(PPP_TARGET_DIR)/etc/ppp
mkdir -p $(PPP_TARGET_DIR)/etc/ppp/peers
mkdir -p $(PPP_TARGET_DIR)/etc/radiusclient
mkdir -p $(PPP_TARGET_DIR)/usr/bin
mkdir -p $(PPP_TARGET_DIR)/usr/sbin
mkdir -p $(PPP_TARGET_DIR)/usr/lib/pppd
make CC=$(TARGET_CC) -C $(PPP_DIR) COPTS="-Os -pipe -Wall -g" FILTER=
HAVE_INET6=y CBCP=
-$(BT_STRIP) -s --remove-section=.note --remove-section=.comment
$(PPP_DIR)/pppd/pppd
-$(BT_STRIP) -s --remove-section=.note --remove-section=.comment
$(PPP_DIR)/pppstats/pppstats
-$(BT_STRIP) -s --remove-section=.note --remove-section=.comment
$(PPP_DIR)/chat/chat
-$(BT_STRIP) -s --strip-unneeded
$(PPP_DIR)/pppd/plugins/pppoatm/pppoatm.so
-$(BT_STRIP) -s --strip-unneeded
$(PPP_DIR)/pppd/plugins/rp-pppoe/rp-pppoe.so
-$(BT_STRIP) -s --strip-unneeded $(PPP_DIR)/pppd/plugins/radius/*.so
-$(BT_STRIP) -s --strip-unneeded $(PPP_DIR)/pppd/plugins/*.so
cp -a poff $(PPP_TARGET_DIR)/usr/bin
cp -a plog $(PPP_TARGET_DIR)/usr/bin
cp -a pon $(PPP_TARGET_DIR)/usr/bin
cp -a $(PPP_DIR)/pppd/pppd $(PPP_TARGET_DIR)/usr/sbin
cp -a $(PPP_DIR)/pppstats/pppstats $(PPP_TARGET_DIR)/usr/sbin
cp -a $(PPP_DIR)/chat/chat $(PPP_TARGET_DIR)/usr/sbin
cp -a $(PPP_DIR)/pppd/plugins/pppoatm/pppoatm.so
$(PPP_TARGET_DIR)/usr/lib/pppd
cp -a $(PPP_DIR)/pppd/plugins/rp-pppoe/rp-pppoe.so
$(PPP_TARGET_DIR)/usr/lib/pppd
cp -a $(PPP_DIR)/pppd/plugins/radius/*.so $(PPP_TARGET_DIR)/usr/lib/pppd
cp -a $(PPP_DIR)/pppd/plugins/pppol2tp.so $(PPP_TARGET_DIR)/usr/lib/pppd
cp -a $(PPP_DIR)/etc.ppp/chap-secrets $(PPP_TARGET_DIR)/etc/ppp
cp -a options $(PPP_TARGET_DIR)/etc/ppp
cp -a pap-secrets $(PPP_TARGET_DIR)/etc/ppp
cp -a ip-up $(PPP_TARGET_DIR)/etc/ppp
cp -a ip-down $(PPP_TARGET_DIR)/etc/ppp
cp -a ipv6-up $(PPP_TARGET_DIR)/etc/ppp
cp -a ipv6-down $(PPP_TARGET_DIR)/etc/ppp
cp -a provider.chat $(PPP_TARGET_DIR)/etc/chatscripts/provider
cp -a provider.peer $(PPP_TARGET_DIR)/etc/ppp/peers/provider
cp -a dsl-provider.atm $(PPP_TARGET_DIR)/etc/ppp/peers/
cp -a dsl-provider.pppoe $(PPP_TARGET_DIR)/etc/ppp/peers/dsl-provider
cp -a $(PPP_DIR)/pppd/plugins/radius/etc/radiusclient.conf
$(PPP_TARGET_DIR)/etc/radiusclient
cp -a $(PPP_DIR)/pppd/plugins/radius/etc/dictionary
$(PPP_TARGET_DIR)/etc/radiusclient
cp -a $(PPP_DIR)/pppd/plugins/radius/etc/dictionary.microsoft
$(PPP_TARGET_DIR)/etc/radiusclient
cp -a $(PPP_DIR)/pppd/plugins/radius/etc/servers
$(PPP_TARGET_DIR)/etc/radiusclient
cp -a $(PPP_DIR)/pppd/plugins/radius/etc/port-id-map
$(PPP_TARGET_DIR)/etc/radiusclient
$(MAKE) -C $(PPP_DIR) clean
make CC=$(TARGET_CC) -C $(PPP_DIR) COPTS="-Os -pipe -Wall -g
-I$(BT_STAGING_DIR)/usr/include" FILTER=y HAVE_INET6=y CBCP=
-$(BT_STRIP) -s --remove-section=.note --remove-section=.comment
$(PPP_DIR)/pppd/pppd
cp -a $(PPP_DIR)/pppd/pppd $(PPP_TARGET_DIR)/usr/sbin/pppd-filter
cp -a $(PPP_TARGET_DIR)/* $(BT_STAGING_DIR)
touch $(PPP_DIR)/.build
build: $(PPP_DIR)/.build
clean:
rm -rf $(PPP_TARGET_DIR)
$(MAKE) -C $(PPP_DIR) clean
rm -f $(PPP_DIR)/.build
rm -f $(PPP_DIR)/.configured
srcclean: clean
rm -rf $(PPP_DIR)
rm -f $(PPP_DIR)/.source
--- NEW FILE: dsl-provider.pppoe ---
# Configuration file for PPP, using PPP over Ethernet
# to connect to a DSL provider.
#
plugin /usr/lib/pppd/rp-pppoe.so
# MUST CHANGE: Uncomment the following line, replacing the [EMAIL PROTECTED]
# by the DSL user name given to your by your DSL provider.
# (There should be a matching entry in /etc/ppp/pap-secrets with the password.)
name "[EMAIL PROTECTED]"
# Use the pppoe program to send the ppp packets over the Ethernet link
# This line should work fine if this computer is the only one accessing
# the Internet through this DSL connection. This is the right line to use
# for most people.
#pty "pppoe -I eth0 -T 80 -m 1452"
# If the computer connected to the Internet using pppoe is not being used
# by other computers as a gateway to the Internet, you can try the following
# line instead, for a small gain in speed:
#pty "pppoe -I eth0 -T 80"
# An even more conservative version of the previous line, if things
# don't work using -m 1452...
#pty "pppoe -I eth0 -T 80 -m 1412"
# The following two options should work fine for most DSL users.
# Assumes that your IP address is allocated dynamically
# by your DSL provider...
noipdefault
# Comment out if you already have the correct default route installed
defaultroute
##
# Section 2
#
# Uncomment if your DSL provider charges by minute connected
# and you want to use demand-dialing.
#
# Disconnect after 300 seconds (5 minutes) of idle time.
#demand
#idle 300
##
# Section 3
#
# You shouldn't need to change these options...
hide-password
lcp-echo-interval 20
lcp-echo-failure 3
# Override any connect script that may have been set in /etc/ppp/options.
connect /bin/true
noauth
persist
# Set maxfail to 0 for unlimited connections attemps
maxfail 10
mtu 1492
--- NEW FILE: pap-secrets ---
# This is a pap-secrets file
#
#papname * papsecret
--- NEW FILE: options ---
# /etc/ppp/options
asyncmap 0
auth
crtscts
lock
hide-password
modem
proxyarp
usepeerdns
lcp-echo-interval 30
lcp-echo-failure 4
noipx
-------------------------------------------------------------------------
This SF.net email is sponsored by: Microsoft
Defy all challenges. Microsoft(R) Visual Studio 2008.
http://clk.atdmt.com/MRT/go/vse0120000070mrt/direct/01/
_______________________________________________
leaf-cvs-commits mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/leaf-cvs-commits