generated from smedev/Template-for-SMEServer-Core-Perl
	initial
This commit is contained in:
		
							
								
								
									
										2
									
								
								Makefile
									
									
									
									
									
								
							
							
						
						
									
										2
									
								
								Makefile
									
									
									
									
									
								
							| @@ -1,4 +1,4 @@ | ||||
| NAME := rd-pppoe | ||||
| NAME := rp-pppoe | ||||
| SPECFILE = $(firstword $(wildcard *.spec)) | ||||
|  | ||||
| define find-makefile-common | ||||
|   | ||||
| @@ -1,14 +1,11 @@ | ||||
| # <img src="https://www.koozali.org/images/koozali/Logo/Png/Koozali_logo_2016.png" width="25%" vertical="auto" style="vertical-align:bottom"> rd-pppoe | ||||
|  | ||||
| SMEServer Koozali local git repo for rd-pppoe   | ||||
|  | ||||
| ## Documentation | ||||
| <br />https://metacpan.org/pod/rd-pppoe | ||||
| SMEServer Koozali local git repo for rp-pppoe   | ||||
|  | ||||
| ## Bugzilla | ||||
| CPAN bug report are [here](https://rt.cpan.org/Public/Dist/Display.html?Name=rd-pppoe) | ||||
| CPAN bug report are [here](https://rt.cpan.org/Public/Dist/Display.html?Name=rp-pppoe) | ||||
|  | ||||
| Show list of Koozali outstanding bugs: [here](https://bugs.koozali.org/buglist.cgi?component=rd-pppoe&product=SME%20Server%2011.X&query_format=advanced&limit=0&bug_status=UNCONFIRMED&bug_status=NEW&bug_status=ASSIGNED&bug_status=REOPENED&bug_status=CONFIRMED) | ||||
| Show list of Koozali outstanding bugs: [here](https://bugs.koozali.org/buglist.cgi?component=rp-pppoe&product=SME%20Server%2011.X&query_format=advanced&limit=0&bug_status=UNCONFIRMED&bug_status=NEW&bug_status=ASSIGNED&bug_status=REOPENED&bug_status=CONFIRMED) | ||||
|  | ||||
| ## Description | ||||
|  | ||||
|   | ||||
| @@ -1,55 +0,0 @@ | ||||
| %define name rd-pppoe | ||||
| %define version 1.0 | ||||
| %define release 1 | ||||
| Summary: This is what rd-pppoe does. | ||||
| Name: %{name} | ||||
| Version: %{version} | ||||
| Release: %{release}%{?dist} | ||||
| Source: %{name}-%{version}.tar.gz | ||||
| License: GNU GPL version 2 | ||||
| Group: SMEserver/addon | ||||
| BuildRoot: %{_tmppath}/%{name}-buildroot | ||||
| Prefix: %{_prefix} | ||||
| BuildArchitectures: noarch | ||||
| BuildRequires: e-smith-devtools | ||||
| Requires: e-smith-release >= 10.0 | ||||
| AutoReqProv: no | ||||
|  | ||||
| %description | ||||
|  pppoe - user-space PPPoE client. | ||||
|  | ||||
| %changelog | ||||
| * Day MMMM DD YYYY <brianr@koozali.org> 1.0-1.sme | ||||
| - Initial code - create RPM [SME:99999] | ||||
|  | ||||
| %prep | ||||
|  | ||||
| %setup -q | ||||
|  | ||||
| %build | ||||
| perl createlinks | ||||
|  | ||||
| %install | ||||
| rm -rf $RPM_BUILD_ROOT | ||||
| (cd root   ; find . -depth -print | cpio -dump $RPM_BUILD_ROOT) | ||||
| rm -f %{name}-%{version}-filelist | ||||
| /sbin/e-smith/genfilelist $RPM_BUILD_ROOT \ | ||||
| > %{name}-%{version}-filelist | ||||
| #echo "%doc COPYING"  >> %{name}-%{version}-filelist | ||||
| #--dir <dir> 'attr(755,user,grp)' \ | ||||
| #--file <file> 'attr(755,root,root)' \ | ||||
|  | ||||
| %clean | ||||
| cd .. | ||||
| rm -rf %{name}-%{version} | ||||
|  | ||||
| %pre | ||||
|  | ||||
| %preun | ||||
|  | ||||
| %post | ||||
|  | ||||
| %postun | ||||
| #uninstall | ||||
| %files -f %{name}-%{version}-filelist | ||||
| %defattr(-,root,root) | ||||
							
								
								
									
										398
									
								
								pppoe-connect
									
									
									
									
									
										Executable file
									
								
							
							
						
						
									
										398
									
								
								pppoe-connect
									
									
									
									
									
										Executable file
									
								
							| @@ -0,0 +1,398 @@ | ||||
| #! /bin/bash | ||||
| # Generated automatically from pppoe-connect.in by configure. | ||||
| #*********************************************************************** | ||||
| # | ||||
| # pppoe-connect | ||||
| # | ||||
| # Shell script to connect to an PPPoE provider using PPPoE | ||||
| # | ||||
| # Copyright (C) 2000 Roaring Penguin Software Inc. | ||||
| # | ||||
| # $Id$ | ||||
| # | ||||
| # This file may be distributed under the terms of the GNU General | ||||
| # Public License. | ||||
| # | ||||
| # Usage: pppoe-connect [config_file] | ||||
| #        pppoe-connect interface user [config_file] | ||||
| # Second form overrides USER and ETH from config file. | ||||
| # If config_file is omitted, defaults to /etc/ppp/pppoe.conf | ||||
| # | ||||
| #*********************************************************************** | ||||
|  | ||||
| # From AUTOCONF | ||||
| prefix=/usr | ||||
| exec_prefix=/usr | ||||
| localstatedir=/var | ||||
|  | ||||
| # Paths to programs | ||||
| IP=/sbin/ip | ||||
| PPPD=/usr/sbin/pppd | ||||
| SETSID=/usr/bin/setsid | ||||
| PPPOE=/usr/sbin/pppoe | ||||
| BR2684CTL=/usr/sbin/br2684ctl | ||||
| LOGGER="/usr/bin/logger -t `basename $0`" | ||||
| NETWORKDIR=/etc/sysconfig/network-scripts | ||||
| LS=/bin/ls | ||||
|  | ||||
| get_device() { | ||||
|     if [ ! -d $NETWORKDIR ] ; then | ||||
|         $ECHO "** $NETWORKDIR not found" | ||||
|         $ECHO "** Quitting" | ||||
|         exit 1 | ||||
|     fi | ||||
|  | ||||
|     cd $NETWORKDIR | ||||
|     interfaces=$($LS ifcfg-ppp* 2>/dev/null | egrep -v '(~|\.bak)$' | \ | ||||
|                  egrep -v '(rpmsave|rpmorig|rpmnew)' | sed 's/^ifcfg-//g') | ||||
|  | ||||
|     for i in $interfaces ; do | ||||
|         test -f ifcfg-$i && . ifcfg-$i 2>/dev/null | ||||
|         if [ "$TYPE" = "xDSL" ] ; then | ||||
|             CONFIG=$NETWORKDIR/ifcfg-$i | ||||
|             break | ||||
|         fi | ||||
|     done | ||||
| } | ||||
|  | ||||
| # Set to "C" locale so we can parse messages from commands | ||||
| LANG=C | ||||
| export LANG | ||||
|  | ||||
| # Must be root | ||||
| if test "`/usr/bin/id -u`" != 0 ; then | ||||
|     echo "$0: You must be root to run this script" >& 2 | ||||
|     exit 1 | ||||
| fi | ||||
|  | ||||
| if test "$SETSID" != "" -a ! -x "$SETSID"; then | ||||
|     SETSID="" | ||||
| fi | ||||
|  | ||||
| USER="" | ||||
| ETH="" | ||||
|  | ||||
| # Sort out command-line arguments | ||||
| case "$#" in | ||||
|     1) | ||||
| 	CONFIG="$1" | ||||
| 	;; | ||||
|     3) | ||||
| 	CONFIG="$3" | ||||
| 	;; | ||||
| esac | ||||
|  | ||||
| if [ -z "$CONFIG" ] ; then | ||||
|     get_device | ||||
|     [ -z "$CONFIG" ] && CONFIG=/etc/ppp/pppoe.conf | ||||
| fi | ||||
|  | ||||
| if test ! -f "$CONFIG" -o ! -r "$CONFIG" ; then | ||||
|     echo "$0: Cannot read configuration file '$CONFIG'" >& 2 | ||||
|     exit 1 | ||||
| fi | ||||
|  | ||||
| export CONFIG | ||||
| . $CONFIG | ||||
|  | ||||
| DEVNAME="$DEVICE" | ||||
| PPPOE_PIDFILE="$PIDFILE.pppoe" | ||||
| PPPD_PIDFILE="$PIDFILE.pppd" | ||||
|  | ||||
| if [ "$CONFIG" != "/etc/ppp/pppoe.conf" ] ; then | ||||
|    DEVNAME=`basename $CONFIG | sed 's/^ifcfg-//g'` | ||||
| fi | ||||
|  | ||||
| if [ -n "$BR2684DEV" ]; then | ||||
| 	[ -z "$ETH" ] && ETH="nas$BR2684DEV" | ||||
| 	modprobe br2684 > /dev/null 2>&1 | ||||
| fi | ||||
|  | ||||
| # Check for command-line overriding of ETH and USER | ||||
| case "$#" in | ||||
|     2|3) | ||||
| 	ETH="$1" | ||||
| 	USER="$2" | ||||
| 	;; | ||||
| esac | ||||
|  | ||||
| # Check that config file is sane | ||||
| if test "$USER" = "" ; then | ||||
|     echo "$0: Check '$CONFIG' -- no setting for USER" >& 2 | ||||
|     exit 1 | ||||
| fi | ||||
| if test "`basename \"$LINUX_PLUGIN\"`" = "pppoatm.so" ; then | ||||
|     if test "$VCI" = "" ; then | ||||
| 	echo "$0: Check '$CONFIG' -- no setting for VCI" >& 2 | ||||
| 	exit 1 | ||||
|     fi | ||||
|     if test "$VPI" = "" ; then | ||||
| 	echo "$0: Check '$CONFIG' -- no setting for VPI" >& 2 | ||||
| 	exit 1 | ||||
|     fi | ||||
| else | ||||
|     if test "$ETH" = "" ; then | ||||
| 	echo "$0: Check '$CONFIG' -- no setting for ETH" >& 2 | ||||
| 	exit 1 | ||||
|     fi | ||||
| fi | ||||
|  | ||||
| PPPD_PID=0 | ||||
|  | ||||
| # Catch common error | ||||
| if test "$DEBUG" = "1" ; then | ||||
|     echo "*** If you want to use DEBUG, invoke pppoe-start, not pppoe-connect." | ||||
|     exit 1 | ||||
| fi | ||||
|  | ||||
| if test "$DEBUG" != "" ; then | ||||
|     if test "$LINUX_PLUGIN" != "" ; then | ||||
| 	echo "Cannot use DEBUG mode and LINUX_PLUGIN at the same time." | ||||
| 	echo "Kernel-mode PPPoE is experimental and unsupported." | ||||
| 	exit 1 | ||||
|     fi | ||||
|     echo "* The following section identifies your Ethernet interface" >> $DEBUG | ||||
|     echo "* and user name.  Some ISP's need 'username'; others" >> $DEBUG | ||||
|     echo "* need 'username@isp.com'.  Try both" >> $DEBUG | ||||
|     echo "ETH=$ETH; USER=$USER" >> $DEBUG | ||||
|     echo "---------------------------------------------" >> $DEBUG | ||||
| fi | ||||
|  | ||||
| # MTU of Ethernet card attached to modem MUST be 1500.  This apparently | ||||
| # fails on some *BSD's, so we'll only do it under Linux | ||||
|  | ||||
| if test `uname -s` = Linux ; then | ||||
|     $IP link set $ETH up mtu 1500  | ||||
|     # For 2.4 kernels.  Will fail on 2.2.x, but who cares? | ||||
|     modprobe ppp_generic > /dev/null 2>&1 | ||||
|     modprobe ppp_async > /dev/null 2>&1 | ||||
|     modprobe ppp_synctty > /dev/null 2>&1 | ||||
|     if test -n "$LINUX_PLUGIN" ; then | ||||
| 	modprobe pppox > /dev/null 2>&1 | ||||
| 	modprobe pppoe > /dev/null 2>&1 | ||||
|     fi | ||||
| fi | ||||
|  | ||||
| if test "$SYNCHRONOUS" = "yes" ; then | ||||
| 	PPPOE_SYNC=-s | ||||
| 	PPPD_SYNC=sync | ||||
| 	# Increase the chances of it working on Linux... | ||||
| 	if test `uname -s` = Linux ; then | ||||
| 	    modprobe n_hdlc > /dev/null 2>&1 | ||||
| 	fi | ||||
| else | ||||
| 	PPPOE_SYNC="" | ||||
| 	PPPD_SYNC="" | ||||
| fi | ||||
|  | ||||
| if test -n "$ACNAME" ; then | ||||
|     ACNAME="-C $ACNAME" | ||||
| fi | ||||
|  | ||||
| if test -n "$SERVICENAME" ; then | ||||
|     SERVICENAMEOPT="-S $SERVICENAME" | ||||
| else | ||||
|     SERVICENAMEOPT="" | ||||
| fi | ||||
|  | ||||
| if test "$CLAMPMSS" = "no" ; then | ||||
| 	CLAMPMSS="" | ||||
| else | ||||
| 	CLAMPMSS="-m $CLAMPMSS" | ||||
| fi | ||||
|  | ||||
| # If DNSTYPE is SERVER, we must use "usepeerdns" option to pppd. | ||||
| if test "$DNSTYPE" = "SERVER" ; then | ||||
| 	PEERDNS=yes | ||||
|    USEPEERDNS=yes | ||||
| fi | ||||
|  | ||||
| if test "$PEERDNS" = "yes" ; then | ||||
| 	PEERDNS="usepeerdns" | ||||
| else | ||||
| 	PEERDNS="" | ||||
| fi | ||||
|  | ||||
| # Backward config file compatibility -- PEERDNS used to be USEPEERDNS | ||||
| if test "$USEPEERDNS" = "yes" ; then | ||||
|     PEERDNS="usepeerdns" | ||||
| fi | ||||
| if test "$USEPEERDNS" = "no" ; then | ||||
|     PEERDNS="" | ||||
| fi | ||||
|  | ||||
| if [ -z "$DEVICE" ] ; then | ||||
|     IPPARAM="" | ||||
|     LINKNAME="" | ||||
| else | ||||
|     IPPARAM="ipparam ${DEVNAME}" | ||||
|     LINKNAME="linkname ${DEVICE}" | ||||
| fi | ||||
|  | ||||
| [ -z "$MTU" ] && MTU="1492" | ||||
| [ -z "$MRU" ] && MRU="1492" | ||||
|  | ||||
| # Backward config file compatibility | ||||
| if test "$DEMAND" = "" ; then | ||||
| 	DEMAND=no | ||||
| fi | ||||
|  | ||||
| if test "$DEMAND" = "no" ; then | ||||
| 	DEMAND="" | ||||
| else | ||||
| 	[ -z "$IPADDR" ] && IPADDR=10.112.112.112 | ||||
| 	[ -z "$REMIP" ]  && REMIP=10.112.112.113 | ||||
|  | ||||
| 	DEMAND="demand persist idle $CONNECT_TIMEOUT $IPADDR:$REMIP ipcp-accept-remote ipcp-accept-local noipdefault ktune" | ||||
| 	# The plugin doesn't need (and may not _accept_) the 'connect' option | ||||
| 	if [ -z "$LINUX_PLUGIN" ]; then | ||||
| 		DEMAND="$DEMAND connect true" | ||||
| 	fi | ||||
| fi | ||||
|  | ||||
| case "$FIREWALL" in | ||||
|     STANDALONE) | ||||
| 	. /etc/ppp/firewall-standalone | ||||
| 	;; | ||||
|     MASQUERADE) | ||||
| 	. /etc/ppp/firewall-masq | ||||
| 	;; | ||||
| esac | ||||
|  | ||||
| # If we're using kernel-mode PPPoE on Linux... | ||||
| if test "`basename \"$LINUX_PLUGIN\"`" = "rp-pppoe.so" ; then | ||||
|     PLUGIN_OPTS="plugin $LINUX_PLUGIN nic-$ETH" | ||||
|     if test -n "$SERVICENAME" ; then | ||||
|        PLUGIN_OPTS="$PLUGIN_OPTS rp_pppoe_service $SERVICENAME" | ||||
|     fi | ||||
|     modprobe pppoe > /dev/null 2>&1 | ||||
| fi | ||||
| # If we're using kernel-mode PPPoATM on Linux... | ||||
| if test "`basename \"$LINUX_PLUGIN\"`" = "pppoatm.so" ; then | ||||
|     PLUGIN_OPTS="plugin $LINUX_PLUGIN" | ||||
|  | ||||
|     # Interface name MUST BE LAST!! | ||||
|     PLUGIN_OPTS="$PLUGIN_OPTS $VPI.$VCI" | ||||
|     modprobe pppoatm > /dev/null 2>&1 | ||||
| fi | ||||
| if test "$DEFROUTE" != "no" ; then | ||||
|     DEFAULTROUTE="defaultroute" | ||||
|     # pppd will no longer delete an existing default route | ||||
|     # so we have to help it out a little here. | ||||
|     DEFRT=$(ip route list match 0/0) | ||||
|     [ -n "${DEFRT}" ] && echo "$DEFRT" > /etc/default-routes | ||||
|     echo "$DEFRT" | while read spec; do | ||||
|         ip route del $spec; | ||||
|     done | ||||
| else | ||||
|     DEFAULTROUTE="" | ||||
| fi | ||||
|  | ||||
| # Standard PPP options we always use | ||||
| PPP_STD_OPTIONS="$IPPARAM $LINKNAME $PLUGIN_OPTS noipdefault noauth default-asyncmap $DEFAULTROUTE hide-password nodetach $PEERDNS mtu $MTU mru $MRU noaccomp nodeflate nopcomp novj novjccomp user $USER lcp-echo-interval $LCP_INTERVAL lcp-echo-failure $LCP_FAILURE $PPPD_EXTRA" | ||||
|  | ||||
| # PPPoE invocation | ||||
| PPPOE_CMD="$PPPOE -p $PPPOE_PIDFILE -I $ETH -T $PPPOE_TIMEOUT -U $PPPOE_SYNC $CLAMPMSS $ACNAME $SERVICENAMEOPT $PPPOE_EXTRA" | ||||
| if test "$DEBUG" != "" ; then | ||||
|     if test "$DEMAND" != "" ; then | ||||
| 	echo "(Turning off DEMAND for debugging purposes)" | ||||
| 	DEMAND="" | ||||
|     fi | ||||
|     echo "* The following section shows the pppd command we will invoke" >> $DEBUG | ||||
|     echo "pppd invocation" >> $DEBUG | ||||
|     echo "$SETSID $PPPD pty '$PPPOE_CMD' $PPP_STD_OPTIONS $PPPD_SYNC debug" >> $DEBUG | ||||
|     echo "---------------------------------------------" >> $DEBUG | ||||
|     $SETSID $PPPD pty "$PPPOE_CMD -D $DEBUG-0" \ | ||||
| 	$PPP_STD_OPTIONS \ | ||||
| 	$PPPD_SYNC \ | ||||
| 	debug >> $DEBUG 2>&1 | ||||
|     echo "---------------------------------------------" >> $DEBUG | ||||
|     echo "* The following section is an extract from your log." >> $DEBUG | ||||
|     echo "* Look for error messages from pppd, such as" >> $DEBUG | ||||
|     echo "* a lack of kernel support for PPP, authentication failure" >> $DEBUG | ||||
|     echo "* etc." >> $DEBUG | ||||
|     if test -f "/var/log/messages" ; then | ||||
| 	echo "Extract from /var/log/messages" >> $DEBUG | ||||
| 	grep 'ppp' /var/log/messages | tail -150 >> $DEBUG | ||||
|     elif test -f "/var/adm/messages"; then | ||||
| 	echo "Extract from /var/adm/messages" >> $DEBUG | ||||
| 	grep 'ppp' /var/adm/messages | tail -150 >> $DEBUG | ||||
|     else | ||||
|         echo "Can't find messages file (looked for /var/{log,adm}/messages" >> $DEBUG | ||||
|     fi | ||||
|     date >> $DEBUG | ||||
|     echo "---------------------------------------------" >> $DEBUG | ||||
|     echo "* The following section is a dump of the packets" >> $DEBUG | ||||
|     echo "* sent and received by rp-pppoe.  If you don't see" >> $DEBUG | ||||
|     echo "* any output, it's an Ethernet driver problem.  If you only" >> $DEBUG | ||||
|     echo "* see three PADI packets and nothing else, check your cables" >> $DEBUG | ||||
|     echo "* and modem.  Make sure the modem lights flash when you try" >> $DEBUG | ||||
|     echo "* to connect.  Check that your Ethernet card is in" >> $DEBUG | ||||
|     echo "* half-duplex, 10Mb/s mode.  If all else fails," >> $DEBUG | ||||
|     echo "* try using pppoe-sniff." >> $DEBUG | ||||
|     echo "rp-pppoe debugging dump" >> $DEBUG | ||||
|     cat $DEBUG-0 >> $DEBUG | ||||
|     rm -f $DEBUG-0 | ||||
|     for i in 1 2 3 4 5 6 7 8 9 10 ; do | ||||
|     echo "" | ||||
|     echo "" | ||||
|     echo "" | ||||
|     done | ||||
|     echo "*** Finished debugging run.  Please review the file" | ||||
|     echo "*** '$DEBUG' and try to" | ||||
|     echo "*** figure out what is going on." | ||||
|     echo "***" | ||||
|     echo "*** Unfortunately, we can NO LONGER accept debugging" | ||||
|     echo "*** output for analysis.  Please do not send this to" | ||||
|     echo "*** Roaring Penguin; it is too time-consuming for" | ||||
|     echo "*** us to deal with all the analyses we have been sent." | ||||
|     exit 0 | ||||
| fi | ||||
|  | ||||
| echo $$ > $PIDFILE | ||||
|  | ||||
| while [ true ] ; do | ||||
|     if [ "${DEFROUTE}" != "no" ] ; then | ||||
|         DEFRT=$(ip route list match 0/0) | ||||
|         [ -n "${DEFRT}" ] && echo "$DEFRT" > /etc/default-routes | ||||
|         echo "$DEFRT" | while read spec; do | ||||
|             ip route del $spec; | ||||
|         done | ||||
|     fi | ||||
|  | ||||
|     if test "$BR2684DEV" != ""; then | ||||
|         $BR2684CTL -b -c $BR2684DEV -a $VPI.$VCI | ||||
|         ip link set $ETH up | ||||
|     fi | ||||
|     if test "$OVERRIDE_PPPD_COMMAND" != "" ; then | ||||
|        $SETSID $OVERRIDE_PPPD_COMMAND & | ||||
|        echo "$!" > $PPPD_PIDFILE | ||||
|     elif test "$LINUX_PLUGIN" != "" ; then | ||||
|         $SETSID $PPPD $PPP_STD_OPTIONS $DEMAND & | ||||
|         echo "$!" > $PPPD_PIDFILE | ||||
|     else | ||||
|         $SETSID $PPPD pty "$PPPOE_CMD" \ | ||||
|         $PPP_STD_OPTIONS \ | ||||
|         $DEMAND \ | ||||
|         $PPPD_SYNC & | ||||
|         echo "$!" > $PPPD_PIDFILE | ||||
|     fi | ||||
|     wait | ||||
|     if test "$BR2684DEV" != ""; then | ||||
|         kill `cat /var/run/nas$BR2684DEV.pid` | ||||
|         rm /var/run/nas$BR2684DEV.pid | ||||
|     fi | ||||
|  | ||||
|     if test "$RETRY_ON_FAILURE" = "no" ; then | ||||
|        exit | ||||
|     fi | ||||
|  | ||||
|     # Run /etc/ppp/adsl-lost if it exists | ||||
|     test -x /etc/ppp/adsl-lost && /etc/ppp/adsl-lost | ||||
|  | ||||
|     # Re-establish the connection | ||||
|     $LOGGER -p daemon.notice "PPPoE connection lost; attempting re-connection." | ||||
|  | ||||
|     # Wait a bit in case a problem causes tons of log messages :-) | ||||
|     sleep 5 | ||||
| done | ||||
							
								
								
									
										9
									
								
								pppoe-server.service
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										9
									
								
								pppoe-server.service
									
									
									
									
									
										Normal file
									
								
							| @@ -0,0 +1,9 @@ | ||||
