PEPA Version 1.9, a Packet Driver
for xDSL with PPPoverEthernet access

Oct. 2001
Copyright Herbert Hanewinkel, Neuried, Germany

Overview

PEPA is an ethernet-type (class=1) packet-driver for xDSL with PPPoverEthernet (RFC2516) access. PEPA was developed for use with ka9q or PCROUTE as a low cost LAN xDSL Router.

PEPA hooks itself on top of an ethernet packet driver. Because of this, PEPA is completely hardware independent. PEPA is implemented as a MS-DOS TSR program.
PEPA supports PPP with PAP or CHAP authentication and DNS redirection. Additionally PEPAM.EXE supports IP-masquerading. Idle timeout and Shorthold mode are available for lines charged by connection time.
PEPA has been tested with T-DSL, the xDSL access of Deutsche Telekom.

Registration

PEPA is Shareware
PEPA, as it is provided, is a demo version. To make use of the full capabilities of PEPA you have to register PEPA. Please read the file ORDER.TXT (German version: BESTELL.TXT) for details.
As long as you have NOT registered PEPA you may test PEPA for 30 days without a registration code. In this case PEPA will stop forwarding data 30 min after startup.

Disclaimer

The program and the documentation is
  Copyright (C) 1999-2001 by Herbert Hanewinkel, Neuried
  All Rights Reserved.

The program is provided as shareware with the following limitations:
This program is copyrighted and it is not in the public domain. It may not be distributed for profit or included in any CD-ROM or diskette software collection without permission. The program is not to be resold or distributed for sale with other programs which are for sale without my express written permission.
There is no warranty or claim of fitness or reliability. The program is distributed AS IS, and as such the author shall NOT be held liable for any loss of data, down time, loss of revenue or any other direct or indirect damage or claims caused by this program.

Installation

To use PEPA you have to set up a configuration file with your PPP configuration as described below. The default name for this file is PEPA.INI.
PEPA.EXE accepts the following arguments:
(Parameters in [ ] are optional, if not given a default is used)

PEPA RegCode [PacketInterrupt [ConfigFile]]

RegCode is your personal registration code you will receive after registration of PEPA. As long as you have NOT registered PEPA you may test PEPA using a ? in place of the registration code. In this case PEPA will stop forwarding data 30 min after startup.

PacketInterrupt defines the software interrupt for the Packet Driver application. The value has to be in the range from 0x60 to 0x80. If not specified, the default of 0x60 is used.

ConfigFile specifies the name of the PEPA configuration file. If the name is not given, it defaults to "PEPA.INI". The configuration file is a readable text file. How to set up a configuration file and a complete reference of all configuration options is described in the chapter Configuration

Deinstallation

PEPA can be unloaded using TERMIN.EXE from the Clarkson/Crynwr Packet Driver collection.

Configuration

Structure of the configuration file

Global options:

