Commit Graph

229 Commits

Author SHA1 Message Date
Brian Somers 62d50f2278 Mention ``alias enable no'', not ``alias enable off''. 1999-08-18 15:35:54 +00:00
Brian Somers dade2407e6 Implement a minimum idle time value as an optional second argument
to ``set timeout''.
This is useful for situations where your minimum call charge is (say)
5 minutes (like mine is)
1999-08-17 17:22:46 +00:00
Brian Somers eb6e5e05f9 Add ISDN support via isdnd & i4b. This requires version
0.81.1 of the i4b code - namely support of the I4B_VR_REQ
ioctl via the i4brbchX device.

Ppp controls the phone number, but idle timers and
SYNC/RAW decisions are still made by isdnd (in isdnd.rc).

This involves a new datalink state machine phase.  The
``wait for carrier'' phase happens after dialing but
before logging in.  The whole dial state should really
be abstracted so that each device type can deal with it
in its own way (thinking about PPPoE) - but that'll have
to wait.

The ``set cd'' symantics remain the same for tty devices,
but we now delay until we either get CD or timeout waiting
(at which time we drop the link if we require CD).

For i4b devices we always insist on carrier.

Thanks to hm@ for his help, and especially for pointing out
that I *don't* need to re-implement isdnd (that was a huge
waste of time !) :-]
1999-08-06 20:04:08 +00:00
Brian Somers ab2de065b2 o Obsolete the undocumented ``set weight'' command.
o If we're using RADIUS and the RADIUS mtu is less than our
  peers mru/mrru, reduce our mtu to this value for NetBSD too.
o Make struct throughput's sample period dynamic and tweak the ppp
  version number to reflect the extra stuff being passed through
  the local domain socket as a result (MP mode).
o Measure the current throughput based on the number of samples actually
  taken rather than on the full sample period.
o Keep the throughput statisics persistent while being passed to
  another ppp invocation through the local domain socket.
o When showing throughput statistics after the timer has stopped, use
  the stopped time for overall calculations, not the current time.
  Also show the stopped time and how long the current throughput has
  been sampled for.
o Use time() consistently in throughput.c
o Tighten up the ``show bundle'' output.
o Introduce the ``set bandwidth'' command.
o Rewrite the ``set autoload'' command.  It now takes three arguments
  and works based on a rolling bundle throughput average compared against
  the theoretical bundle bandwidth over a given period (read: it's now
  functional).
1999-08-05 10:32:16 +00:00
Brian Somers 93a25fb90a Reorganise ppp's usage to avoid some mandoc limitations.
Suggested by: wollman
1999-08-03 16:14:38 +00:00
Brian Somers badaf18d92 Mention that ospf is a possible filter protocol. 1999-08-02 21:45:36 +00:00
Brian Somers 12197c9e76 Mention which rfc the DNS/NBNS IPCP extensions come from. 1999-07-29 14:37:26 +00:00
Brian Somers 804c097b9e Fix a load of typos
Use sizeof, not a hardcode value.

Some of it submitted by:  Peter Jeremy <jeremyp@gsmx07.alcatel.com.au>
1999-07-28 03:01:52 +00:00
Brian Somers cad7e7426a o Overhaul filtering, adding facilities to jump over rules and to
negate the sense of rules.
o Remove the redundant (and undocumented) ``host'' and ``port''
  words (README.changes updated).
o Don't permit (and ignore) garbage instead of the protocol.

Mostly submitted by:  Peter Jeremy <jeremyp@gsmx07.alcatel.com.au>
1999-07-27 23:44:00 +00:00
Brian Somers 8d14e328f9 If we've negotiated CBCP and have also specified ``none'' as a possible
callback option, and the server sends us CBCP_NONUM, proceed directly
to the network phase rather than insisting on our configured CBCP
option.

Mostly submitted by: kkphang <phang@dgate.po.my>
1999-07-27 13:47:59 +00:00
Brian Somers 83a18abc10 Be a bit more consistent with variable names. 1999-07-27 00:30:32 +00:00
Brian Somers b4d797e707 Fix an off-by-one error and correct the man page WRT clearing
filters.