| [Unit] | ||||
| Description=PPPoE Server. | ||||
| After=syslog.target | ||||
|  | ||||
| [Service] | ||||
| ExecStart=/sbin/pppoe-server | ||||
|  | ||||
| [Install] | ||||
| WantedBy=multi-user.target | ||||
							
								
								
									
										492
									
								
								pppoe-setup
									
									
									
									
									
										Executable file
									
								
							
							
						
						
									
										492
									
								
								pppoe-setup
									
									
									
									
									
										Executable file
									
								
							| @@ -0,0 +1,492 @@ | ||||
| #! /bin/bash | ||||
| #*********************************************************************** | ||||
| # | ||||
| # pppoe-setup | ||||
| # | ||||
| # All-purpose slicing/dicing shell script to configure rp-pppoe. | ||||
| # | ||||
| # Copyright (C) 2000 Roaring Penguin Software Inc. | ||||
| # | ||||
| # $Id$ | ||||
| #*********************************************************************** | ||||
|  | ||||
| # Paths to programs and config files | ||||
| IP=/sbin/ip | ||||
| PPPD=/usr/sbin/pppd | ||||
| PPPOE=/sbin/pppoe | ||||
| ECHO=/bin/echo | ||||
| LS=/bin/ls | ||||
| ID=/usr/bin/id | ||||
| NETWORKDIR=/etc/sysconfig/network-scripts | ||||
| PAPFILE=/etc/ppp/chap-secrets | ||||
| CHAPFILE=/etc/ppp/pap-secrets | ||||
| RESOLVFILE=/etc/resolv.conf | ||||
|  | ||||
| # Set to "C" locale so we can parse messages from commands | ||||
| LANG=C | ||||
| export LANG | ||||
|  | ||||
| # Protect created files | ||||
| umask 077 | ||||
|  | ||||
| copy() { | ||||
|     cp $1 $2 | ||||
|     if [ "$?" != 0 ] ; then | ||||
| 	$ECHO "*** Error copying $1 to $2" | ||||
| 	$ECHO "*** Quitting." | ||||
| 	exit 1 | ||||
|     fi | ||||
| } | ||||
|  | ||||
| get_device() { | ||||
|     if [ ! -d $NETWORKDIR ] ; then | ||||
|         $ECHO "** $NETWORKDIR not found" | ||||
|         $ECHO "** Quitting" | ||||
|         exit 1 | ||||
|     fi | ||||
|  | ||||
|     cd $NETWORKDIR | ||||
|     interfaces=$($LS ifcfg-ppp* 2>/dev/null | egrep -v '(~|\.bak)$' | \ | ||||
|                  egrep -v '(rpmsave|rpmorig|rpmnew)' | sed 's/^ifcfg-//g') | ||||
|  | ||||
|     for i in $interfaces ; do | ||||
|         test -f ifcfg-$i && . ifcfg-$i 2>/dev/null | ||||
|         if [ "$TYPE" = "xDSL" ] ; then | ||||
|             device_count=$[$device_count+1] | ||||
|             devices="$devices $DEVICE" | ||||
|         fi | ||||
|     done | ||||
| } | ||||
|  | ||||
| clear_env() { | ||||
|     unset USERCTL BOOTPROTO NAME DEVICE TYPE ONBOOT FIREWALL PING \ | ||||
|           PPPOE_TIMEOUT LCP_FAILURE LCP_INTERVAL CLAMPMSS CONNECT_POLL \ | ||||
| 	  CONNECT_TIMEOUT DEFROUTE SYNCHRONOUS ETH PROVIDER USER PEERDNS \ | ||||
| 	  DNS1 DNS2 | ||||
| } | ||||
|  | ||||
|  | ||||
| clear | ||||
|  | ||||
| $ECHO "Welcome to the PPPoE client setup.  First, I will run some checks on" | ||||
| $ECHO "your system to make sure the PPPoE client is installed properly..." | ||||
| $ECHO "" | ||||
|  | ||||
| # Must be root | ||||
| if [ "`$ID -u`" != 0 ] ; then | ||||
|     $ECHO "$0: Sorry, you must be root to run this script" | ||||
|     exit 1 | ||||
| fi | ||||
|  | ||||
| # Must have pppd | ||||
| if [ ! -x $PPPD ] ; then | ||||
|     $ECHO "Oops, I can't execute the program '$PPPD'.  You" | ||||
|     $ECHO "must install the PPP software suite, version 2.3.10 or later." | ||||
|     exit 1 | ||||
| fi | ||||
|  | ||||
| # get the DSL config files in /etc/sysconfig/network-scripts | ||||
| devices="" | ||||
| device_count=0 | ||||
| get_device | ||||
|  | ||||
| if [ $device_count -gt 0 ] ; then | ||||
|     $ECHO "The following DSL config was found on your system:" | ||||
|     $ECHO "" | ||||
|     $ECHO "  Device:      Name:" | ||||
|  | ||||
|     for i in $devices ; do | ||||
| 	. $NETWORKDIR/ifcfg-$i | ||||
| 	$ECHO "  $i         $NAME" | ||||
|     done | ||||
|  | ||||
|     $ECHO "" | ||||
|  | ||||
|     for i in $devices ; do | ||||
| 	default_device=$i | ||||
| 	break | ||||
|     done | ||||
|  | ||||
|     clear_env | ||||
|  | ||||
|     while [ true ] ; do | ||||
| 	$ECHO "Please enter the device if you want to configure the present DSL config" | ||||
| 	$ECHO -n "(default $default_device) or enter 'n' if you want to create a new one: " | ||||
|  | ||||
| 	read dev | ||||
|  | ||||
| 	if [ "$dev" = "n" ] ; then | ||||
| 	    i=0 | ||||
| 	    while true; do | ||||
| 		found=0 | ||||
| 		for j in $interfaces ; do | ||||
| 		    if [ "$j" = "ppp$i" ] ; then | ||||
| 			found=1 | ||||
| 			break | ||||
| 		    fi | ||||
| 		done | ||||
| 		if [ $found -eq 0 ] ; then | ||||
| 		    dsl_device="ppp$i" | ||||
| 		    break | ||||
| 		fi | ||||
| 		i=$[$i+1] | ||||
| 	    done | ||||
|             if [ -z "$dsl_device" ]; then | ||||
|                 dev=0 | ||||
|                 while [ -e $NETWORKDIR/ifcfg-ppp$dev ]; do | ||||
|                     dev=`expr $dev + 1` | ||||
|                 done | ||||
|                 dsl_device="ppp$dev" | ||||
|             fi | ||||
| 	    break | ||||
| 	else | ||||
| 	    if [ -n "$default_device" ] ; then | ||||
| 		if [ -n "$dev" ] ; then | ||||
| 		    dsl_device="$dev" | ||||
| 		else | ||||
| 		    dsl_device="$default_device" | ||||
| 		fi | ||||
| 	    fi | ||||
| 	    for i in $devices ; do | ||||
| 		[ "$dsl_device" = "$i" ] && break | ||||
| 	    done | ||||
| 	    if [ "$dsl_device" = "$i" ] ; then | ||||
| 		break | ||||
| 	    fi | ||||
| 	    $ECHO "Device '$dsl_device' is not found in the list, please choose the correct one" | ||||
| 	fi | ||||
|     done | ||||
| else | ||||
|     dev=0 | ||||
|     while [ -e $NETWORKDIR/ifcfg-ppp$dev ]; do | ||||
|         dev=`expr $dev + 1` | ||||
|     done | ||||
|     dsl_device="ppp$dev" | ||||
| fi | ||||
|  | ||||
| CONFIG="$NETWORKDIR/ifcfg-$dsl_device" | ||||
| DEVICE=$dsl_device | ||||
| export CONFIG | ||||
|  | ||||
| [ "$dev" = "n" ] || . $CONFIG 2>/dev/null | ||||
| [ "$DEMAND" = "" ] &&  DEMAND=no | ||||
|  | ||||
| while [ true ] ; do | ||||
|     $ECHO "" | ||||
|     $ECHO "LOGIN NAME" | ||||
|     $ECHO "" | ||||
|     if [ -z "$USER" ] ; then | ||||
| 	$ECHO -n "Enter your Login Name: " | ||||
|     else | ||||
| 	$ECHO -n "Enter your Login Name (default $USER): " | ||||
|     fi | ||||
|  | ||||
|     read U | ||||
|  | ||||
|     if [ -z "$U" ] ; then | ||||
| 	if [ -z "$USER" ] ; then | ||||
| 	    continue | ||||
| 	fi | ||||
|     else | ||||
| 	USER="$U" | ||||
|     fi | ||||
|  | ||||
|  | ||||
|     # Under Linux, "fix" the default interface if eth1 is not available | ||||
|     [ -n "$ETH" ] || ETH=eth0 | ||||
|     if test `uname -s` = "Linux" ; then | ||||
|        $IP link show $ETH > /dev/null 2>&1 || ETH=eth0 | ||||
|     fi | ||||
|     $ECHO "" | ||||
|     $ECHO "INTERFACE" | ||||
|     $ECHO "" | ||||
|     $ECHO "Enter the Ethernet interface connected to the PPPoE modem" | ||||
|     $ECHO "For Solaris, this is likely to be something like /dev/hme0." | ||||
|     $ECHO "For Linux, it will be ethX, where 'X' is a number." | ||||
|     $ECHO -n "(default $ETH): " | ||||
|     read E | ||||
|  | ||||
|     if [ -n "$E" ] ; then | ||||
| 	ETH="$E" | ||||
|     fi | ||||
|  | ||||
|     $ECHO "" | ||||
|     $ECHO "Do you want the link to come up on demand, or stay up continuously?" | ||||
|     $ECHO "If you want it to come up on demand, enter the idle time in seconds" | ||||
|     $ECHO "after which the link should be dropped.  If you want the link to" | ||||
|     $ECHO "stay up permanently, enter 'no' (two letters, lower-case.)" | ||||
|     $ECHO "NOTE: Demand-activated links do not interact well with dynamic IP" | ||||
|     $ECHO "addresses.  You may have some problems with demand-activated links." | ||||
|     $ECHO -n "Enter the demand value (default $DEMAND): " | ||||
|     read D | ||||
|     if [ -n "$D" ] ; then | ||||
| 	DEMAND="$D" | ||||
|     fi | ||||
|  | ||||
|     $ECHO "" | ||||
|     $ECHO "DNS" | ||||
|     $ECHO "" | ||||
|     $ECHO "Please enter the IP address of your ISP's primary DNS server." | ||||
|     $ECHO "If your ISP claims that 'the server will provide dynamic DNS addresses'," | ||||
|     $ECHO "enter 'server' (all lower-case) here." | ||||
|     $ECHO "If you just press enter, I will assume you know what you are" | ||||
|     $ECHO "doing and not modify your DNS setup." | ||||
|     $ECHO -n "Enter the DNS information here: " | ||||
|  | ||||
|     read DNS1 | ||||
|  | ||||
|  | ||||
|     if [ -n "$DNS1" ] ; then | ||||
|         if [ "$DNS1" != "server" ] ; then | ||||
| 	    $ECHO "Please enter the IP address of your ISP's secondary DNS server." | ||||
| 	    $ECHO "If you just press enter, I will assume there is only one DNS server." | ||||
| 	    $ECHO -n "Enter the secondary DNS server address here: " | ||||
| 	    read DNS2 | ||||
| 	fi | ||||
|     fi | ||||
|  | ||||
|     while [ true ] ; do | ||||
| 	$ECHO "" | ||||
| 	$ECHO "PASSWORD" | ||||
| 	$ECHO "" | ||||
| 	stty -echo | ||||
| 	$ECHO -n "Please enter your Password: " | ||||
| 	read PWD1 | ||||
| 	$ECHO "" | ||||
| 	$ECHO -n "Please re-enter your Password: " | ||||
| 	read PWD2 | ||||
| 	$ECHO "" | ||||
| 	stty echo | ||||
| 	if [ "$PWD1" = "$PWD2" ] ; then | ||||
| 	    break | ||||
| 	fi | ||||
|  | ||||
| 	$ECHO -n "Sorry, the passwords do not match.  Try again? (y/n)" | ||||
| 	read ANS | ||||
| 	case "$ANS" in | ||||
| 	    N|No|NO|Non|n|no|non) | ||||
| 		$ECHO "OK, quitting.  Bye." | ||||
| 		exit 1 | ||||
| 	esac | ||||
|     done | ||||
|  | ||||
|     # Usercontrol | ||||
|     $ECHO "" | ||||
|     $ECHO "USERCTRL" | ||||
|     $ECHO | ||||
|     $ECHO "Please enter 'yes' (three letters, lower-case.) if you want to allow" | ||||
|     $ECHO -n "normal user to start or stop DSL connection (default yes): " | ||||
|  | ||||
|     read USERCTL | ||||
|  | ||||
|     if [ -z "$USERCTL" ] ; then | ||||
| 	USERCTL="yes" | ||||
|     fi | ||||
|  | ||||
|     # Firewalling | ||||
|     $ECHO "" | ||||
|     $ECHO "FIREWALLING" | ||||
|     $ECHO "" | ||||
|     if test `uname -s` != "Linux" ; then | ||||
| 	$ECHO "Sorry, firewalling is only supported under Linux.  Consult" | ||||
| 	$ECHO "your operating system manuals for details on setting up" | ||||
| 	$ECHO "packet filters for your system." | ||||
| 	FIREWALL=NONE | ||||
|     else | ||||
| 	$ECHO "Please choose the firewall rules to use.  Note that these rules are" | ||||
| 	$ECHO "very basic.  You are strongly encouraged to use a more sophisticated" | ||||
| 	$ECHO "firewall setup; however, these will provide basic security.  If you" | ||||
| 	$ECHO "are running any servers on your machine, you must choose 'NONE' and" | ||||
| 	$ECHO "set up firewalling yourself.  Otherwise, the firewall rules will deny" | ||||
| 	$ECHO "access to all standard servers like Web, e-mail, ftp, etc.  If you" | ||||
| 	$ECHO "are using SSH, the rules will block outgoing SSH connections which" | ||||
| 	$ECHO "allocate a privileged source port." | ||||
| 	$ECHO "" | ||||
| 	while [ true ] ; do | ||||
| 	    $ECHO "The firewall choices are:" | ||||
| 	    $ECHO "0 - NONE: This script will not set any firewall rules.  You are responsible" | ||||
| 	    $ECHO "          for ensuring the security of your machine.  You are STRONGLY" | ||||
| 	    $ECHO "          recommended to use some kind of firewall rules." | ||||
| 	    $ECHO "1 - STANDALONE: Appropriate for a basic stand-alone web-surfing workstation" | ||||
| 	    $ECHO "2 - MASQUERADE: Appropriate for a machine acting as an Internet gateway" | ||||
| 	    $ECHO "                for a LAN" | ||||
| 	    $ECHO -n "Choose a type of firewall (0-2): " | ||||
| 	    read a | ||||
| 	    if [ "$a" = 0 -o "$a" = 1 -o "$a" = 2 ] ; then | ||||
| 		break | ||||
| 	    fi | ||||
| 	    $ECHO "Please enter a number from 0 to 2" | ||||
| 	done | ||||
|  | ||||
| 	case "$a" in | ||||
| 	    0) | ||||
| 		FIREWALL=NONE | ||||
| 		;; | ||||
| 	    1) | ||||
| 		FIREWALL=STANDALONE | ||||
| 		;; | ||||
| 	    2) | ||||
| 		FIREWALL=MASQUERADE | ||||
| 		;; | ||||
| 	esac | ||||
|     fi | ||||
|  | ||||
|     $ECHO "" | ||||
|     $ECHO "Start this connection at boot time" | ||||
|     $ECHO "" | ||||
|     $ECHO "Do you want to start this connection at boot time?" | ||||
|     $ECHO -n "Please enter no or yes (default no):" | ||||
|     read boot | ||||
|     case "$boot" in | ||||
|       yes|YES) ONBOOT="yes";; | ||||
|       *) ONBOOT="no";; | ||||
|     esac | ||||
|  | ||||
|     $ECHO "" | ||||
|     $ECHO "** Summary of what you entered **" | ||||
|     $ECHO "" | ||||
|     $ECHO "Ethernet Interface: $ETH" | ||||
|     $ECHO "User name:          $USER" | ||||
|     if [ "$DEMAND" = "no" ] ; then | ||||
| 	$ECHO "Activate-on-demand: No" | ||||
|     else | ||||
| 	$ECHO "Activate-on-demand: Yes; idle timeout = $DEMAND seconds" | ||||
|     fi | ||||
|  | ||||
|     if [ -n "$DNS1" ] ; then | ||||
|         if [ "$DNS1" = "server" ] ; then | ||||
| 	    $ECHO "DNS addresses:      Supplied by ISP's server" | ||||
|         else | ||||
| 	    $ECHO "Primary DNS:        $DNS1" | ||||
| 	    if [ -n "$DNS2" ] ; then | ||||
| 		$ECHO "Secondary DNS:      $DNS2" | ||||
| 	    fi | ||||
|         fi | ||||
|     else | ||||
| 	$ECHO "DNS:                Do not adjust" | ||||
|     fi | ||||
|     $ECHO "Firewalling:        $FIREWALL" | ||||
|     $ECHO "User Control:       $USERCTL" | ||||
|     while [ true ] ; do | ||||
|         $ECHO -n 'Accept these settings and adjust configuration files (y/n)? ' | ||||
|         read ANS | ||||
| 	case "ANS" in | ||||
| 	    Y|y|yes|Yes|oui|Oui) | ||||
| 		ANS=y | ||||
| 		;; | ||||
|             N|n|no|No|non|Non) | ||||
| 		ANS=n | ||||
| 		;; | ||||
| 	esac | ||||
| 	if [ "$ANS" = "y" -o "$ANS" = "n" ] ; then | ||||
| 	    break | ||||
|         fi | ||||
|     done | ||||
|     if [ "$ANS" = "y" ] ; then | ||||
| 	break | ||||
|     fi | ||||
| done | ||||
|  | ||||
| # Adjust configuration files.  First to $CONFIG | ||||
|  | ||||
| $ECHO "Adjusting $CONFIG" | ||||
|  | ||||
| test -f $CONFIG && copy $CONFIG $CONFIG.bak | ||||
| if [ "$DNS1" = "server" ] ; then | ||||
|     DNS1="" | ||||
|     DNS2="" | ||||
|     PEERDNS=yes | ||||
| else | ||||
|     PEERDNS=no | ||||
| fi | ||||
|  | ||||
| # Where is pppd likely to put its pid? | ||||
| if [ -d /var/run ] ; then | ||||
|     VARRUN=/var/run | ||||
| else | ||||
|     VARRUN=/etc/ppp | ||||
| fi | ||||
|  | ||||
| $ECHO "USERCTL=$USERCTL" >$CONFIG | ||||
| $ECHO "BOOTPROTO=dialup" >>$CONFIG | ||||
| [ -z "$NAME" ] && NAME="DSL$DEVICE" | ||||
| $ECHO "NAME=DSL$DEVICE" >>$CONFIG | ||||
| $ECHO "DEVICE=$DEVICE" >>$CONFIG | ||||
| $ECHO "TYPE=xDSL" >>$CONFIG | ||||
| $ECHO "ONBOOT=$ONBOOT" >>$CONFIG | ||||
| $ECHO "PIDFILE=/var/run/pppoe-adsl.pid" >>$CONFIG | ||||
| $ECHO "FIREWALL=$FIREWALL" >>$CONFIG | ||||
| [ -z "$PING" ] && PING="." | ||||
| $ECHO "PING=$PING" >>$CONFIG | ||||
| [ -z "$PPPOE_TIMEOUT" ] && PPPOE_TIMEOUT=80 | ||||
| $ECHO "PPPOE_TIMEOUT=$PPPOE_TIMEOUT" >>$CONFIG | ||||
| [ -z "$LCP_FAILURE" ] && LCP_FAILURE=3 | ||||
| $ECHO "LCP_FAILURE=$LCP_FAILURE" >>$CONFIG | ||||
| [ -z "$LCP_INTERVAL" ] && LCP_INTERVAL=20 | ||||
| $ECHO "LCP_INTERVAL=$LCP_INTERVAL" >>$CONFIG | ||||
| [ -z "$CLAMPMSS" ] && CLAMPMSS=1412 | ||||
| $ECHO "CLAMPMSS=$CLAMPMSS" >>$CONFIG | ||||
| [ -z "$CONNECT_POLL" ] && CONNECT_POLL=6 | ||||
| $ECHO "CONNECT_POLL=$CONNECT_POLL" >>$CONFIG | ||||
| [ -z "$CONNECT_TIMEOUT" ] && CONNECT_TIMEOUT=60 | ||||
| $ECHO "CONNECT_TIMEOUT=$CONNECT_TIMEOUT" >>$CONFIG | ||||
| [ -z "$DEFROUTE" ] && DEFROUTE=yes | ||||
| $ECHO "DEFROUTE=$DEFROUTE" >>$CONFIG | ||||
| [ -z "$SYNCHRONOUS" ] && SYNCHRONOUS=no | ||||
| $ECHO "SYNCHRONOUS=$SYNCHRONOUS" >>$CONFIG | ||||
| $ECHO "ETH=$ETH" >> $CONFIG | ||||
| [ -z "$PROVIDER" ] && PROVIDER="$NAME" | ||||
| $ECHO "PROVIDER=$PROVIDER" >>$CONFIG | ||||
| $ECHO "USER=$USER" >>$CONFIG | ||||
| $ECHO "PEERDNS=$PEERDNS" >>$CONFIG | ||||
| $ECHO "DEMAND=$DEMAND" >>$CONFIG | ||||
|  | ||||
| if [ -n "$DNS1" ] ; then | ||||
|     if [ "$DNS1" != "server" ] ; then | ||||
| 	$ECHO "Adjusting $RESOLVFILE" | ||||
| 	if [ -r $RESOLVFILE ] ; then | ||||
| 	    grep -s "MADE-BY-RP-PPPOE" $RESOLVFILE > /dev/null 2>&1 | ||||
| 	    if [ "$?" != 0 ] ; then | ||||
| 		$ECHO "  (But first backing it up to $RESOLVFILE.bak)" | ||||
| 		test -f $$RESOLVFILE && copy $RESOLVFILE $RESOLVFILE.bak | ||||
| 	    fi | ||||
| 	fi | ||||
| 	$ECHO "# MADE-BY-RP-PPPOE" > $RESOLVFILE | ||||
| 	$ECHO "nameserver $DNS1" >> $RESOLVFILE | ||||
| 	if [ -n "$DNS2" ] ; then | ||||
| 	    $ECHO "nameserver $DNS2" >> $RESOLVFILE | ||||
| 	fi | ||||
|     fi | ||||
| fi | ||||
|  | ||||
| $ECHO "Adjusting $PAPFILE and $CHAPFILE" | ||||
| if [ -r $PAPFILE ] ; then | ||||
|     $ECHO "  (But first backing it up to $PAPFILE.bak)" | ||||
|     test -f $PAPFILE && copy $PAPFILE $PAPFILE.bak | ||||
| else | ||||
|     cp /dev/null $PAPFILE.bak | ||||
| fi | ||||
| if [ -r $CHAPFILE ] ; then | ||||
|     $ECHO "  (But first backing it up to $CHAPFILE.bak)" | ||||
|     test -f $CHAPFILE && copy $CHAPFILE $CHAPFILE.bak | ||||
| else | ||||
|     cp /dev/null $CHAPFILE.bak | ||||
| fi | ||||
|  | ||||
| egrep -v "^$USER|^\"$USER\"" $PAPFILE.bak > $PAPFILE | ||||
| $ECHO "\"$USER\"	*	\"$PWD1\"" >> $PAPFILE | ||||
| egrep -v "^$USER|^\"$USER\"" $CHAPFILE.bak > $CHAPFILE | ||||
| $ECHO "\"$USER\"	*	\"$PWD1\"" >> $CHAPFILE | ||||
|  | ||||
| $ECHO "" | ||||
| $ECHO "" | ||||
| $ECHO "" | ||||
| $ECHO "Congratulations, it should be all set up!" | ||||
| $ECHO "" | ||||
| $ECHO "Type '/sbin/ifup $dsl_device' to bring up your xDSL link and '/sbin/ifdown $dsl_device'" | ||||
| $ECHO "to bring it down." | ||||
| $ECHO "Type '/sbin/pppoe-status $NETWORKDIR/ifcfg-$dsl_device'" | ||||
| $ECHO "to see the link status." | ||||
| $ECHO "" | ||||
|  | ||||
| exit 0 | ||||
							
								
								
									
										228
									
								
								pppoe-start
									
									
									
									
									
										Executable file
									
								
							
							
						
						
									
										228
									
								
								pppoe-start
									
									
									
									
									
										Executable file
									
								
							| @@ -0,0 +1,228 @@ | ||||