-m my-ip-address
defines a static local IP address for use in PPP negotiation and/or use with BOOTP, DHCP, RARP and NAT. Setting the local IP address to 0.0.0.0 has a special meaning. In this case a received dynamic IP address will be kept until the program is terminated or the IP address is manually set to 0.0.0.0 again.
default: no address defined
-n nameserver-ip-address
defines one or two IP addresses of name servers for local use. Requests to these addresses are redirected to the DNS addresses received via PPP.
default: no address defined
-n ip-address,full-qualified-domain-name
creates an entry for DNS name interception to resolve the name locally.
-a
disables the auto dialer. If not selected the driver will dial-on-demand.
default: auto dialer enabled
-b
The driver will respond to BOOTP / DHCP requests, if a non zero IP address was configured through the -m Option or an IP address was received via PPP from a link. This option disables responding to BOOTP or DHCP requests.
default: BOOTP/DHCP response enabled
-k setup[,sleep]
specifies the set-up time in seconds. The system will wait "setup" seconds for a connection to come up. If the connection does not reach the active state during this time, the channel is reset. The "sleep" parameter allows you to modify the delay between a disconnect and the next dial request.
In shorthold mode a connection is closed down "save" seconds before the end of a unit is estimated.
defaults: 15,5
-l interval[c]
if "interval" is non zero and a connection is up, a statistic message will be displayed every "interval"-seconds. "interval" should be a multiple of 8, otherwise it is internally rounded up to the next multiple of 8.
Appending a "c" to interval will force immediate log (on the screen or syslog host) of every charge message received from the CAPI software.
-r log-ip,my-ip
remote logging on a UNIX host with a syslogd. Using ISPA with IP-Router software this option can be used to log all connection related messages on a UNIX host with a Berkeley syslogd.
log-ip defines the IP address of the UNIX host.
my-ip defines the source IP address of syslog messages sent by the programs (a packet driver can not automatically retrieve the information from the application layer).
Syslog-messages are sent with the characteristics "local0.info".
-g n
the program allocates 16 buffers of 1536 Bytes each for an outgoing packet queue. With this option the allocated bufferspace can be set to n buffers.
default: 16
-i vector
specifies the software interrupt for communication with the ethernet packet driver.
default: PEPA software interrupt + 1
-o
the drivers use direct screen output to avoid BIOS output delays.
if the automatic selection of the video-RAM fails, this option can be used to force screen output to the monochrome video-RAM at B000:0.
-q
suppresses any message output on the screen.
-v
the driver tries to allocate buffers in upper memory (UMB). This option disables this feature and the program will use conventional memory at the top of the DOS memory.
-w
Display activity, state and charge information in the upper right corner of the screen. The display has the following layout:

/xx\yyAnnnn