Submitted by:	Peter Jeremy <peter.jeremy@alcatel.com.au>
PR:		12437
1999-07-26 11:15:11 +00:00
Brian Somers 02ad5579d0 Fix a typo
Submitted by:	Rich Wood <rich@chugaboom.net>
1999-07-17 10:33:57 +00:00
Brian Somers 1f9e5fe5fa Support `igmp' filters.
Mostly submitted by: Timo Geusch <freebsd@sleepycat.ukpeople.net>
1999-06-23 16:48:24 +00:00
Brian Somers ec3026b6f7 Come up with something useful when someone searches for
``dynamic IP''.
1999-06-14 10:12:41 +00:00
Brian Somers fbe3e6af84 Describe why a ``magic'' enddisc is not always a good idea. 1999-06-11 11:27:18 +00:00
Brian Somers 9afe6bdaee Allow a remote IP and port range specification in the
``alias port'' command.
1999-06-10 00:17:27 +00:00
Brian Somers 7063995c94 Allow our endpoint discriminator to be enabled, disabled, accepted
and denied.  This is necessary for some MP implementations that
get confused if you accept their endpoint discriminator but reject
their MRRU.
1999-06-09 16:54:04 +00:00
Brian Somers b12ce35537 Make the ``load'', ``dial'' and ``open'' commands a big clearer.
Requested by: Michael Heitmeier <MICHAEL_HEITMEIER@HP-Germany-om12.om.hp.com>
1999-06-08 11:57:59 +00:00
Brian Somers ac685e314f Introduce the ``keep-session'' option. Refer to the man
page for details.  This allows MP over non-tty devices where
the original ppp process must not exit (such as sshd-spawned
ppp sessions).
1999-06-02 00:46:55 +00:00
Brian Somers d7452b10bd Mention that using MYADDR and HISADDR with ``set filter''
will result in the rules being updated any time MYADDR
or HISADDR change.
1999-06-01 08:46:53 +00:00
Brian Somers 9b898a03d8 Mention ``show layers'' 1999-05-16 13:39:03 +00:00
Brian Somers 6815097bf7 Allow ``host:port/udp'' devices and support ``host:port/tcp'' as
being the same as the previous (still supported) ``host:port''
syntax for tcp socket devices.

A udp device uses synchronous ppp rather than async, and avoids
the double-retransmit overhead that comes with ppp over tcp (it's
usually a bad idea to transport IP over a reliable transport that
itself is using an unreliable transport).  PPP over UDP provides
througput of ** 1.5Mb per second ** with all compression disabled,
maxing out a PPro/200 when running ppp twice, back-to-back.

This proves that PPPoE is plausable in userland....

This change adds a few more handler functions to struct device and
allows derivations of struct device (which may contain their own
data etc) to pass themselves through the unix domain socket for MP.
** At last **, struct physical has lost all the tty crud !

iov2physical() is now smart enough to restore the correct stack of
layers so that MP servers will work again.

The version number has bumped as our MP link transfer contents have
changed (they now may contain a `struct device').

Don't extract the protocol twice in MP mode (resulting in protocol
rejects for every MP packet).  This was broken with my original
layering changes.

Add ``Physical'' and ``Sync'' log levels for logging the relevent
raw packets and add protocol-tracking LogDEBUG stuff in various
LayerPush & LayerPull functions.

Assign our physical device name for incoming tcp connections by
calling getpeername().