| #! /bin/bash | ||||
| # Generated automatically from pppoe-start.in by configure. | ||||
| #*********************************************************************** | ||||
| # | ||||
| # pppoe-start | ||||
| # | ||||
| # Shell script to bring up an PPPoE connection | ||||
| # | ||||
| # Copyright (C) 2000 Roaring Penguin Software Inc. | ||||
| # | ||||
| # $Id$ | ||||
| # | ||||
| # This file may be distributed under the terms of the GNU General | ||||
| # Public License. | ||||
| # | ||||
| # Usage: pppoe-start [config_file] | ||||
| #        pppoe-start interface user [config_file] | ||||
| # Second form overrides USER and ETH from config file. | ||||
| # If config_file is omitted, defaults to /etc/ppp/pppoe.conf | ||||
| # | ||||
| #*********************************************************************** | ||||
|  | ||||
| # From AUTOCONF | ||||
| prefix=/usr | ||||
| exec_prefix=/usr | ||||
|  | ||||
| # Paths to programs | ||||
| CONNECT=/sbin/pppoe-connect | ||||
| ECHO=/bin/echo | ||||
| IP=/sbin/ip | ||||
| LS=/bin/ls | ||||
| NETWORKDIR=/etc/sysconfig/network-scripts | ||||
|  | ||||
| get_device() { | ||||
|     if [ ! -d $NETWORKDIR ] ; then | ||||
|         $ECHO "** $NETWORKDIR not found" | ||||
|         $ECHO "** Quitting" | ||||
|         exit 1 | ||||
|     fi | ||||
|  | ||||
|     cd $NETWORKDIR | ||||
|     interfaces=$($LS ifcfg-ppp* 2>/dev/null | egrep -v '(~|\.bak)$' | \ | ||||
|                  egrep -v '(rpmsave|rpmorig|rpmnew)' | sed 's/^ifcfg-//g') | ||||
|  | ||||
|     for i in $interfaces ; do | ||||
|         test -f ifcfg-$i && . ifcfg-$i 2>/dev/null | ||||
|         if [ "$TYPE" = "xDSL" ] ; then | ||||
|             CONFIG=$NETWORKDIR/ifcfg-$i | ||||
|             break | ||||
|         fi | ||||
|     done | ||||
| } | ||||
|  | ||||
| # Set to "C" locale so we can parse messages from commands | ||||
| LANG=C | ||||
| export LANG | ||||
|  | ||||
| # Defaults | ||||
| USER="" | ||||
| ETH="" | ||||
| ME=`basename $0` | ||||
|  | ||||
| # Must be root | ||||
| if [ "`/usr/bin/id -u`" != 0 ] ; then | ||||
|     [ "$DEBUG" = "1" ] && $ECHO "$ME: You must be root to run this script" >& 2 | ||||
|     exit 1 | ||||
| fi | ||||
|  | ||||
| # Debugging | ||||
| if [ "$DEBUG" = "1" ] ; then | ||||
|     $ECHO "*** Running in debug mode... please be patient..." | ||||
|     DEBUG=`mktemp -d /tmp/pppoe-debug-XXXXXXXX` | ||||
|     if [ $? -ne 0 ] ; then | ||||
| 	$ECHO "Could not create directory $DEBUG... exiting" | ||||
| 	exit 1 | ||||
|     fi | ||||
|     export DEBUG | ||||
|     DEBUG=$DEBUG/pppoe-debug.txt | ||||
|  | ||||
|     # Initial debug output | ||||
|     $ECHO "---------------------------------------------" > $DEBUG | ||||
|     $ECHO "* The following section contains information about your system" >> $DEBUG | ||||
|     date >> $DEBUG | ||||
|     $ECHO "Output of uname -a" >> $DEBUG | ||||
|     uname -a >> $DEBUG | ||||
|     $ECHO "---------------------------------------------" >> $DEBUG | ||||
|     $ECHO "* The following section contains information about your network" >> $DEBUG | ||||
|     $ECHO "* interfaces.  The one you chose for PPPoE should contain the words:" >> $DEBUG | ||||
|     $ECHO "* 'UP' and 'RUNNING'.  If it does not, you probably have an Ethernet" >> $DEBUG | ||||
|     $ECHO "* driver problem." >> $DEBUG | ||||
|     $ECHO "Output of ip addr show" >> $DEBUG | ||||
|     $IP addr show >> $DEBUG | ||||
|     $ECHO "---------------------------------------------" >> $DEBUG | ||||
|     if [ "`uname -s`" = "Linux" ] ; then | ||||
|         $ECHO "* The following section contains information about kernel modules" >> $DEBUG | ||||
| 	$ECHO "* If the module for your Ethernet card is 'tulip', you might" >> $DEBUG | ||||
| 	$ECHO "* want to look for an updated version at http://www.scyld.com" >> $DEBUG | ||||
| 	$ECHO "Output of lsmod" >> $DEBUG | ||||
| 	lsmod >> $DEBUG | ||||
| 	$ECHO "---------------------------------------------" >> $DEBUG | ||||
|     fi | ||||
|     $ECHO "* The following section lists your routing table." >> $DEBUG | ||||
|     $ECHO "* If you have an entry which starts with '0.0.0.0', you probably" >> $DEBUG | ||||
|     $ECHO "* have defined a default route and gateway, and pppd will" >> $DEBUG | ||||
|     $ECHO "* not create a default route using your ISP.  Try getting" >> $DEBUG | ||||
|     $ECHO "* rid of this route." >> $DEBUG | ||||
|     $ECHO "Output of netstat -n -r" >> $DEBUG | ||||
|     netstat -n -r >> $DEBUG | ||||
|     $ECHO "---------------------------------------------" >> $DEBUG | ||||
|     $ECHO "Contents of /etc/resolv.conf" >> $DEBUG | ||||
|     $ECHO "* The following section lists DNS setup." >> $DEBUG | ||||
|     $ECHO "* If you can browse by IP address, but not name, suspect" >> $DEBUG | ||||
|     $ECHO "* a DNS problem." >> $DEBUG | ||||
|     cat /etc/resolv.conf >> $DEBUG | ||||
|     $ECHO "---------------------------------------------" >> $DEBUG | ||||
|     $ECHO "* The following section lists /etc/ppp/options." >> $DEBUG | ||||
|     $ECHO "* You should have NOTHING in that file." >> $DEBUG | ||||
|     $ECHO "Contents of /etc/ppp/options" >> $DEBUG | ||||
|     cat /etc/ppp/options >> $DEBUG 2>/dev/null | ||||
|     $ECHO "---------------------------------------------" >> $DEBUG | ||||
|     DEBUG="1" | ||||
| fi | ||||
|  | ||||
| # Sort out command-line arguments | ||||
| case "$#" in | ||||
|     1) | ||||
| 	CONFIG="$1" | ||||
| 	;; | ||||
|     3) | ||||
| 	CONFIG="$3" | ||||
| 	;; | ||||
| esac | ||||
|  | ||||
| if [ -z "$CONFIG" ] ; then | ||||
|     get_device | ||||
|     [ -z "$CONFIG" ] && CONFIG=/etc/ppp/pppoe.conf | ||||
| fi | ||||
|  | ||||
| if [ ! -f "$CONFIG" -o ! -r "$CONFIG" ] ; then | ||||
|     [ "$DEBUG" = "1" ] && $ECHO "$ME: Cannot read configuration file '$CONFIG'" >& 2 | ||||
|     exit 1 | ||||
| fi | ||||
|  | ||||
| export CONFIG | ||||
| . $CONFIG | ||||
|  | ||||
| # Check for command-line overriding of ETH and USER | ||||
| case "$#" in | ||||
|     2|3) | ||||
| 	ETH="$1" | ||||
| 	USER="$2" | ||||
| 	;; | ||||
| esac | ||||
|  | ||||
| # Check for pidfile | ||||
| if [ -r "$PIDFILE" ] ; then | ||||
|     PID=`cat "$PIDFILE"` | ||||
|     # Check if still running | ||||
|     kill -0 $PID > /dev/null 2>&1 | ||||
|     if [ $? = 0 ] ; then | ||||
| 	[ "$DEBUG" = "1" ] && $ECHO "$ME: There already seems to be an PPPoE connection up (PID $PID)" >& 2 | ||||
| 	exit 1 | ||||
|     fi | ||||
|     # Delete bogus PIDFILE | ||||
|     rm -f "$PIDFILE" "$PIDFILE.pppd" "$PIDFILE.pppoe" "$PIDFILE.start" | ||||
| fi | ||||
|  | ||||
| echo $$ > $PIDFILE.start | ||||
|  | ||||
| # Start the connection in the background unless we're debugging | ||||
| if [ "$DEBUG" != "" ] ; then | ||||
|     $CONNECT "$@" | ||||
|     exit 0 | ||||
| fi | ||||
|  | ||||
| $CONNECT "$@" > /dev/null 2>&1 & | ||||
| CONNECT_PID=$! | ||||
|  | ||||
| if [ "$CONNECT_TIMEOUT" = "" -o "$CONNECT_TIMEOUT" = 0 ] ; then | ||||
|     exit 0 | ||||
| fi | ||||
|  | ||||
| # Don't monitor connection if dial-on-demand | ||||
| if [ "$DEMAND" != "" -a "$DEMAND" != "no" ] ; then | ||||
|     exit 0 | ||||
| fi | ||||
|  | ||||
| # Monitor connection | ||||
| TIME=0 | ||||
| while [ true ] ; do | ||||
|     /sbin/pppoe-status $CONFIG > /dev/null 2>&1 | ||||
|  | ||||
|     # Looks like the interface came up | ||||
|     if [ $? = 0 ] ; then | ||||
| 	# Print newline if standard input is a TTY | ||||
| 	[ "$DEBUG" = "1" ] && tty -s && $ECHO " Connected!" | ||||
| 	exit 0 | ||||
|     fi | ||||
|  | ||||
|     if test -n "$FORCEPING" ; then | ||||
| 	[ "$DEBUG" = "1" ] && $ECHO -n "$FORCEPING" | ||||
|     else | ||||
| 	[ "$DEBUG" = "1" ] && tty -s && $ECHO -n "$PING" | ||||
|     fi | ||||
|     sleep $CONNECT_POLL | ||||
|     TIME=`expr $TIME + $CONNECT_POLL` | ||||
|     if [ $TIME -gt $CONNECT_TIMEOUT ] ; then | ||||
| 	break | ||||
|     fi | ||||
| done | ||||
|  | ||||
| [ "$DEBUG" = "1" ] && $ECHO "TIMED OUT" >& 2 | ||||
| # Timed out!  Kill the pppoe-connect process and quit | ||||
| kill $CONNECT_PID > /dev/null 2>&1 | ||||
|  | ||||
| # Clean up PIDFILE(s) | ||||
| rm -f "$PIDFILE" "$PIDFILE.pppd" "$PIDFILE.pppoe" "$PIDFILE.start" | ||||
|  | ||||
| # add old default gw back | ||||
| if [ -s /etc/default-routes ] ; then | ||||
|     while read spec; do | ||||
|         /sbin/ip route add $spec | ||||
|     done < /etc/default-routes | ||||
|     rm -f /etc/default-routes | ||||
| fi | ||||
|  | ||||
| exit 1 | ||||
|  | ||||
							
								
								
									
										104
									
								
								pppoe-status
									
									
									
									
									
										Executable file
									
								
							
							
						
						
									
										104
									
								
								pppoe-status
									
									
									
									
									
										Executable file
									
								
							| @@ -0,0 +1,104 @@ | ||||