The symobls mark from left to right:

  • outgoing data, the symbol rotates for every transmitted packet
  • outgoing data rate in kBytes/sec
  • incoming data, the symbol rotates for every received packet
  • incoming data rate in kBytes/sec
  • state of connection
  • accumulated charge units for open connections.
  • State symbols:

  • _ = free,
  • A = PPPoE connection up
  • L = LCP configuration up
  • I = PAP/CHAP configuration up, IPCP configuration started,
  • P = PPP connection up
  • -x TCPport-range,IP-address
    PEPAM.EXE only
    defines static TCP port mapping entries for IP masquerading. To protect all local ports from incoming access (firewall), redirect the desired port(s) to an IP address of 0.0.0.0.
    default: requests to well known ports are forwarded to the local ip address.

    Use -x without arguments to disable port mapping in PEPAM.

    -u UDPport-range,IP-address
    PEPAM.EXE only
    defines static UDP port mapping entries for IP masquerading. To protect all local ports from incoming access (firewall), redirect the desired port(s) to an IP address of 0.0.0.0.
    default: requests to well known ports are forwarded to the local ip address.
    -z days
    forces an automatic restart of the PC after "days"-days, as soon as the system becomes idle. "days" should be in the range from 1 to 255.
    default: disabled
    -d
    enables automatic disconnect on release with the termination of the last Packet Driver application.
    default: don't disconnect on release
    -p vector
    specifies the software interrupt for communication with the Packet Driver application software.
    default: 0x60

    Service options:

    -p
    Point-to-Point protocol using default PPP-parameters. Of the possible upper layer protocols, only IP is supported at this time. The following PPP options are requested from the remote site:

    LCP MRU option with values greater or equal to 1500.
    LCP protocol field compression
    LCP address and control field compression.
    IPCP IP-ADDRESS.
    IPCP DNS-ADDRESS.
    IPCP TCP-header compression

    The PPP authentication methods PPP PAP and CHAP are supported in both directions.

    -n userid,password
    -n userid'password
    With the -n option an userid/password combination can be specified for a remote site. The authentication string is send only, if the remote site requests Password authentication during PPP option negotiation. Following a ' a password encryted with ENCPASS is expected.

    Attention: A comma or space in the userid string is not supported.

    -g userid,password
    -g userid'password
    With the -g option a local id/password can be defined for each peer.Defines a local userid/password combination. Incoming PPP connections are accepted only if the remote site sends this userid/password combination. Following a ' a password encryted with ENCPASS is expected.
    More than one -g option can be specified per entry to allow more than a single userid/password combination.

    Attention: A comma or space in the userid string is not supported.

    -c
    The default authentication protocol is PAP. Authentication via CHAP can be selected with this option.
    -z
    Reset the IP address for every connection. With the IPCP IP address option the last IP address will be requested as default. With this option the IPCP request always asks for a new IP address.
    -v
    van Jacobson TCP header compression.
    -e
    send lcp echo requests once per second to check the link. If there is no response to 10 consecutive requests the connection is closed.
    -t max-idle[,min-idle]
    an idle connection will be disconnected after "max-idle"-seconds. Setting "max-idle" to zero disables shutdown of idle connections.
    min-idle enables the use of adaptive timeout. Specifying a "min-idle" value lower than "max-idle", a connection will be hold at least "min-idle" seconds, it will be closed down shortly before the next charge unit is exceeded or max-idle expires. In this case the max-idle value is used as the length of a charge unit.
    default: max-idle: 300 seconds, min-idle: disabled
    -k
    Don't reset the disconnect timer on sending broadcast packets and some NetBios-Requests.
    Don't open a connection by broadcast packets and NetBios-Requests.
    Enable this option if your IP software should announce routing information when the link is up. Setting this option will allow the link to time out even if broadcast packets are sent. This option also suppresses unneccssary NetBios-Requests.
    -r
    Don't reset the disconnect timer on received packets.
    If a peer sends IP packets on a regular basis (e.g. RIP routing information packets), these packets will normally keep a line up. The option allows a link to time out even if packets are received.
    -u
    Declares a link as a broadcast link. Broadcast packets are sent over this link.
    -o [ip-address]
    Enables NAT (Network Address Translation, RFC 1631) and IP-Masquerading.
    With NAT enabled, a received dynamic (or the optional specified fixed) IP address replaces local IP-addresses in outgoing packets.
    -q
    disable NETBIOS.

    Example

    PEPA.INI:

    -i 0x65                       # ethernet PD at 0x65
    -w                            # activity display on DOS screen
    -n 192.168.2.1                # locally (on local clients) used DNS nameserver
    -n 192.168.2.2                #  addresses redirected to dyn. assigned addresses
    #
    0.0.0.0 -p -nheha,password    # PPP with remote authentication
                    -k -q         # supress Broadcasts and disable NETBIOS
                    -o            # NAT
                    -t60,20       # unit length 60s, shorthold of 20s

    KA9Q AUTOEXEC.NET:

    hostname gate
    ip address 192.168.2.1
    #
    # PPPoE has a maximum MTU of 1492 !!!
    #
    attach packet 0x60 tdsl 10 1492
    attach packet 0x65 lan  10 1492
    ifconfig tdsl ipaddr gate netmask 0xffffff00
    ifconfig lan  ipaddr 192.168.1.1 netmask 0xffffff00 broadcast 192.168.1.255
    #
    route add default tdsl
    #

    Ethernet characteristics

    PEPA works as an ethernet type Packet Driver. The ethernet address of PEPA is defined as: 00-00-0xFB-0xAA-00-<pkt-int>. <pkt-int> is replaced by the software interrupt number used for accessing PEPA.

    With PKTADDR.EXE from the Clarkson/Crynwr Packet Driver collection the ethernet address can be changed to any other desired value.

    Availability

    The latest version of PEPA is available on http://www.hanewin.de.

    Support

    Please mail comments, questions, problems to mail@hanewin.de.

    Warranty

    There is absolutely NO WARRANTY, expressed or implied with this software. If you choose to use this software, you assume all risk.