Assign our physical device name for incoming udp connections from
the address retrieved by the first recvfrom().
1999-05-12 09:49:12 +00:00
Brian Somers 5d9e610366 o Redesign the layering mechanism and make the aliasing code part of
the layering.

  We now ``stack'' layers as soon as we open the device (when we figure
  out what we're dealing with).  A static set of `dispatch' routines are
  also declared for dealing with incoming packets after they've been
  `pulled' up through the stacked layers.

  Physical devices are now assigned handlers based on the device type
  when they're opened.  For the moment there are three device types;
  ttys, execs and tcps.

o Increment version number to 2.2
o Make an entry in [uw]tmp for non-tty -direct invocations (after
  pap/chap authentication).
o Make throughput counters quad_t's
o Account for the absolute number of mbuf malloc()s and free()s in
  ``show mem''.
o ``show modem'' becomes ``show physical''.
1999-05-08 11:07:56 +00:00
Brian Somers 3de29bbf70 Mention ``show mp''.
Describe ACFComp correctly.
1999-05-02 08:52:50 +00:00
Brian Somers 7c6b3a5704 Spelling police 1999-04-23 13:45:50 +00:00
Brian Somers fe3094cdd7 Allow port ranges in ``alias port''. 1999-03-25 23:36:25 +00:00
Brian Somers 4a948cab8b Do away with some literal text that is never switched
off - I *think* these were groff bugs.
1999-03-19 09:00:08 +00:00
Brian Somers 24a6ccfc38 Replace hardcoded quoting with Sq or Dq. 1999-03-19 01:42:45 +00:00
Brian Somers 8b9e9093a0 Use ``Sx'' when xref'ing sections. 1999-03-18 21:53:56 +00:00
Brian Somers 7919e54037 Remove all remaining [ and ] characters (and do things properly). 1999-03-18 21:50:52 +00:00
Brian Somers 38ab56c440 Remove all hardcoded [...] syntax.
With help from: Daniel C. Sobral <dcs@newsguy.com>
1999-03-17 00:25:43 +00:00
Guy Helmer d5f39fc1d1 Add leading 0 in front of octal file permissions number.
OK'ed by:	Brian Somers <brian@freebsd.org>
PR:		docs/9843
1999-03-07 20:27:45 +00:00
Brian Somers 50a63ab997 Support PPTP via libalias (``alias pptp addr''). 1999-03-07 18:13:44 +00:00
Brian Somers d318fe8e17 Support proxying & transparent proxying curtesy of libalias(3).
Order the alias command descriptions.
Order the SEE ALSO entries.
1999-03-07 15:02:38 +00:00
Brian Somers a39fd2143c Correctly drop existing connections when reopening the diagnostic
socket.
1999-03-07 11:54:43 +00:00
Brian Somers c11e57a340 Extend the ``set redial'' command to allow incremental
redial timeouts.
1999-03-04 17:42:15 +00:00
Brian Somers bc76350ef9 Correct some ntohl/htonl bogons in the netmask handling.
This was pretty harmless as netmasks on a POINTOPOINT
interface are pretty much ignored, but it looked funny.

Mention the configured netmask in ``show ipcp''.

Describe in more detail what a proxy arp entry is.
1999-03-03 23:00:41 +00:00
Brian Somers 479508cf28 Allow control over the number of ConfigREQ & TermREQ attempts
that are made in each of the FSMs (LCP, CCP & IPCP) and the
number of REQs/Challenges for PAP/CHAP by accepting more arguments
in the ``set {c,ip,l}cpretry'' and ``set {ch,p}apretry'' commands.

Change the non-convergence thresholds to 3 times the number of configured
REQ tries (rather than the previous fixed ``10'').  We now notice
repeated NAKs and REJs rather than just REQs.

Don't suggest that CHAP 0x05 isn't supported when it's not configured.

Fix some bugs that expose themselves with smaller numbers of retries:
o Handle instantaneous disconnects (set device /dev/null) correctly
  by stopping all fsm timers in fsm2initial.
o Don't forget to uu_unlock() devices that are files but are not
  ttys (set device /dev/zero).

Fix a *HORRENDOUS* bug in RFC1661 (already fixed for an Open event in state
``Closed''):
  According to the state transition table, a RCR+ or RCR- received in
  the ``Stopped'' state are supposed to InitRestartCounter, SendConfigReq
  and SendConfig{Ack,Nak}.  However, in ``Stopped'', we haven't yet
  done a TLS (or the last thing we did is a TLF).  We must therefore
  do the TLS at this point !

  This was never noticed before because LCP and CCP used not use
  LayerStart() for anything interesting, and IPCP tends to go into
  Stopped then get a Down because of an LCP RTR rather than getting a
  RCR again.
1999-02-26 21:28:14 +00:00
Brian Somers b5c347a37a When our dial timeout is ``random'', display its value
correctly by invoking the timer to get the value before
displaying the message.
Don't assume that a value of 0 is ``random'' in
``show datalink''.
Make the random value between 1 and DIAL_TIMEOUT rather
than between 0 and DIAL_TIMEOUT-1
1999-02-25 12:00:04 +00:00
Brian Somers 5e31549897 Fully support both NT and LANMan CHAP type 0x80 as both
authenticator and authenticatee.
1999-02-18 00:52:15 +00:00
Brian Somers 6b4286e0f5 Wait by default for one second after the login script
is complete before checking carrier.  If it's there,
the device supports carrier.  If it's not it doesn't.

Add the ``set cd'' command for deciding how soon to check
for carrier, and for deciding if carrier is REQUIRED.

The default has changed:  Pre 2.0 versions of ppp waited
for 1 second.  Version 2 didn't wait, but this causes
problems with some (few?) modems that don't assert carrier
immediately on reporting CONNECT.  The one second delay
is back now and can be removed with ``set cd 0''.

Bump the ppp version number in case this needs to be changed
again....
1999-02-16 00:16:56 +00:00
Brian Somers 9576e3690f Describe manual dialing in greater detail.
Mention more rfc numbers.
Don't ``.Nm Ppp'' (just use ``.Nm'').
1999-02-14 12:16:41 +00:00
Brian Somers a8103305cb When executing a command as part of a dial/login/hangup
script, expand words in the same way as !bg does.
1999-02-12 00:52:30 +00:00
Brian Somers 00b001185c /etc/ppp/ppp.*.sample -> /usr/share/examples/ppp/ppp.*.sample 1999-02-11 16:34:15 +00:00
Brian Somers 58330d7bfa When resending chap challenges, resend the same challenge
each time rather than making up a new one.

Increase the authname/authkey max sizes to 100 characters.

Allow ``authkey'' specifications beginning with ``!''.
When a challenge is received, the text following the
``!'' is executed as a program (expanding stuff in the same
way that ``sh'' and ``!bg'' do).  The program is passed the
peer name, peer challenge and local ``authname'' on standard
input and is expected to output the name/key combination that
should be used to build the CHAP response.

This provides support for Secure ID cards (guess what I was
given at work recently!) using CHAP.

Examples will follow.
1999-02-11 10:14:08 +00:00
Bill Fumerola 65aaeb15d5 Reflect syslog(8)'s acceptance of either tabs or spaces.
PR:		docs/9660
Submitted by:	Kris Kennaway <kkennawa@physics.adelaide.edu.au>
1999-01-28 22:55:08 +00:00
Brian Somers 972a1bcf5d Initial RADIUS support (using libradius). See the man page for
details.  Compiling with -DNORADIUS (the default for `release')
removes support.

TODO: The functionality in libradius::rad_send_request() needs
      to be supplied as a set of routines so that ppp doesn't
      have to wait indefinitely for the radius server(s).  Instead,
      we need to get a descriptor back, select() on the descriptor,
      and ask libradius to service it when necessary.
      For now, ppp blocks SIGALRM while in rad_send_request(), so
      it misses PAP/CHAP retries & timeouts if they occur.

      Only PAP is functional.  When CHAP is attempted, libradius
      complains that no User-Password has been specified... rfc2138
      says that it *mustn't* be used for CHAP :-(

Sponsored by: Internet Business Solutions Ltd., Switzerland
1999-01-28 01:56:34 +00:00
Brian Somers d9949a3acf Change the maximum number of filters from 20 to 40.
Increase requested by: "Clement T. Cole" <clemc@echo.ccc.com>
1999-01-19 22:16:02 +00:00
Brian Somers 3d091023a7 Suggest that ``set proctitle'' is used in ppp.linkup when
USER is expected to be expanded.
1999-01-19 22:15:41 +00:00