| #! /bin/bash | ||||
| #*********************************************************************** | ||||
| # | ||||
| # pppoe-status | ||||
| # | ||||
| # Shell script to report on status of PPPoE connection | ||||
| # | ||||
| # Copyright (C) 2000-2001 Roaring Penguin Software Inc. | ||||
| # | ||||
| # $Id$ | ||||
| # | ||||
| # This file may be distributed under the terms of the GNU General | ||||
| # Public License. | ||||
| # | ||||
| # LIC: GPL | ||||
| # | ||||
| # Usage: pppoe-status [config_file] | ||||
| # If config_file is omitted, defaults to /etc/ppp/pppoe.conf | ||||
| # | ||||
| #*********************************************************************** | ||||
|  | ||||
| # Defaults | ||||
| LS=/bin/ls | ||||
| NETWORKDIR=/etc/sysconfig/network-scripts | ||||
|  | ||||
| get_device() { | ||||
|     if [ ! -d $NETWORKDIR ] ; then | ||||
|         $ECHO "** $NETWORKDIR not found" | ||||
|         $ECHO "** Quitting" | ||||
|         exit 1 | ||||
|     fi | ||||
|  | ||||
|     cd $NETWORKDIR | ||||
|     interfaces=$($LS ifcfg-ppp* 2>/dev/null | egrep -v '(~|\.bak)$' | \ | ||||
|                  egrep -v '(rpmsave|rpmorig|rpmnew)' | sed 's/^ifcfg-//g') | ||||
|  | ||||
|     for i in $interfaces ; do | ||||
|         test -f ifcfg-$i && . ifcfg-$i 2>/dev/null | ||||
|         if [ "$TYPE" = "xDSL" ] ; then | ||||
|             CONFIG=$NETWORKDIR/ifcfg-$i | ||||
|             break | ||||
|         fi | ||||
|     done | ||||
| } | ||||
|  | ||||
| CONFIG="$1" | ||||
| if [ -z "$CONFIG" ] ; then | ||||
|     get_device | ||||
|     [ -z "$CONFIG" ] && CONFIG=/etc/ppp/pppoe.conf | ||||
| fi | ||||
|  | ||||
| if [ ! -f "$CONFIG" -o ! -r "$CONFIG" ] ; then | ||||
|     echo "$0: Cannot read configuration file '$CONFIG'" >& 2 | ||||
|     exit 1 | ||||
| fi | ||||
|  | ||||
| . $CONFIG | ||||
|  | ||||
| PPPOE_PIDFILE="$PIDFILE.pppoe" | ||||
| PPPD_PIDFILE="$PIDFILE.pppd" | ||||
|  | ||||
| if [ "$DEMAND" != "no" ] ; then | ||||
|     echo "Note: You have enabled demand-connection; pppoe-status may be inaccurate." | ||||
| fi | ||||
|  | ||||
| # If no PPPOE_PIDFILE, connection is down, unless we're using the Linux plugin | ||||
| if [ "$LINUX_PLUGIN" = "" ] ; then | ||||
|     if [ ! -r "$PPPOE_PIDFILE" ] ; then | ||||
| 	echo "pppoe-status: Link is down (can't read pppoe PID file $PPPOE_PIDFILE)" | ||||
| 	exit 1 | ||||
|     fi | ||||
| fi | ||||
|  | ||||
| # If no PPPD_PIDFILE, something fishy! | ||||
| if [ ! -r "$PPPD_PIDFILE" ] ; then | ||||
|     echo "pppoe-status: Link is down (can't read pppd PID file $PPPD_PIDFILE)" | ||||
|     exit 1 | ||||
| fi | ||||
|  | ||||
| PPPD_PID=`cat "$PPPD_PIDFILE"` | ||||
|  | ||||
| # Sigh.  Some versions of pppd put PID files in /var/run; others put them | ||||
| # in /etc/ppp.  Since it's too messy to figure out what pppd does, we | ||||
| # try both locations. | ||||
| for i in /etc/ppp/ppp*.pid /var/run/ppp*.pid ; do | ||||
|     if [ -r $i ] ; then | ||||
| 	PID=`cat $i` | ||||
| 	if [ "$PID" = "$PPPD_PID" ] ; then | ||||
| 	    IF=`basename $i .pid` | ||||
| 	    netstat -rn | grep " ${IF}\$" > /dev/null | ||||
| 	    if [ "$?" != "0" ] ; then | ||||
| 		echo "pppoe-status: Link is attached to $IF, but $IF is down" | ||||
| 		exit 1 | ||||
| 	    fi | ||||
| 	    echo "pppoe-status: Link is up and running on interface $IF" | ||||
| 	    /sbin/ip addr show $IF | ||||
| 	    exit 0 | ||||
| 	fi | ||||
|     fi | ||||
| done | ||||
|  | ||||
| echo "ppppoe-status: Link is down -- could not find interface corresponding to" | ||||
| echo "pppd pid $PPPD_PID" | ||||
| exit 1 | ||||
							
								
								
									
										142
									
								
								pppoe-stop
									
									
									
									
									
										Executable file
									
								
							
							
						
						
									
										142
									
								
								pppoe-stop
									
									
									
									
									
										Executable file
									
								
							| @@ -0,0 +1,142 @@ | ||||
| #! /bin/bash | ||||
| # Generated automatically from pppoe-stop.in by configure. | ||||
| #*********************************************************************** | ||||
| # | ||||
| # pppoe-stop | ||||
| # | ||||
| # Shell script to bring down an PPPoE connection | ||||
| # | ||||
| # Copyright (C) 2000 Roaring Penguin Software Inc. | ||||
| # | ||||
| # $Id$ | ||||
| # | ||||
| # This file may be distributed under the terms of the GNU General | ||||
| # Public License. | ||||
| # | ||||
| # LIC: GPL | ||||
| # | ||||
| # Usage: pppoe-stop [config_file] | ||||
| # If config_file is omitted, defaults to /etc/ppp/pppoe.conf | ||||
| # | ||||
| #*********************************************************************** | ||||
|  | ||||
| export PATH=/sbin:/bin:/usr/sbin:/usr/bin | ||||
|  | ||||
| LS=/bin/ls | ||||
| NETWORKDIR=/etc/sysconfig/network-scripts | ||||
|  | ||||
| # Set to "C" locale so we can parse messages from commands | ||||
| LANG=C | ||||
| export LANG | ||||
|  | ||||
| get_device() { | ||||
|     if [ ! -d $NETWORKDIR ] ; then | ||||
|         $ECHO "** $NETWORKDIR not found" | ||||
|         $ECHO "** Quitting" | ||||
|         exit 1 | ||||
|     fi | ||||
|  | ||||
|     cd $NETWORKDIR | ||||
|     interfaces=$($LS ifcfg-ppp* 2>/dev/null | egrep -v '(~|\.bak)$' | \ | ||||
|                  egrep -v '(rpmsave|rpmorig|rpmnew)' | sed 's/^ifcfg-//g') | ||||
|  | ||||
|     for i in $interfaces ; do | ||||
|         test -f ifcfg-$i && . ifcfg-$i 2>/dev/null | ||||
|         if [ "$TYPE" = "xDSL" ] ; then | ||||
|             CONFIG=$NETWORKDIR/ifcfg-$i | ||||
|             break | ||||
|         fi | ||||
|     done | ||||
| } | ||||
|  | ||||
| ME="`basename $0`" | ||||
| LOGGER="/usr/bin/logger -t $ME" | ||||
| CONFIG="$1" | ||||
| if [ -z "$CONFIG" ] ; then | ||||
|     get_device | ||||
|     [ -z "$CONFIG" ] && CONFIG=/etc/ppp/pppoe.conf | ||||
| fi | ||||
|  | ||||
| if [ ! -f "$CONFIG" -o ! -r "$CONFIG" ] ; then | ||||
|     [ "$DEBUG" = "1" ] && echo "$ME: Cannot read configuration file '$CONFIG'" >& 2 | ||||
|     exit 1 | ||||
| fi | ||||
|  | ||||
| export CONFIG | ||||
| . $CONFIG | ||||
|  | ||||
| PPPOE_PIDFILE="$PIDFILE.pppoe" | ||||
| PPPD_PIDFILE="$PIDFILE.pppd" | ||||
| STARTPID="$PIDFILE.start" | ||||
|  | ||||
| # Backward config file compatibility | ||||
| if test "$DEMAND" = "" ; then | ||||
| 	DEMAND=no | ||||
| fi | ||||
|  | ||||
| # Ignore SIGTERM | ||||
| trap "" 15 | ||||
|  | ||||
| # Check for pidfile | ||||
| if [ -r "$PIDFILE" ] ; then | ||||
|     PID=`cat $PIDFILE` | ||||
|  | ||||
|     # Check if still running | ||||
|     kill -0 $PID > /dev/null 2>&1 | ||||
|     if [ $? != 0 ] ; then | ||||
|         [ "$DEBUG" = "1" ] && echo "$ME: The pppoe-connect script (PID $PID) appears to have died" >& 2 | ||||
|     fi | ||||
|  | ||||
|     # Kill pppd, which should in turn kill pppoe | ||||
|     if [ -r "$PPPD_PIDFILE" ] ; then | ||||
|         PPPD_PID=`cat "$PPPD_PIDFILE"` | ||||
|         $LOGGER -p daemon.notice "Killing pppd" | ||||
|         [ "$DEBUG" = "1" ] && echo "Killing pppd ($PPPD_PID)" | ||||
|         kill $PPPD_PID > /dev/null 2>&1 | ||||
|     fi | ||||
|  | ||||
|     # Kill pppoe-start | ||||
|     PIDS=`cat $STARTPID` | ||||
|     kill -0 $PIDS > /dev/null 2>&1 | ||||
|     if [ $? = 0 ] ; then | ||||
|         $LOGGER -p daemon.notice "Killing pppoe-connect" | ||||
|         kill $PIDS > /dev/null 2>&1 | ||||
|     fi | ||||
|  | ||||
|     # Kill pppoe-connect | ||||
|     $LOGGER -p daemon.notice "Killing pppoe-connect" | ||||
|     [ "$DEBUG" = "1" ] && echo "Killing pppoe-connect ($PID)" | ||||
|     kill $PID > /dev/null 2>&1 | ||||
|  | ||||
|     # Kill pppd again, in case it's still hanging around | ||||
|     if [ -r "$PPPD_PIDFILE" ] ; then | ||||
|        PPPD_PID=`cat "$PPPD_PIDFILE"` | ||||
|        kill -9 $PPPD_PID > /dev/null 2>&1 || exit 1 | ||||
|     fi | ||||
|  | ||||
|     # Kill br2684ctl if necessary | ||||
|     if [ -n "$BR2684DEV" -a -r /var/run/nas$BR2684DEV.pid ]; then | ||||
| 	PIDS=`cat /var/run/nas$BR2684DEV.pid` | ||||
| 	kill -0 $PIDS > /dev/null 2>&1 | ||||
| 	if [ $? = 0 ]; then | ||||
| 	    $LOGGER -p daemon.notice "Killing br2684ctl for nas$BR2684DEV" | ||||
| 	    kill $PIDS > /dev/null 2>&1 | ||||
| 	fi | ||||
| 	rm -f /var/run/nas$BR2684DEV.pid | ||||
|     fi | ||||
|  | ||||
|     rm -f "$PIDFILE" "$PPPD_PIDFILE" "$PPPOE_PIDFILE" "$STARTPID" | ||||
| else | ||||
|     [ "$DEBUG" = "1" ] && echo "$ME: No PPPoE connection appears to be running" >&2 | ||||
|     exit 1 | ||||
| fi | ||||
|  | ||||
| # add old default gw back | ||||
| if [ -s /etc/default-routes ] ; then | ||||
|     while read spec; do | ||||
|         /sbin/ip route add $spec | ||||
|     done < /etc/default-routes | ||||
|     rm -f /etc/default-routes | ||||
| fi | ||||
|  | ||||
| exit 0 | ||||
							
								
								
									
										119
									
								
								rp-pppoe-3.11-ip-allocation.patch
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										119
									
								
								rp-pppoe-3.11-ip-allocation.patch
									
									
									
									
									
										Normal file
									
								
							| @@ -0,0 +1,119 @@ | ||||
| diff -up rp-pppoe-3.11/man/pppoe-server.8.orig rp-pppoe-3.11/man/pppoe-server.8 | ||||
| --- rp-pppoe-3.11/man/pppoe-server.8.orig	2012-08-17 20:31:25.000000000 +0200 | ||||
| +++ rp-pppoe-3.11/man/pppoe-server.8	2012-08-20 12:32:45.008870731 +0200 | ||||
| @@ -96,6 +96,11 @@ valid remote IP address to \fBpppd\fR. | ||||
|  of 10.67.15.1 is used. | ||||
|   | ||||
|  .TP | ||||
| +.B \-D | ||||
| +Delegate the allocation of IP addresses to \fBpppd\fR.  If specified, no | ||||
| +local and remote addresses passed to pppd. | ||||
| + | ||||
| +.TP | ||||
|  .B \-N \fInum\fR | ||||
|  Allows at most \fInum\fR concurrent PPPoE sessions.  If not specified, | ||||
|  the default is 64. | ||||
| diff -up rp-pppoe-3.11/src/pppoe-server.c.orig rp-pppoe-3.11/src/pppoe-server.c | ||||
| --- rp-pppoe-3.11/src/pppoe-server.c.orig	2012-08-17 20:31:25.000000000 +0200 | ||||
| +++ rp-pppoe-3.11/src/pppoe-server.c	2012-08-20 12:34:25.348145846 +0200 | ||||
| @@ -176,6 +176,9 @@ char PppoeOptions[SMALLBUF] = ""; | ||||
|  unsigned char LocalIP[IPV4ALEN] = {10, 0, 0, 1}; /* Counter optionally STARTS here */ | ||||
|  unsigned char RemoteIP[IPV4ALEN] = {10, 67, 15, 1}; /* Counter STARTS here */ | ||||
|   | ||||
| +/* Delegates the allocation of IP addresses to pppd (as the pptpd doing) */ | ||||
| +int DelegateIPAllocation = 0; | ||||
| + | ||||
|  /* Do we increment local IP for each connection? */ | ||||
|  int IncrLocalIP = 0; | ||||
|   | ||||
| @@ -242,15 +245,25 @@ childHandler(pid_t pid, int status, void | ||||
|      memset(&conn, 0, sizeof(conn)); | ||||
|      conn.useHostUniq = 0; | ||||
|   | ||||
| -    syslog(LOG_INFO, | ||||
| -	   "Session %u closed for client " | ||||
| -	   "%02x:%02x:%02x:%02x:%02x:%02x (%d.%d.%d.%d) on %s", | ||||
| -	   (unsigned int) ntohs(session->sess), | ||||
| -	   session->eth[0], session->eth[1], session->eth[2], | ||||
| -	   session->eth[3], session->eth[4], session->eth[5], | ||||
| -	   (int) session->realpeerip[0], (int) session->realpeerip[1], | ||||
| -	   (int) session->realpeerip[2], (int) session->realpeerip[3], | ||||
| -	   session->ethif->name); | ||||
| +    if (!DelegateIPAllocation) { | ||||
| +	syslog(LOG_INFO, | ||||
| +	    "Session %u closed for client " | ||||
| +	    "%02x:%02x:%02x:%02x:%02x:%02x (%d.%d.%d.%d) on %s", | ||||
| +	    (unsigned int) ntohs(session->sess), | ||||
| +	    session->eth[0], session->eth[1], session->eth[2], | ||||
| +	    session->eth[3], session->eth[4], session->eth[5], | ||||
| +	    (int) session->realpeerip[0], (int) session->realpeerip[1], | ||||
| +	    (int) session->realpeerip[2], (int) session->realpeerip[3], | ||||
| +	    session->ethif->name); | ||||
| +    } else { | ||||
| +	syslog(LOG_INFO, | ||||
| +	    "Session %u closed for client " | ||||
| +	    "%02x:%02x:%02x:%02x:%02x:%02x on %s", | ||||
| +	    (unsigned int) ntohs(session->sess), | ||||
| +	    session->eth[0], session->eth[1], session->eth[2], | ||||
| +	    session->eth[3], session->eth[4], session->eth[5], | ||||
| +	    session->ethif->name); | ||||
| +    } | ||||
|      memcpy(conn.myEth, session->ethif->mac, ETH_ALEN); | ||||
|      conn.discoverySocket = session->ethif->sock; | ||||
|      conn.session = session->sess; | ||||
| @@ -1134,6 +1147,7 @@ usage(char const *argv0) | ||||
|      fprintf(stderr, "   -L ip          -- Set local IP address.\n"); | ||||
|      fprintf(stderr, "   -l             -- Increment local IP address for each session.\n"); | ||||
|      fprintf(stderr, "   -R ip          -- Set start address of remote IP pool.\n"); | ||||
| +    fprintf(stderr, "   -D             -- Delegates the allocation of IP addresses to pppd.\n"); | ||||
|      fprintf(stderr, "   -S name        -- Advertise specified service-name.\n"); | ||||
|      fprintf(stderr, "   -O fname       -- Use PPPD options from specified file\n"); | ||||
|      fprintf(stderr, "                     (default %s).\n", PPPOE_SERVER_OPTIONS); | ||||
| @@ -1200,9 +1214,9 @@ main(int argc, char **argv) | ||||
|  #endif | ||||
|   | ||||
|  #ifndef HAVE_LINUX_KERNEL_PPPOE | ||||
| -    char *options = "X:ix:hI:C:L:R:T:m:FN:f:O:o:sp:lrudPc:S:1q:Q:"; | ||||
| +    char *options = "X:ix:hI:C:L:R:DT:m:FN:f:O:o:sp:lrudPc:S:1q:Q:"; | ||||
|  #else | ||||
| -    char *options = "X:ix:hI:C:L:R:T:m:FN:f:O:o:skp:lrudPc:S:1q:Q:"; | ||||
| +    char *options = "X:ix:hI:C:L:R:DT:m:FN:f:O:o:skp:lrudPc:S:1q:Q:"; | ||||
|  #endif | ||||
|   | ||||
|      if (getuid() != geteuid() || | ||||
| @@ -1401,6 +1415,10 @@ main(int argc, char **argv) | ||||
|  	    } | ||||
|  	    break; | ||||
|   | ||||
| +	case 'D': | ||||
| +	    DelegateIPAllocation = 1; | ||||
| +	    break; | ||||
| + | ||||
|  	case 'T': | ||||
|  	case 'm': | ||||
|  	    /* These just get passed to pppoe */ | ||||
| @@ -1915,6 +1933,7 @@ startPPPDUserMode(ClientSession *session | ||||
|      argv[c++] = "file"; | ||||
|      argv[c++] = pppoptfile; | ||||
|   | ||||
| +    if (!DelegateIPAllocation) { | ||||
|      snprintf(buffer, SMALLBUF, "%d.%d.%d.%d:%d.%d.%d.%d", | ||||
|  	    (int) session->myip[0], (int) session->myip[1], | ||||
|  	    (int) session->myip[2], (int) session->myip[3], | ||||
| @@ -1930,6 +1949,16 @@ startPPPDUserMode(ClientSession *session | ||||
|  	   session->ethif->name, | ||||
|  	   session->serviceName); | ||||
|      argv[c++] = strdup(buffer); | ||||
| +    } else { | ||||
| +	syslog(LOG_INFO, | ||||
| +	    "Session %u created for client %02x:%02x:%02x:%02x:%02x:%02x on %s using Service-Name '%s'", | ||||
| +	    (unsigned int) ntohs(session->sess), | ||||
| +	    session->eth[0], session->eth[1], session->eth[2], | ||||
| +	    session->eth[3], session->eth[4], session->eth[5], | ||||
| +	    session->ethif->name, | ||||
| +	    session->serviceName); | ||||
| +    } | ||||
| +     | ||||
|      if (!argv[c-1]) { | ||||
|  	/* TODO: Send a PADT */ | ||||
|  	exit(EXIT_FAILURE); | ||||
							
								
								
									
										108
									
								
								rp-pppoe-3.14-ip-allocation.lux.patch
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										108
									
								
								rp-pppoe-3.14-ip-allocation.lux.patch
									
									
									
									
									
										Normal file
									
								
							| @@ -0,0 +1,108 @@ | ||||
| diff -uarNbB '--exclude=*.orig' '--exclude=*.rej' rp-pppoe-3.14.orig/man/pppoe-server.8 rp-pppoe-3.14/man/pppoe-server.8 | ||||
| --- rp-pppoe-3.14.orig/man/pppoe-server.8	2020-05-27 02:29:37.000000000 +0200 | ||||
| +++ rp-pppoe-3.14/man/pppoe-server.8	2020-08-23 07:46:06.007078604 +0200 | ||||
| @@ -96,6 +96,11 @@ | ||||
|  of 10.67.15.1 is used. | ||||
|   | ||||
|  .TP | ||||
| +.B \-D | ||||
| +Delegate the allocation of IP addresses to \fBpppd\fR.  If specified, no | ||||
| +local and remote addresses passed to pppd. | ||||
| + | ||||
| +.TP | ||||
|  .B \-N \fInum\fR | ||||
|  Allows at most \fInum\fR concurrent PPPoE sessions.  If not specified, | ||||
|  the default is 64. | ||||
| diff -uarNbB '--exclude=*.orig' '--exclude=*.rej' rp-pppoe-3.14.orig/src/pppoe-server.c rp-pppoe-3.14/src/pppoe-server.c | ||||
| --- rp-pppoe-3.14.orig/src/pppoe-server.c	2020-05-27 02:29:37.000000000 +0200 | ||||
| +++ rp-pppoe-3.14/src/pppoe-server.c	2020-08-23 07:49:11.814181477 +0200 | ||||
| @@ -182,6 +182,9 @@ | ||||
|  unsigned char LocalIP[IPV4ALEN] = {10, 0, 0, 1}; /* Counter optionally STARTS here */ | ||||
|  unsigned char RemoteIP[IPV4ALEN] = {10, 67, 15, 1}; /* Counter STARTS here */ | ||||
|   | ||||
| +/* Delegates the allocation of IP addresses to pppd (as the pptpd doing) */ | ||||
| +int DelegateIPAllocation = 0; | ||||
| + | ||||
|  /* Do we increment local IP for each connection? */ | ||||
|  int IncrLocalIP = 0; | ||||
|   | ||||
| @@ -248,6 +251,7 @@ | ||||
|      memset(&conn, 0, sizeof(conn)); | ||||
|      conn.hostUniq = NULL; | ||||
|   | ||||
| +    if (!DelegateIPAllocation) { | ||||
|      syslog(LOG_INFO, | ||||
|  	   "Session %u closed for client " | ||||
|  	   "%02x:%02x:%02x:%02x:%02x:%02x (%d.%d.%d.%d) on %s", | ||||
| @@ -257,6 +261,15 @@ | ||||
|  	   (int) session->realpeerip[0], (int) session->realpeerip[1], | ||||
|  	   (int) session->realpeerip[2], (int) session->realpeerip[3], | ||||
|  	   session->ethif->name); | ||||
| +    } else { | ||||
| +	syslog(LOG_INFO, | ||||
| +	    "Session %u closed for client " | ||||
| +	    "%02x:%02x:%02x:%02x:%02x:%02x on %s", | ||||
| +	    (unsigned int) ntohs(session->sess), | ||||
| +	    session->eth[0], session->eth[1], session->eth[2], | ||||
| +	    session->eth[3], session->eth[4], session->eth[5], | ||||
| +	    session->ethif->name); | ||||
| +    } | ||||
|      memcpy(conn.myEth, session->ethif->mac, ETH_ALEN); | ||||
|      conn.discoverySocket = session->ethif->sock; | ||||
|      conn.session = session->sess; | ||||
| @@ -1155,6 +1168,7 @@ | ||||
|      fprintf(stderr, "   -L ip          -- Set local IP address.\n"); | ||||
|      fprintf(stderr, "   -l             -- Increment local IP address for each session.\n"); | ||||
|      fprintf(stderr, "   -R ip          -- Set start address of remote IP pool.\n"); | ||||
| +    fprintf(stderr, "   -D             -- Delegates the allocation of IP addresses to pppd.\n"); | ||||
|      fprintf(stderr, "   -S name        -- Advertise specified service-name.\n"); | ||||
|      fprintf(stderr, "   -O fname       -- Use PPPD options from specified file\n"); | ||||
|      fprintf(stderr, "                     (default %s).\n", PPPOE_SERVER_OPTIONS); | ||||
| @@ -1224,9 +1238,9 @@ | ||||
|  #endif | ||||
|   | ||||
|  #ifndef HAVE_LINUX_KERNEL_PPPOE | ||||
| -    char *options = "X:ix:hI:C:L:R:T:m:FN:f:O:o:sp:lrudPc:S:1q:Q:H:M:"; | ||||
| +    char *options = "X:ix:hI:C:L:R:DT:m:FN:f:O:o:sp:lrudPc:S:1q:Q:H:M:"; | ||||
|  #else | ||||
| -    char *options = "X:ix:hI:C:L:R:T:m:FN:f:O:o:skp:lrudPc:S:1q:Q:H:M:"; | ||||
| +    char *options = "X:ix:hI:C:L:R:DT:m:FN:f:O:o:skp:lrudPc:S:1q:Q:H:M:"; | ||||
|  #endif | ||||
|   | ||||
|      if (getuid() != geteuid() || | ||||
| @@ -1448,6 +1462,10 @@ | ||||
|  	    } | ||||
|  	    break; | ||||
|   | ||||
| +	case 'D': | ||||
| +	    DelegateIPAllocation = 1; | ||||
| +	    break; | ||||
| + | ||||
|  	case 'T': | ||||
|  	case 'm': | ||||
|  	    /* These just get passed to pppoe */ | ||||
| @@ -2056,6 +2074,7 @@ | ||||
|      argv[c++] = "file"; | ||||
|      argv[c++] = pppoptfile; | ||||
|   | ||||
| +    if (!DelegateIPAllocation) { | ||||
|      snprintf(buffer, SMALLBUF, "%d.%d.%d.%d:%d.%d.%d.%d", | ||||
|  	    (int) session->myip[0], (int) session->myip[1], | ||||
|  	    (int) session->myip[2], (int) session->myip[3], | ||||
| @@ -2071,6 +2090,16 @@ | ||||
|  	   session->ethif->name, | ||||
|  	   session->serviceName); | ||||
|      argv[c++] = strdup(buffer); | ||||
| +    } else { | ||||
| +	syslog(LOG_INFO, | ||||
| +	    "Session %u created for client %02x:%02x:%02x:%02x:%02x:%02x on %s using Service-Name '%s'", | ||||
| +	    (unsigned int) ntohs(session->sess), | ||||
| +	    session->eth[0], session->eth[1], session->eth[2], | ||||
| +	    session->eth[3], session->eth[4], session->eth[5], | ||||
| +	    session->ethif->name, | ||||
| +	    session->serviceName); | ||||
| +    } | ||||
| +     | ||||
|      if (!argv[c-1]) { | ||||
|  	/* TODO: Send a PADT */ | ||||
|  	exit(EXIT_FAILURE); | ||||
							
								
								
									
										71
									
								
								rp-pppoe-3.14-manpages.lux.patch
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										71
									
								
								rp-pppoe-3.14-manpages.lux.patch
									
									
									
									
									
										Normal file
									
								
							| @@ -0,0 +1,71 @@ | ||||
| diff -uarNbB '--exclude=*.orig' '--exclude=*.rej' rp-pppoe-3.14.orig/man/pppoe.8 rp-pppoe-3.14/man/pppoe.8 | ||||
| --- rp-pppoe-3.14.orig/man/pppoe.8	2020-05-27 02:29:37.000000000 +0200 | ||||
| +++ rp-pppoe-3.14/man/pppoe.8	2020-08-23 07:51:09.033859091 +0200 | ||||
| @@ -32,6 +32,10 @@ | ||||
|  PPPoE timeout to be about four times the LCP echo interval. | ||||
|   | ||||
|  .TP | ||||
| +.B \-t \fItimeout\fR | ||||
| +The \fB\-t\fR option sets the initial timeout for discovery packets in seconds. | ||||
| + | ||||
| +.TP | ||||
|  .B \-D \fIfile_name\fR | ||||
|  The \fB\-D\fR option causes every packet to be dumped to the specified | ||||
|  \fIfile_name\fR.  This is intended for debugging only; it produces huge | ||||
| @@ -147,6 +151,10 @@ | ||||
|  ISP uses non-standard frame types, complain! | ||||
|   | ||||
|  .TP | ||||
| +.B \-F numfloods | ||||
| +The \fB\-F\fR option sets the discovery flood, only used for stress-testing. | ||||
| + | ||||
| +.TP | ||||
|  .B \-h | ||||
|  The \fB\-h\fR option causes \fBpppoe\fR to print usage information and | ||||
|  exit. | ||||
| diff -uarNbB '--exclude=*.orig' '--exclude=*.rej' rp-pppoe-3.14.orig/man/pppoe-server.8 rp-pppoe-3.14/man/pppoe-server.8 | ||||
| --- rp-pppoe-3.14.orig/man/pppoe-server.8	2020-08-23 07:50:35.650666110 +0200 | ||||
| +++ rp-pppoe-3.14/man/pppoe-server.8	2020-08-23 07:51:09.034859097 +0200 | ||||
| @@ -77,12 +77,20 @@ | ||||
|  then no limit is imposed on the number of sessions per peer MAC address. | ||||
|   | ||||
|  .TP | ||||
| +.B \-P | ||||
| +Check pool file for correctness and exit. | ||||
| + | ||||
| +.TP | ||||
|  .B \-s | ||||
|  This option is passed directly to \fBpppoe\fR; see \fBpppoe\fR(8) for | ||||
|  details.  In addition, it causes \fBpppd\fR to be invoked with the | ||||
|  \fIsync\fR option. | ||||
|   | ||||
|  .TP | ||||
| +.B \-l | ||||
| +Increment local IP address for each session. | ||||
| + | ||||
| +.TP | ||||
|  .B \-L \fIip\fR | ||||
|  Sets the local IP address.  This is passed to spawned \fBpppd\fR processes. | ||||
|  If not specified, the default is 10.0.0.1. | ||||
| @@ -158,6 +166,10 @@ | ||||
|  unpredictable order. | ||||
|   | ||||
|  .TP | ||||
| +.B \-d | ||||
| +Debug session creation. | ||||
| + | ||||
| +.TP | ||||
|  .B \-u | ||||
|  Tells the server to invoke \fBpppd\fR with the \fIunit\fR option.  Note | ||||
|  that this option only works for \fBpppd\fR version 2.4.0 or newer. | ||||
| diff -uarNbB '--exclude=*.orig' '--exclude=*.rej' rp-pppoe-3.14.orig/src/pppoe.c rp-pppoe-3.14/src/pppoe.c | ||||
| --- rp-pppoe-3.14.orig/src/pppoe.c	2020-05-27 02:29:37.000000000 +0200 | ||||
| +++ rp-pppoe-3.14/src/pppoe.c	2020-08-23 07:51:09.035859103 +0200 | ||||
| @@ -383,6 +383,7 @@ | ||||
|  	    "   -k             -- Kill a session with PADT (requires -e)\n" | ||||
|  	    "   -d             -- Perform discovery, print session info and exit.\n" | ||||
|  	    "   -f disc:sess   -- Set Ethernet frame types (hex).\n" | ||||
| +	    "   -F numfloods   -- Set the discovery flood, only used for stress-testing.\n" | ||||
|  	    "   -h             -- Print usage information.\n\n" | ||||
|  	    "RP-PPPoE Version %s, Copyright (C) 2001-2018 Roaring Penguin Software Inc.\n" | ||||
|  	    "                 %*s  Copyright (C) 2018-2020 Dianne Skoll\n" | ||||
							
								
								
									
										104
									
								
								rp-pppoe-3.14-redhat.lux.patch
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										104
									
								
								rp-pppoe-3.14-redhat.lux.patch
									
									
									
									
									
										Normal file
									
								
							| @@ -0,0 +1,104 @@ | ||||
| diff -uarNbB '--exclude=*.orig' '--exclude=*.rej' rp-pppoe-3.14.orig/man/pppoe.conf.5 rp-pppoe-3.14/man/pppoe.conf.5 | ||||
| --- rp-pppoe-3.14.orig/man/pppoe.conf.5	2020-05-27 02:29:37.000000000 +0200 | ||||
| +++ rp-pppoe-3.14/man/pppoe.conf.5	2020-08-23 07:43:22.741789590 +0200 | ||||
| @@ -2,16 +2,16 @@ | ||||
|  .TH PPPOE.CONF 5 "21 February 2000" | ||||
|  .UC 4 | ||||
|  .SH NAME | ||||
| -pppoe.conf \- Configuration file used by \fBpppoe-start\fR(8), | ||||
| +ifcfg-ppp0 \- Configuration file used by \fBpppoe-start\fR(8), | ||||
|  \fBpppoe-stop\fR(8), \fBpppoe-status(8)\fR and \fBpppoe-connect\fR(8). | ||||
|   | ||||
|  .SH DESCRIPTION | ||||
| -\fB/etc/ppp/pppoe.conf\fR is a shell script which contains configuration | ||||
| -information for RP-PPPoE scripts.  Note that \fBpppoe.conf\fR | ||||
| +\fB/etc/sysconfig/network-scripts/ifcfg-ppp0\fR is a shell script which contains configuration | ||||
| +information for RP-PPPoE scripts.  Note that \fBifcfg-ppp0\fR | ||||
|  is used only by the various pppoe-* shell scripts, not by \fBpppoe\fR | ||||
|  itself. | ||||
|   | ||||
| -\fBpppoe.conf\fR consists of a sequence of shell variable assignments. | ||||
| +\fBifcfg-ppp0\fR consists of a sequence of shell variable assignments. | ||||
|  The variables and their meanings are: | ||||
|   | ||||
|  .TP | ||||
| @@ -54,11 +54,10 @@ | ||||
|  IP addresses of DNS servers if you use DNSTYPE=SPECIFY. | ||||
|   | ||||
|  .TP | ||||
| -.B NONROOT | ||||
| -If the line \fBNONROOT=OK\fR (exactly like that; no whitespace or comments) | ||||
| -appears in the configuration file, then \fBpppoe-wrapper\fR will allow | ||||
| -non-root users to bring the conneciton up or down.  The wrapper is installed | ||||
| -only if you installed the rp-pppoe-gui package. | ||||
| +.B USERCTL | ||||
| +If the line \fBUSERCTL=yes\fR (exactly like that; no whitespace or comments) | ||||
| +appears in the configuration file, then \fB/sbin/ifup\fR will allow | ||||
| +non-root users to bring the conneciton up or down. | ||||
|   | ||||
|  .TP | ||||
|  .B USEPEERDNS | ||||
| diff -uarNbB '--exclude=*.orig' '--exclude=*.rej' rp-pppoe-3.14.orig/man/pppoe-connect.8 rp-pppoe-3.14/man/pppoe-connect.8 | ||||
| --- rp-pppoe-3.14.orig/man/pppoe-connect.8	2020-05-27 02:29:37.000000000 +0200 | ||||
| +++ rp-pppoe-3.14/man/pppoe-connect.8	2020-08-23 07:41:04.337069110 +0200 | ||||
| @@ -13,7 +13,8 @@ | ||||
|  .SH DESCRIPTION | ||||
|  \fBpppoe-connect\fR is a shell script which manages a PPPoE connection | ||||
|  using the Roaring Penguin user-space PPPoE client.  If you omit | ||||
| -\fIconfig_file\fR, the default file \fB/etc/ppp/pppoe.conf\fR is used. | ||||
| +\fIconfig_file\fR, the default file | ||||
| +\fB/etc/sysconfig/network-scripts/ifcfg-ppp0\fR is used. | ||||
|  If you supply \fIinterface\fR and \fIuser\fR, then they override the | ||||
|  Ethernet interface and user-name settings in the configuration file. | ||||
|  .P | ||||
| diff -uarNbB '--exclude=*.orig' '--exclude=*.rej' rp-pppoe-3.14.orig/man/pppoe-setup.8 rp-pppoe-3.14/man/pppoe-setup.8 | ||||
| --- rp-pppoe-3.14.orig/man/pppoe-setup.8	2020-05-27 02:29:37.000000000 +0200 | ||||
| +++ rp-pppoe-3.14/man/pppoe-setup.8	2020-08-23 07:41:04.336069104 +0200 | ||||
| @@ -8,8 +8,9 @@ | ||||
|   | ||||
|  .SH DESCRIPTION | ||||
|  \fBpppoe-setup\fR is a shell script which prompts you for various pieces | ||||
| -of information and sets up an /etc/ppp/pppoe.conf configuration script | ||||
| -for the \fBpppoe-start\fR, \fBpppoe-stop\fR and \fBpppoe-connect\fR scripts. | ||||
| +of information and sets up an /etc/sysconfig/network-scripts/ifcfg-ppp0 | ||||
| +configuration script for the \fBpppoe-start\fR, \fBpppoe-stop\fR and | ||||
| ++\fBpppoe-connect\fR scripts. | ||||
|   | ||||
|  .SH AUTHOR | ||||
|  \fBpppoe-setup\fR was written by Dianne Skoll <dianne@skoll.ca>. | ||||
| diff -uarNbB '--exclude=*.orig' '--exclude=*.rej' rp-pppoe-3.14.orig/man/pppoe-start.8 rp-pppoe-3.14/man/pppoe-start.8 | ||||
| --- rp-pppoe-3.14.orig/man/pppoe-start.8	2020-05-27 02:29:37.000000000 +0200 | ||||
| +++ rp-pppoe-3.14/man/pppoe-start.8	2020-08-23 07:41:04.337069110 +0200 | ||||
| @@ -11,7 +11,7 @@ | ||||
|  .SH DESCRIPTION | ||||
|  \fBpppoe-start\fR is a shell script which starts the RP-PPPoE | ||||
|  user-space PPPoE client.  If you omit \fIconfig_file\fR, the default | ||||
| -file \fB/etc/ppp/pppoe.conf\fR is used.  If you supply | ||||
| +file \fB/etc/sysconfig/network-scripts/ifcfg-ppp0\fR is used.  If you supply | ||||
|  \fIinterface\fR and \fIuser\fR, then they override the Ethernet interface | ||||
|  and user-name settings in the configuration file. | ||||
|   | ||||
| diff -uarNbB '--exclude=*.orig' '--exclude=*.rej' rp-pppoe-3.14.orig/man/pppoe-status.8 rp-pppoe-3.14/man/pppoe-status.8 | ||||
| --- rp-pppoe-3.14.orig/man/pppoe-status.8	2020-05-27 02:29:37.000000000 +0200 | ||||
| +++ rp-pppoe-3.14/man/pppoe-status.8	2020-08-23 07:41:04.338069115 +0200 | ||||
| @@ -10,7 +10,7 @@ | ||||
|  \fBpppoe-status\fR is a shell script which checks the status of the | ||||
|  PPPoE link established by the Roaring Penguin user-space PPPoE client. | ||||
|  If you omit \fIconfig_file\fR, the default file | ||||
| -\fB/etc/ppp/pppoe.conf\fR is used. | ||||
| +\fB/etc/sysconfig/network-scripts/ifcfg-ppp0\fR is used. | ||||
|   | ||||
|  .SH AUTHOR | ||||
|  \fBpppoe-status\fR was written by Dianne Skoll <dianne@skoll.ca>. | ||||
| diff -uarNbB '--exclude=*.orig' '--exclude=*.rej' rp-pppoe-3.14.orig/man/pppoe-stop.8 rp-pppoe-3.14/man/pppoe-stop.8 | ||||
| --- rp-pppoe-3.14.orig/man/pppoe-stop.8	2020-05-27 02:29:37.000000000 +0200 | ||||
| +++ rp-pppoe-3.14/man/pppoe-stop.8	2020-08-23 07:41:04.338069115 +0200 | ||||
| @@ -9,7 +9,7 @@ | ||||
|  .SH DESCRIPTION | ||||
|  \fBpppoe-stop\fR is a shell script which stops the RP-PPPoE | ||||
|  user-space PPPoE client.  If you omit \fIconfig_file\fR, the default | ||||
| -file \fB/etc/ppp/pppoe.conf\fR is used. | ||||
| +file \fB/etc/sysconfig/network-scripts/ifcfg-ppp0\fR is used. | ||||
|   | ||||
|  .SH AUTHOR | ||||
|  \fBpppoe-stop\fR was written by Dianne Skoll <dianne@skoll.ca> | ||||
							
								
								
									
										
											BIN
										
									
								
								rp-pppoe-3.14.tar.gz
									 (Stored with Git LFS)
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										
											BIN
										
									
								
								rp-pppoe-3.14.tar.gz
									 (Stored with Git LFS)
									
									
									
									
										Normal file
									
								
							
										
											Binary file not shown.
										
									
								
							
							
								
								
									
										97
									
								
								rp-pppoe-3.8-redhat.patch
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										97
									
								
								rp-pppoe-3.8-redhat.patch
									
									
									
									
									
										Normal file
									
								
							| @@ -0,0 +1,97 @@ | ||||
| --- rp-pppoe-3.8/man/pppoe.conf.5.orig	2007-03-20 18:57:28.000000000 +0100 | ||||
| +++ rp-pppoe-3.8/man/pppoe.conf.5	2007-03-20 19:00:20.000000000 +0100 | ||||
| @@ -4,16 +4,16 @@ | ||||
|  .TH PPPOE.CONF 5 "21 February 2000" | ||||
|  .UC 4 | ||||
|  .SH NAME | ||||
| -pppoe.conf \- Configuration file used by \fBpppoe-start\fR(8), | ||||
| +ifcfg-ppp0 \- Configuration file used by \fBpppoe-start\fR(8), | ||||
|  \fBpppoe-stop\fR(8), \fBpppoe-status(8)\fR and \fBpppoe-connect\fR(8). | ||||
|   | ||||
|  .SH DESCRIPTION | ||||
| -\fB/etc/ppp/pppoe.conf\fR is a shell script which contains configuration | ||||
| +\fB/etc/sysconfig/network-scripts/ifcfg-ppp0\fR is a shell script which contains configuration | ||||
|  information for Roaring Penguin's PPPoE scripts.  Note that \fBpppoe.conf\fR | ||||
|  is used only by the various pppoe-* shell scripts, not by \fBpppoe\fR | ||||
|  itself. | ||||
|   | ||||
| -\fBpppoe.conf\fR consists of a sequence of shell variable assignments. | ||||
| +\fBifcfg-ppp0\fR consists of a sequence of shell variable assignments. | ||||
|  The variables and their meanings are: | ||||
|   | ||||
|  .TP | ||||
| @@ -56,11 +56,10 @@ | ||||
|  IP addresses of DNS servers if you use DNSTYPE=SPECIFY. | ||||
|   | ||||
|  .TP | ||||
| -.B NONROOT | ||||
| -If the line \fBNONROOT=OK\fR (exactly like that; no whitespace or comments) | ||||
| -appears in the configuration file, then \fBpppoe-wrapper\fR will allow | ||||
| -non-root users to bring the conneciton up or down.  The wrapper is installed | ||||
| -only if you installed the rp-pppoe-gui package. | ||||
| +.B USERCTL | ||||
| +If the line \fBUSERCTL=yes\fR (exactly like that; no whitespace or comments) | ||||
| +appears in the configuration file, then \fB/sbin/ifup\fR will allow | ||||
| +non-root users to bring the conneciton up or down. | ||||
|   | ||||
|  .TP | ||||
|  .B USEPEERDNS | ||||
| --- rp-pppoe-3.8/man/pppoe-setup.8.orig	2007-03-20 18:54:49.000000000 +0100 | ||||
| +++ rp-pppoe-3.8/man/pppoe-setup.8	2007-03-20 18:55:59.000000000 +0100 | ||||
| @@ -9,8 +9,9 @@ | ||||
|   | ||||
|  .SH DESCRIPTION | ||||
|  \fBpppoe-setup\fR is a shell script which prompts you for various pieces | ||||
| -of information and sets up an /etc/ppp/pppoe.conf configuration script | ||||
| -for the \fBpppoe-start\fR, \fBpppoe-stop\fR and \fBpppoe-connect\fR scripts. | ||||
| +of information and sets up an /etc/sysconfig/network-scripts/ifcfg-ppp0 | ||||
| +configuration script for the \fBpppoe-start\fR, \fBpppoe-stop\fR and | ||||
| ++\fBpppoe-connect\fR scripts. | ||||
|   | ||||
|  .SH AUTHOR | ||||
|  \fBpppoe-setup\fR was written by David F. Skoll <dfs@roaringpenguin.com>. | ||||
| --- rp-pppoe-3.8/man/pppoe-connect.8.orig	2007-03-20 18:54:20.000000000 +0100 | ||||
| +++ rp-pppoe-3.8/man/pppoe-connect.8	2007-03-20 18:54:40.000000000 +0100 | ||||
| @@ -14,7 +14,8 @@ | ||||
|  .SH DESCRIPTION | ||||
|  \fBpppoe-connect\fR is a shell script which manages a PPPoE connection | ||||
|  using the Roaring Penguin user-space PPPoE client.  If you omit | ||||
| -\fIconfig_file\fR, the default file \fB/etc/ppp/pppoe.conf\fR is used. | ||||
| +\fIconfig_file\fR, the default file | ||||
| +\fB/etc/sysconfig/network-scripts/ifcfg-ppp0\fR is used. | ||||
|  If you supply \fIinterface\fR and \fIuser\fR, then they override the | ||||
|  Ethernet interface and user-name settings in the configuration file. | ||||
|  .P | ||||
| --- rp-pppoe-3.8/man/pppoe-start.8.orig	2007-03-20 18:50:01.000000000 +0100 | ||||
| +++ rp-pppoe-3.8/man/pppoe-start.8	2007-03-20 18:54:11.000000000 +0100 | ||||
| @@ -12,7 +12,7 @@ | ||||
|  .SH DESCRIPTION | ||||
|  \fBpppoe-start\fR is a shell script which starts the Roaring Penguin | ||||
|  user-space PPPoE client.  If you omit \fIconfig_file\fR, the default | ||||
| -file \fB/etc/ppp/pppoe.conf\fR is used.  If you supply | ||||
| +file \fB/etc/sysconfig/network-scripts/ifcfg-ppp0\fR is used.  If you supply | ||||
|  \fIinterface\fR and \fIuser\fR, then they override the Ethernet interface | ||||
|  and user-name settings in the configuration file. | ||||
|   | ||||
| --- rp-pppoe-3.8/man/pppoe-stop.8.orig	2007-03-20 18:57:07.000000000 +0100 | ||||
| +++ rp-pppoe-3.8/man/pppoe-stop.8	2007-03-20 18:57:20.000000000 +0100 | ||||
| @@ -10,7 +10,7 @@ | ||||
|  .SH DESCRIPTION | ||||
|  \fBpppoe-stop\fR is a shell script which stops the Roaring Penguin | ||||
|  user-space PPPoE client.  If you omit \fIconfig_file\fR, the default | ||||
| -file \fB/etc/ppp/pppoe.conf\fR is used. | ||||
| +file \fB/etc/sysconfig/network-scripts/ifcfg-ppp0\fR is used. | ||||
|   | ||||
|  .SH AUTHOR | ||||
|  \fBpppoe-stop\fR was written by David F. Skoll <dfs@roaringpenguin.com>. | ||||
| --- rp-pppoe-3.8/man/pppoe-status.8.orig	2007-03-20 18:56:42.000000000 +0100 | ||||
| +++ rp-pppoe-3.8/man/pppoe-status.8	2007-03-20 18:56:57.000000000 +0100 | ||||
| @@ -11,7 +11,7 @@ | ||||
|  \fBpppoe-status\fR is a shell script which checks the status of the | ||||
|  PPPoE link established by the Roaring Penguin user-space PPPoE client. | ||||
|  If you omit \fIconfig_file\fR, the default file | ||||
| -\fB/etc/ppp/pppoe.conf\fR is used. | ||||
| +\fB/etc/sysconfig/network-scripts/ifcfg-ppp0\fR is used. | ||||
|   | ||||
|  .SH AUTHOR | ||||
|  \fBpppoe-status\fR was written by David F. Skoll <dfs@roaringpenguin.com>. | ||||
							
								
								
									
										72
									
								
								rp-pppoe-manpages.patch
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										72
									
								
								rp-pppoe-manpages.patch
									
									
									
									
									
										Normal file
									
								
							| @@ -0,0 +1,72 @@ | ||||
| diff -up rp-pppoe-3.10/man/pppoe.8.than rp-pppoe-3.10/man/pppoe.8 | ||||
| --- rp-pppoe-3.10/man/pppoe.8.than	2016-06-03 15:51:56.587673656 +0200 | ||||
| +++ rp-pppoe-3.10/man/pppoe.8	2016-06-03 16:43:36.171245000 +0200 | ||||
| @@ -32,6 +32,10 @@ triggered.  The best way to do this is t | ||||
|  PPPoE timeout to be about four times the LCP echo interval. | ||||
|   | ||||
|  .TP | ||||
| +.B \-t \fItimeout\fR | ||||
| +The \fB\-t\fR option sets the initial timeout for discovery packets in seconds. | ||||
| + | ||||
| +.TP | ||||
|  .B \-D \fIfile_name\fR | ||||
|  The \fB\-D\fR option causes every packet to be dumped to the specified | ||||
|  \fIfile_name\fR.  This is intended for debugging only; it produces huge | ||||
| @@ -140,6 +144,10 @@ the peer you are dealing with uses non-s | ||||
|  ISP uses non-standard frame types, complain! | ||||
|   | ||||
|  .TP | ||||
| +.B \-F numfloods | ||||
| +The \fB\-F\fR option sets the discovery flood, only used for stress-testing. | ||||
| + | ||||
| +.TP | ||||
|  .B \-h | ||||
|  The \fB\-h\fR option causes \fBpppoe\fR to print usage information and | ||||
|  exit. | ||||
| diff -up rp-pppoe-3.10/man/pppoe-server.8.than rp-pppoe-3.10/man/pppoe-server.8 | ||||
| --- rp-pppoe-3.10/man/pppoe-server.8.than	2016-06-03 16:46:36.653467414 +0200 | ||||
| +++ rp-pppoe-3.10/man/pppoe-server.8	2016-06-03 17:03:14.838977026 +0200 | ||||
| @@ -58,12 +58,20 @@ PADI and PADR packets are ignored.  If y | ||||
|  then no limit is imposed on the number of sessions per peer MAC address. | ||||
|   | ||||
|  .TP | ||||
| +.B \-P | ||||
| +Check pool file for correctness and exit. | ||||
| + | ||||
| +.TP | ||||
|  .B \-s | ||||
|  This option is passed directly to \fBpppoe\fR; see \fBpppoe\fR(8) for | ||||
|  details.  In addition, it causes \fBpppd\fR to be invoked with the | ||||
|  \fIsync\fR option. | ||||
|   | ||||
|  .TP | ||||
| +.B \-l | ||||
| +Increment local IP address for each session. | ||||
| + | ||||
| +.TP | ||||
|  .B \-L \fIip\fR | ||||
|  Sets the local IP address.  This is passed to spawned \fBpppd\fR processes. | ||||
|  If not specified, the default is 10.0.0.1. | ||||
| @@ -123,6 +131,10 @@ handing out sessions in order, the sessi | ||||
|  unpredictable order. | ||||
|   | ||||
|  .TP | ||||
| +.B \-d | ||||
| +Debug session creation. | ||||
| + | ||||
| +.TP | ||||
|  .B \-u | ||||
|  Tells the server to invoke \fBpppd\fR with the \fIunit\fR option.  Note | ||||
|  that this option only works for \fBpppd\fR version 2.4.0 or newer. | ||||
| diff -up rp-pppoe-3.10/src/pppoe.c.than rp-pppoe-3.10/src/pppoe.c | ||||
| --- rp-pppoe-3.10/src/pppoe.c.than	2016-06-03 15:37:36.009035435 +0200 | ||||
| +++ rp-pppoe-3.10/src/pppoe.c	2016-06-03 16:45:05.547888671 +0200 | ||||
| @@ -379,6 +379,7 @@ usage(char const *argv0) | ||||
|  	    "   -k             -- Kill a session with PADT (requires -e)\n" | ||||
|  	    "   -d             -- Perform discovery, print session info and exit.\n" | ||||
|  	    "   -f disc:sess   -- Set Ethernet frame types (hex).\n" | ||||
| +	    "   -F numfloods   -- Set the discovery flood, only used for stress-testing.\n" | ||||
|  	    "   -h             -- Print usage information.\n\n" | ||||
|  	    "PPPoE Version %s, Copyright (C) 2001-2006 Roaring Penguin Software Inc.\n" | ||||
|  	    "PPPoE comes with ABSOLUTELY NO WARRANTY.\n" | ||||
| diff -up rp-pppoe-3.10/src/pppoe-server.c.than rp-pppoe-3.10/src/pppoe-server.c | ||||
							
								
								
									
										471
									
								
								rp-pppoe.spec
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										471
									
								
								rp-pppoe.spec
									
									
									
									
									
										Normal file
									
								
							| @@ -0,0 +1,471 @@ | ||||
| Summary: A PPP over Ethernet client (for xDSL support). | ||||
| Name: rp-pppoe | ||||
| Version: 3.14 | ||||
| Release: 7%{?dist} | ||||
| License: GPLv2+ | ||||
| Group: System Environment/Daemons | ||||
| Url: http://www.roaringpenguin.com/pppoe/ | ||||
| Source: http://www.roaringpenguin.com/files/download/rp-pppoe-%{version}.tar.gz | ||||
| Source1: pppoe-connect | ||||
| Source2: pppoe-setup | ||||
| Source3: pppoe-start | ||||
| Source4: pppoe-status | ||||
| Source5: pppoe-stop | ||||
| Source6: pppoe-server.service | ||||
|  | ||||
| Patch0: rp-pppoe-3.8-redhat.patch | ||||
| Patch1: rp-pppoe-3.11-ip-allocation.patch | ||||
| Patch2: rp-pppoe-manpages.patch | ||||
| Patch1000: rp-pppoe-3.14-redhat.lux.patch | ||||
| Patch1001: rp-pppoe-3.14-ip-allocation.lux.patch | ||||
| Patch1002: rp-pppoe-3.14-manpages.lux.patch | ||||
|  | ||||
| Buildroot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n) | ||||
|  | ||||
| Requires(post): initscripts fileutils | ||||
| Requires(postun): chkconfig initscripts fileutils | ||||
| Requires: ppp >= 2.4.2 | ||||
| Requires: initscripts >= 5.92 | ||||
| Requires: iproute >= 2.6 | ||||
| Requires: coreutils | ||||
| Requires: systemd-units >= 39-2 | ||||
| Requires: net-tools | ||||
| Requires(post): systemd-units | ||||
| Requires(preun): systemd-units | ||||
| Requires(postun): systemd-units | ||||
| Requires(post): systemd-sysv | ||||
| Conflicts: filesystem < 3 | ||||
|  | ||||
| BuildRequires: libtool | ||||
| BuildRequires: autoconf | ||||
| BuildRequires: automake | ||||
| BuildRequires: coreutils | ||||
| BuildRequires: ppp | ||||
| BuildRequires: systemd-units >= 39-2 | ||||
|  | ||||
| ExcludeArch: s390 s390x | ||||
|  | ||||
| %description | ||||
| PPPoE (Point-to-Point Protocol over Ethernet) is a protocol used by | ||||
| many ADSL Internet Service Providers. This package contains the | ||||
| Roaring Penguin PPPoE client, a user-mode program that does not | ||||
| require any kernel modifications. It is fully compliant with RFC 2516, | ||||
| the official PPPoE specification. | ||||
|  | ||||
| %prep | ||||
| %setup -q | ||||
| %patch1000 -p1 -b .config | ||||
| %patch1001 -p1 -b .ip-allocation | ||||
| %patch1002 -p1 | ||||
|  | ||||
| %build | ||||
| cd src | ||||
| autoconf | ||||
| export CFLAGS="$RPM_OPT_FLAGS -D_GNU_SOURCE -fno-strict-aliasing" | ||||
| %configure | ||||
| make | ||||
|  | ||||
| %install | ||||
| rm -rf %{buildroot} | ||||
|  | ||||
| mkdir -p %{buildroot}%{_sbindir} %{buildroot}%{_unitdir} | ||||
|  | ||||
| make -C src install DESTDIR=%{buildroot} | ||||
|  | ||||
| install -m 0755 %{SOURCE1} %{buildroot}%{_sbindir} | ||||
| install -m 0755 %{SOURCE2} %{buildroot}%{_sbindir} | ||||
| install -m 0755 %{SOURCE3} %{buildroot}%{_sbindir} | ||||
| install -m 0755 %{SOURCE4} %{buildroot}%{_sbindir} | ||||
| install -m 0755 %{SOURCE5} %{buildroot}%{_sbindir} | ||||
| install -m 0644 %{SOURCE6} %{buildroot}%{_unitdir}/pppoe-server.service | ||||
|  | ||||
| ln -sf pppoe-stop %{buildroot}%{_sbindir}/adsl-stop | ||||
| ln -sf pppoe-start %{buildroot}%{_sbindir}/adsl-start | ||||
| ln -fs pppoe-start.8 %{buildroot}%{_mandir}/man8/adsl-start.8 | ||||
| ln -fs pppoe-stop.8 %{buildroot}%{_mandir}/man8/adsl-stop.8 | ||||
|  | ||||
| rm -rf %{buildroot}/etc/ppp/pppoe.conf \ | ||||
|        %{buildroot}/etc/rc.d/init.d/pppoe \ | ||||
|        %{buildroot}/usr/share/doc \ | ||||
|        %{buildroot}%{_sysconfdir}/ppp/plugins | ||||
|  | ||||
| %clean | ||||
| rm -rf %{buildroot} | ||||
|  | ||||
| %preun | ||||
| if [ "$1" = "0" ]; then | ||||
|    # Package removal, not upgrade | ||||
|    /bin/systemctl disable pppoe-server.service > /dev/null 2>&1 || : | ||||
|    /bin/systemctl stop pppoe-server.service > /dev/null 2>&1 || : | ||||
| fi | ||||
|  | ||||
| %postun | ||||
| /bin/systemctl daemon-reload >/dev/null 2>&1 || : | ||||
| if [ $1 -ge 1 ] ; then | ||||
|     # Package upgrade, not uninstall | ||||
|     /bin/systemctl try-restart pppoe-server.service >/dev/null 2>&1 || : | ||||
| fi | ||||
|  | ||||
| %triggerun -- %{name} < 3.10-9 | ||||
| # Run these because the SysV package being removed won't do them | ||||
| /sbin/chkconfig --del pppoe-server >/dev/null 2>&1 || : | ||||
| /bin/systemctl try-restart pppoe-server.service >/dev/null 2>&1 || : | ||||
|  | ||||
|  | ||||
| %files | ||||
| %defattr(-,root,root) | ||||
| %doc doc/LICENSE scripts/pppoe-connect scripts/pppoe-setup scripts/pppoe-init | ||||
| %doc scripts/pppoe-start scripts/pppoe-status scripts/pppoe-stop | ||||
| %doc configs | ||||
| %config(noreplace) %{_sysconfdir}/ppp/pppoe-server-options | ||||
| %config(noreplace) %{_sysconfdir}/ppp/firewall* | ||||
| %{_unitdir}/pppoe-server.service | ||||
| %{_sbindir}/* | ||||
| %{_mandir}/man?/* | ||||
|  | ||||
| %changelog | ||||
| * Wed Feb 15 2017 Than Ngo <than@redhat.com> - 3.11-7 | ||||
| - Resolves: bz#1422019, pppoe-server.service is marked executable | ||||
|  | ||||
| * Fri Jun 03 2016 Than Ngo <than@redhat.com> - 3.11-6 | ||||
| - Resolves: bz#948950, fix manpage issues | ||||
|  | ||||
| * Fri Dec 27 2013 Daniel Mach <dmach@redhat.com> - 3.11-5 | ||||
| - Mass rebuild 2013-12-27 | ||||
|  | ||||
| * Mon May 13 2013 Than Ngo <than@redhat.com> - 3.11-4 | ||||
| - bz#961529, add Requirement on net-tools | ||||
|  | ||||
| * Thu Apr 25 2013 Than Ngo <than@redhat.com> - 3.11-3 | ||||
| - build with -fno-strict-aliasing | ||||
|  | ||||
| * Thu Feb 14 2013 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 3.11-2 | ||||
| - Rebuilt for https://fedoraproject.org/wiki/Fedora_19_Mass_Rebuild | ||||
|  | ||||
| * Mon Aug 20 2012 Than Ngo <than@redhat.com> - 3.11-1 | ||||
| - 3.11 | ||||
| - bz#540763, add IP allocation by pppd ability to pppoe-server | ||||
| - bz#808676, add missing %% symbol for triggerun | ||||
|  | ||||
| * Sat Jul 21 2012 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 3.10-13 | ||||
| - Rebuilt for https://fedoraproject.org/wiki/Fedora_18_Mass_Rebuild | ||||
|  | ||||
| * Mon Mar 19 2012 Than Ngo <than@redhat.com> - 3.10-12 | ||||
| - fix bz#804396, add missing [Unit] section | ||||
|  | ||||
| * Wed Jan 25 2012 Harald Hoyer <harald@redhat.com> 3.10-11 | ||||
| - install everything in /usr | ||||
|   https://fedoraproject.org/wiki/Features/UsrMove | ||||
|  | ||||
| * Sat Jan 14 2012 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 3.10-10 | ||||
| - Rebuilt for https://fedoraproject.org/wiki/Fedora_17_Mass_Rebuild | ||||
|  | ||||
| * Tue Jul 05 2011 Than Ngo <than@redhat.com> - 3.10-9 | ||||
| - bz#697664, native systemd file | ||||
|  | ||||
| * Wed Feb 09 2011 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 3.10-8 | ||||
| - Rebuilt for https://fedoraproject.org/wiki/Fedora_15_Mass_Rebuild | ||||
|  | ||||
| * Mon Dec 07 2009 Than Ngo <than@redhat.com> - 3.10-7 | ||||
| - fix url | ||||
|  | ||||
| * Wed Sep 09 2009 Than Ngo <than@redhat.com> - 3.10-6 | ||||
| - rebuilt | ||||
|  | ||||
| * Wed Sep 09 2009 Than Ngo <than@redhat.com> - 3.10-5 | ||||
| - wrong path to initscript bz#522010 | ||||
| - add remove services in %postun/%preun | ||||
|  | ||||
| * Mon Sep 07 2009 Than Ngo <than@redhat.com> - 3.10-4 | ||||
| - add feature, save and restore all information about default routes bz#191242 | ||||
| - add startup script for pppoe-server bz#507123 | ||||
|  | ||||
| * Sun Jul 26 2009 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 3.10-3 | ||||
| - Rebuilt for https://fedoraproject.org/wiki/Fedora_12_Mass_Rebuild | ||||
|  | ||||
| * Wed Feb 25 2009 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 3.10-2 | ||||
| - Rebuilt for https://fedoraproject.org/wiki/Fedora_11_Mass_Rebuild | ||||
|  | ||||
| * Tue Nov 11 2008 Than Ngo <than@redhat.com> 3.10-1 | ||||
| - 3.10 | ||||
|  | ||||
| * Wed Sep  3 2008 Tom "spot" Callaway <tcallawa@redhat.com> 3.8-5 | ||||
| - fix license tag | ||||
|  | ||||
| * Thu Apr 10 2008 Karsten Hopp <karsten@redhat.com> 3.8-4 | ||||
| - Build with $RPM_OPT_FLAGS (#249978) (Ville Skyttä) | ||||
|  | ||||
| * Fri Feb 15 2008 Than Ngo <than@redhat.com> 3.8-3 | ||||
| - rebuild | ||||
|  | ||||
| * Tue Mar 20 2007 Than Ngo <than@redhat.com> - 3.8-2.fc7 | ||||
| - setting DEBUG for adsl-start causes adsl-connect to exit, #195828 | ||||
|  | ||||
| * Tue Mar 20 2007 Than Ngo <than@redhat.com> - 3.8-1.fc7 | ||||
| - update to 3.8 | ||||
|  | ||||
| * Wed Jul 12 2006 Jesse Keating <jkeating@redhat.com> - 3.5-32.1 | ||||
| - rebuild | ||||
|  | ||||
| * Sat Jun 10 2006 Than Ngo <than@redhat.com> 3.5-32 | ||||
| - fix build problem in mock | ||||
|  | ||||
| * Wed Feb 15 2006 Than Ngo <than@redhat.com> 3.5-31 | ||||
| - apply patch to use mktemp | ||||
|  | ||||
| * Fri Feb 10 2006 Jesse Keating <jkeating@redhat.com> - 3.5-30.2.1 | ||||
| - bump again for double-long bug on ppc(64) | ||||
|  | ||||
| * Tue Feb 07 2006 Jesse Keating <jkeating@redhat.com> - 3.5-30.2 | ||||
| - rebuilt for new gcc4.1 snapshot and glibc changes | ||||
|  | ||||
| * Fri Dec 09 2005 Jesse Keating <jkeating@redhat.com> | ||||
| - rebuilt | ||||
|  | ||||
| * Mon Aug 15 2005 Than Ngo <than@redhat.com> 3.5-30 | ||||
| - defaultroute should not overridden #152014 | ||||
|  | ||||
| * Mon Jul 04 2005 Than Ngo <than@redhat.com> 3.5-29  | ||||
| - fix broken dependencies  | ||||
|  | ||||
| * Mon Jun 13 2005 Than Ngo <than@redhat.com> 3.5-28 | ||||
| - use iproute2 instead of old ifconfig #134816 | ||||
|  | ||||
| * Mon Mar 07 2005 Than Ngo <than@redhat.com> 3.5-27 | ||||
| - rebuilt | ||||
|  | ||||
| * Sat Jan 22 2005 Than Ngo <than@redhat.com> 3.5-26 | ||||
| - rename config files #145255 | ||||
|  | ||||
| * Wed Jan 19 2005 David Woodhouse <dwmw2@redhat.com> 3.5-25 | ||||
| - Kill br2684ctl after ifdown if we started it | ||||
|  | ||||
| * Wed Jan 19 2005 David Woodhouse <dwmw2@redhat.com> 3.5-24 | ||||
| - Add support for RFC2684 Ethernet-over-ATM (for PPPoE-over-ATM) | ||||
|  | ||||
| * Mon Nov 22 2004 Than Ngo <than@redhat.com> 3.5-23 | ||||
| - fix typo in adsl-setup #140287 | ||||
|  | ||||
| * Fri Oct 15 2004 Than Ngo <than@redhat.com> 3.5-22 | ||||
| - Fix ip conflict in dsl connect, #135012 | ||||
|  | ||||
| * Thu Oct 07 2004 David Woodhouse <dwmw2@redhat.com> 3.5-21 | ||||
| - Fix ordering of VCI and VPI in pppoatm address. | ||||
|  | ||||
| * Thu Oct 07 2004 David Woodhouse <dwmw2@redhat.com> 3.5-20 | ||||
| - Add support for static IP with demand option. | ||||
| - Add support for using PPP over ATM plugin. | ||||
|  | ||||
| * Thu Oct 07 2004 Than Ngo <than@redhat.com> 3.5-19 | ||||
| - fix typo bug in adsl connect | ||||
| - remove unused rp-pppoe plugin, it's now included in new ppppd | ||||
|  | ||||
| * Wed Oct 06 2004 Than Ngo <than@redhat.com> 3.5-18 | ||||
| - fix adsl connect for using MTU/MRU | ||||
|  | ||||
| * Thu Sep 30 2004 Than Ngo <than@redhat.com> 3.5-17 | ||||
| - fix idle parameter in asdl connect | ||||
|  | ||||
| * Mon Aug 02 2004 Than Ngo <than@redhat.com> 3.5-16 | ||||
| - use iptables instead ipchains, thanks to Robert Scheck | ||||
|  | ||||
| * Tue Jun 15 2004 Elliot Lee <sopwith@redhat.com> | ||||
| - rebuilt | ||||
|  | ||||
| * Thu Apr 01 2004 Than Ngo <than@redhat.com> 3.5-14 | ||||
| - fixed typo  | ||||
|  | ||||
| * Tue Mar 30 2004 Than Ngo <than@redhat.com> 3.5-13 | ||||
| - fixed reconnect problem | ||||
|  | ||||
| * Mon Mar 29 2004 Than Ngo <than@redhat.com> 3.5-12 | ||||
| - fixed wrong idle parameter, #119280 | ||||
|  | ||||
| * Thu Mar 04 2004 Than Ngo <than@redhat.com> 3.5-11 | ||||
| - fixed default route problem, #114875 | ||||
| - fixed restart issue, #100610 | ||||
| - fixed a bug in adsl status | ||||
|  | ||||
| * Fri Feb 13 2004 Elliot Lee <sopwith@redhat.com> | ||||
| - rebuilt | ||||
|  | ||||
| * Mon Nov 10 2003 Than Ngo <than@redhat.com> 3.5-9 | ||||
| - better fix for nickename issue | ||||
|  | ||||
| * Wed Oct 29 2003 Than Ngo <than@redhat.com> 3.5-8 | ||||
| - fix a bug in connect script | ||||
|  | ||||
| * Mon Oct 27 2003 Than Ngo <than@redhat.com> 3.5-7 | ||||
| - fix nickename issue | ||||
|  | ||||
| * Wed Jun 04 2003 Elliot Lee <sopwith@redhat.com> | ||||
| - rebuilt | ||||
|  | ||||
| * Tue Jun  3 2003 Than Ngo <than@redhat.com> 3.5-5 | ||||
| - add correct PPOE_TIMEOUT/LCP_INTERVAL bug #82630 | ||||
|  | ||||
| * Sun May 04 2003 Florian La Roche <Florian.LaRoche@redhat.de> | ||||
| - fix initdir in triggerpostun | ||||
|  | ||||
| * Wed Jan 22 2003 Tim Powers <timp@redhat.com> | ||||
| - rebuilt | ||||
|  | ||||
| * Fri Nov 29 2002 Than Ngo <than@redhat.com> 3.5-1 | ||||
| - update to 3.5 | ||||
|  | ||||
| * Thu Nov  7 2002 Than Ngo <than@redhat.com> 3.4-8 | ||||
| - unpackaged files issue | ||||
|  | ||||
| * Fri Jun 21 2002 Tim Powers <timp@redhat.com> | ||||
| - automated rebuild | ||||
|  | ||||
| * Thu Jun 20 2002 Than Ngo <than@redhat.com> 3.4-5 | ||||
| - Don't forcibly strip binaries | ||||
|  | ||||
| * Sun Jun 09 2002 Than Ngo <than@redhat.com> 3.4-4 | ||||
| - Fix up creation of first device (#64773) | ||||
|  | ||||
| * Fri Jun 07 2002 Than Ngo <than@redhat.com> 3.4-3 | ||||
| - set correct default value for PPPoE timeout (bug #64903) | ||||
|  | ||||
| * Sun May 26 2002 Tim Powers <timp@redhat.com> | ||||
| - automated rebuild | ||||
|  | ||||
| * Thu May 23 2002 Harald Hoyer <harald@redhat.de> 3.4-1 | ||||
| - 3.4 | ||||
| - added kernel plugin | ||||
|  | ||||
| * Sun Apr 14 2002 Than Ngo <than@redhat.com> 3.3-7 | ||||
| - add fix for neat-control | ||||
|  | ||||
| * Sat Feb 23 2002 Than Ngo <than@redhat.com> 3.3-6 | ||||
| - fix a bug in adsl-stop (#60138) | ||||
|  | ||||
| * Tue Feb 12 2002 Bernhard Rosenkraenzer <bero@redhat.com> 3.3-5 | ||||
| - Fix up creation of first device (#59236) | ||||
|  | ||||
| * Wed Jan 09 2002 Tim Powers <timp@redhat.com> | ||||
| - automated rebuild | ||||
|  | ||||
| * Sun Dec 16 2001 Than Ngo <than@redhat.com> 3.3-3 | ||||
| - fix bugs #57070, #55627, #55140 | ||||
| - add man pages, Docs and example scripts | ||||
|  | ||||
| * Mon Nov 05 2001 Than Ngo <than@redhat.com> 3.3-2 | ||||
| - fix a bug in adsl-connect | ||||
|  | ||||
| * Wed Sep 19 2001 Than Ngo <than@redhat.com> 3.3-1 | ||||
| - update to 3.3 (bug #53697) | ||||
|  | ||||
| * Thu Aug 16 2001 Than Ngo <than@redhat.com> 3.2-4 | ||||
| - don't print messages as default | ||||
|  | ||||
| * Wed Aug  8 2001 Than Ngo <than@redhat.com> | ||||
| - fix softlinks | ||||
|  | ||||
| * Sun Jul 22 2001 Than Ngo <than@redhat.com> | ||||
| - update to 3.2 | ||||
|  | ||||
| * Thu Jul 19 2001 Than Ngo <than@redhat.com> 3.0-5 | ||||
| - fix bug in trigger | ||||
|  | ||||
| * Fri Jun 22 2001 Than Ngo <than@redhat.com> | ||||
| - Copyright -> License | ||||
| - fix activate ethernet device problem | ||||
| - get rid of pppoe initscript, use ifup/ifdown | ||||
|   to activate/shutdown xDSL connection | ||||
| - convert old pppoe config format into new format | ||||
| - remove adsl-setup, Users have to use netconf to setup xDSL connection | ||||
| - excludearch s390 | ||||
|  | ||||
| * Mon May 14 2001 Than Ngo <than@redhat.com> | ||||
| - clean PID files when connection fails (Bug #40349) | ||||
| - fix order of pppoe script (Bug #40454) | ||||
|  | ||||
| * Wed May 02 2001 Than Ngo <than@redhat.com> | ||||
| - fixed a firewall bug in adsl-setup (Bug #38550) | ||||
|  | ||||
| * Sun Apr 22 2001 Than Ngo <than@redhat.com> | ||||
| - update to 3.0 (bug #34075) | ||||
|  | ||||
| * Thu Mar 15 2001 Than Ngo <than@redhat.com> | ||||
| - fix BOOT enviroment again, it should work fine now  | ||||
|  | ||||
| * Wed Mar 14 2001 Than Ngo <than@redhat.com> | ||||
| - fix bug in adsl-setup (DEVICE enviroment) | ||||
|  | ||||
| * Thu Feb 08 2001 Than Ngo <than@redhat.com> | ||||
| - fixed a problem in startup (Bug #26454) | ||||
| - fixed i18n in initscript (Bug #26540) | ||||
|  | ||||
| * Sat Feb 03 2001 Than Ngo <than@redhat.com> | ||||
| - updated to 2.6 | ||||
| - some fixes in pppoe script | ||||
|  | ||||
| * Fri Feb 02 2001 Than Ngo <than@redhat.com> | ||||
| - fixed starting pppoe service at boot time. (Bug #25494) | ||||
|  | ||||
| * Sun Jan 28 2001 Than Ngo <than@redhat.com> | ||||
| - fixed so that pppoe script does not kill adsl connection when | ||||
|   the runlevel is changed.  | ||||
| - remove excludearch ia64 | ||||
|  | ||||
| * Tue Jan 23 2001 Than Ngo <than@redhat.com> | ||||
| - hacked for using USEPEERDNS | ||||
|  | ||||
| * Mon Dec 11 2000 Than Ngo <than@redhat.com> | ||||
| - updated to 2.5, it fixes a denial-of-service vulnerability | ||||
|  | ||||
| * Tue Aug 08 2000 Than Ngo <than@redhat.de> | ||||
| - fix german configuration HOWTO to T-DSL | ||||
|  | ||||
| * Mon Aug 07 2000 Than Ngo <than@redhat.de> | ||||
| - fixes for starting pppd under /usr/sbin | ||||
| - added german configuration HOWTO to T-DSL | ||||
|  | ||||
| * Tue Aug 01 2000 Than Ngo <than@redhat.de> | ||||
| - update to 2.2 | ||||
|  | ||||
| * Fri Jul 28 2000 Than Ngo <than@redhat.de> | ||||
| - fixed initscripts so that condrestart doesn't return 1 when the test fails | ||||
|  | ||||
| * Thu Jul 27 2000 Than Ngo <than@redhat.de> | ||||
| - update to 2.1 | ||||
| - don't detect pppd for building | ||||
|  | ||||
| * Thu Jul 27 2000 Than Ngo <than@redhat.de> | ||||
| - rename the rp-pppoe startup script (Bug #14734) | ||||
|  | ||||
| * Wed Jul 26 2000 Bill Nottingham <notting@redhat.com> | ||||
| - don't run by default; it hangs if not configured | ||||
|  | ||||
| * Tue Jul 25 2000 Bill Nottingham <notting@redhat.com> | ||||
| - prereq /etc/init.d (it's referenced in the initscript) | ||||
|  | ||||
| * Tue Jul 18 2000 Than Ngo <than@redhat.de> | ||||
| - inits back to rc.d/init.d, using service to fire them up | ||||
|  | ||||
| * Wed Jul 12 2000 Prospector <bugzilla@redhat.com> | ||||
| - automatic rebuild | ||||
|  | ||||
| * Sat Jul 08 2000 Than Ngo <than@redhat.de> | ||||
| - add Prereq: /etc/init.d | ||||
|  | ||||
| * Fri Jun 30 2000 Than Ngo <than@redhat.de> | ||||
| - turned off deamon by default | ||||
|  | ||||
| * Tue Jun 27 2000 Than Ngo <than@redhat.de> | ||||
| - don't prereq, only require initscripts | ||||
|  | ||||
| * Mon Jun 26 2000 Than Ngo <than@redhat.de> | ||||
| - /etc/rc.d/init.d -> /etc/init.d | ||||
| - add condrestart directive | ||||
| - fix post/preun/postun scripts | ||||
| - prereq initscripts >= 5.20 | ||||
|  | ||||
| * Sun Jun 18 2000 Than Ngo <than@redhat.de> | ||||
| - use RPM macros | ||||
| - rebuilt in the new build environment | ||||
|  | ||||
| * Wed May 31 2000 Than Ngo <than@redhat.de>  | ||||
| - adopted for Winston. | ||||
		Reference in New Issue
	
	Block a user