ppp.git
15 years agoPatch from Robert Vogelgesang:
Paul Mackerras [Thu, 28 Oct 2004 00:24:40 +0000 (00:24 +0000)]
Patch from Robert Vogelgesang:
This patch does two things:
o It adds some debugging messages.
o "cleanup()" will no longer be added to the link_down_notifier
chain.
The debugging messages are obvious.
The problem with cleanup() in the link_down_notifier chain is only
half-way that there could be cases where the link would go up again
and without a further authentication -- I just don't know if this
can happen.  But this part of the patch is a work-around for a
_real_ problem/bug in the radius plugin (not the radattr plugin):

The radius plugin calls functions registered via the
radius_attributes_hook after each PAP authentication (which is
correct), but only after the _first_ successful CHAP authentication
during a session.  Subsequent CHAP authentications are performed,
but the radius_attributes_hook will not be processed again.

This can happen in a setup where pppd is used as a back-end
        by a L2TP daemon, in case the PPP session at the other side
        of the L2TP tunnel reconnects, but the L2TP daemon at that
        side just reuses the old L2TP tunnel instead of creating a
        new one.  In such situations, an incomming follow-up session
via an existing T2TP tunnel would re-use the same instance of
pppd; the incomming CHAP authentication would first tear down
the old session, which in turn would call the link_down_notifier.
When the _subsequent_ CHAP authentication succeeds, there is
currently no call to the function assigned to
radius_attributes_hook (here: print_attributes(); THIS BUG
REMAINS AND NEEDS TO BE FIXED).
To summarize: The radius plugin calls the function registered
via the radius_attributes_hook after _each_ successful PAP
authentication, but only after the _first_ successful CHAP
authentication; radius_attributes_hook _should_ be processed
after _each_ successful CHAP authentication.

I have currently no patch for this bug; furthermore, I should
first contact the author of the radius plugin and ask him,
_why_ he has programmed a special handling of subsequent
CHAP authentications.

With the following patch, the follow-up session can re-use the
radattr-file left over from the previous session, which is OK
in our application, but may cause problems in others.
Note: This is only a problem when CHAP is used; subsequent
sessions authenticated with PAP are OK, with and without this
patch.

15 years agoRemove compile warning resulting from chap_verify_hook prototype change.
Paul Mackerras [Thu, 28 Oct 2004 00:22:54 +0000 (00:22 +0000)]
Remove compile warning resulting from chap_verify_hook prototype change.

15 years agoPatch from Robert Vogelgesang:
Paul Mackerras [Thu, 28 Oct 2004 00:21:48 +0000 (00:21 +0000)]
Patch from Robert Vogelgesang:
        This patch avoids duplicate session IDs in RADIUS accounting,
        when the same pppd instance has multiple sessions during
        the same second.  This can happen when you have a really
        fast RADIUS server and fast clients, e. g. when using pppd
        as a back-end for PPPoE (either directly or via L2TP).

15 years agoGet rid of an unnecessary chmod (it wasn't being used on Linux anyway).
Paul Mackerras [Thu, 28 Oct 2004 00:16:37 +0000 (00:16 +0000)]
Get rid of an unnecessary chmod (it wasn't being used on Linux anyway).

15 years agoFix some places where we weren't checking the received
Paul Mackerras [Thu, 28 Oct 2004 00:15:36 +0000 (00:15 +0000)]
Fix some places where we weren't checking the received
packets carefully enough.

15 years agoMake the filtering stuff work with recent versions of libpcap.
Paul Mackerras [Thu, 28 Oct 2004 00:15:08 +0000 (00:15 +0000)]
Make the filtering stuff work with recent versions of libpcap.

15 years agoDon't prepend /dev/ to a possible device name if it already begins
Paul Mackerras [Sun, 24 Oct 2004 23:53:05 +0000 (23:53 +0000)]
Don't prepend /dev/ to a possible device name if it already begins
with '/' (i.e. just check for / instead of /dev/ as before).
This allows /udev/blah to be used as a tty device name.
Requested by Pawel Sakowski.

15 years agoDon't use unsigned long in the SHA1 code; we want 32-bit variables
Paul Mackerras [Sun, 24 Oct 2004 23:31:20 +0000 (23:31 +0000)]
Don't use unsigned long in the SHA1 code; we want 32-bit variables
and unsigned long is 64 bits on 64-bit platforms.  Use unsigned int
or u_int32_t instead.  Pointed out by Oleg Makarenko.

15 years agoFix use-after-free bug where we were freeing the per-user options
Paul Mackerras [Sun, 24 Oct 2004 23:26:19 +0000 (23:26 +0000)]
Fix use-after-free bug where we were freeing the per-user options
set in the secrets file before they were used.  Patch from
Michael Tokarev.

15 years agoTolerate EINTR on tcsetattr in set_up_tty - just retry.
Paul Mackerras [Sun, 24 Oct 2004 23:18:50 +0000 (23:18 +0000)]
Tolerate EINTR on tcsetattr in set_up_tty - just retry.

15 years agoClose the device fd in device_script() if the channel plugin doesn't
Paul Mackerras [Sun, 24 Oct 2004 23:13:16 +0000 (23:13 +0000)]
Close the device fd in device_script() if the channel plugin doesn't
have a close function.  Change suggested by Alan Hourihane.

15 years agoAllow pppoe to be used on bridging interfaces (br*).
Paul Mackerras [Sun, 24 Oct 2004 23:06:31 +0000 (23:06 +0000)]
Allow pppoe to be used on bridging interfaces (br*).
Get rid of OldDevnameHook, which was never used.

16 years agoHandle PFC on rx side, efficiently, thanks to Jan Dubiec.
Frank Cusack [Tue, 4 May 2004 12:30:18 +0000 (12:30 +0000)]
Handle PFC on rx side, efficiently, thanks to Jan Dubiec.

16 years agofix typos noticed by James Cameron.
Frank Cusack [Tue, 27 Apr 2004 18:22:58 +0000 (18:22 +0000)]
fix typos noticed by James Cameron.

16 years agoTested with MS-CHAP and CBCP options on Solaris and added options
James Carlson [Wed, 14 Apr 2004 02:39:39 +0000 (02:39 +0000)]
Tested with MS-CHAP and CBCP options on Solaris and added options
to makefile.
Repaired support for use of gcc on Solaris x86 -- 32 bit modules also
need -fno-builtin.
MPPE changes broke plain MS-CHAP; repaired errors and cleaned up
compilation warnings due to char/unsigned char differences with non-gcc
compilers.

16 years agoSet up the mask of signals we handle in one place not too
Paul Mackerras [Mon, 12 Apr 2004 11:20:19 +0000 (11:20 +0000)]
Set up the mask of signals we handle in one place not too
Remove unnecessary sigaddset in kill_my_pg

16 years agotidy up shell scripting, common radvd path in examples
Alexandr D. Kanevskiy [Mon, 12 Apr 2004 05:41:01 +0000 (05:41 +0000)]
tidy up shell scripting, common radvd path in examples

16 years agoexample fix
Alexandr D. Kanevskiy [Mon, 12 Apr 2004 05:25:06 +0000 (05:25 +0000)]
example fix

16 years agoadd support of Port-Type=Sync
Alexandr D. Kanevskiy [Mon, 12 Apr 2004 05:16:37 +0000 (05:16 +0000)]
add support of Port-Type=Sync

16 years agoadd support of Port-Type=Sync
Alexandr D. Kanevskiy [Mon, 12 Apr 2004 05:14:53 +0000 (05:14 +0000)]
add support of Port-Type=Sync

16 years agofix random signals blocking in handle_events()
Alexandr D. Kanevskiy [Mon, 12 Apr 2004 05:02:00 +0000 (05:02 +0000)]
fix random signals blocking in handle_events()

16 years agofix random signals blocking in kill_my_pg()
Alexandr D. Kanevskiy [Mon, 12 Apr 2004 04:53:00 +0000 (04:53 +0000)]
fix random signals blocking in kill_my_pg()

16 years agoDescribe avpair in pppd-radius.8
Alexandr D. Kanevskiy [Fri, 26 Mar 2004 13:27:17 +0000 (13:27 +0000)]
Describe avpair in pppd-radius.8
Add support for:
 NAS-Port-Type (Async/Virtual)
 Acct-Terminate-Cause
 Selectable NAS-Port-Id equal to interface number or try map via libradiusclient

16 years agoMPPE for 2.6.
Frank Cusack [Tue, 23 Mar 2004 23:31:45 +0000 (23:31 +0000)]
MPPE for 2.6.
Contributed by Thomas Sjolshagen <thomas.sjolshagen@hp.com> and
James Cameron <james.cameron@hp.com>

16 years agoFixed bad next-state in previous delta; need to go to Stopping state
James Carlson [Mon, 2 Feb 2004 03:57:19 +0000 (03:57 +0000)]
Fixed bad next-state in previous delta; need to go to Stopping state
when Protocol-Reject is seen in Opened state.

16 years agoFix kill_my_pg, and add a big fat comment explaining why
Paul Mackerras [Mon, 2 Feb 2004 03:40:12 +0000 (03:40 +0000)]
Fix kill_my_pg, and add a big fat comment explaining why
the previous "fix" was wrong.

16 years agoAllow *-max-terminate to be set to zero -- meaning that one Terminate-
James Carlson [Mon, 2 Feb 2004 02:52:51 +0000 (02:52 +0000)]
Allow *-max-terminate to be set to zero -- meaning that one Terminate-
Request will be sent, but no waiting will be done.  Fixed termination
code so that link statistics are printed only once.

16 years agoFixed compilation failure on Solaris due to new CHAP (missing chap-md5.o
James Carlson [Sat, 17 Jan 2004 05:47:55 +0000 (05:47 +0000)]
Fixed compilation failure on Solaris due to new CHAP (missing chap-md5.o
in makefile).

Updated ppp_mod so that it will work with Solaris 10 and beyond
(identify entry point is now obsolete).

Fixed warnings in chat, bsd-comp, deflate, vjcompress, chap-new,
sys-solaris, tty, pppdump, ppp_comp.

16 years agoDescribe DNS1 and DNS2 environment variables.
Paul Mackerras [Thu, 15 Jan 2004 05:09:00 +0000 (05:09 +0000)]
Describe DNS1 and DNS2 environment variables.

16 years agoUpdate
Paul Mackerras [Tue, 13 Jan 2004 04:46:52 +0000 (04:46 +0000)]
Update

16 years agoDon't change serial port permissions under Linux, since the
Paul Mackerras [Tue, 13 Jan 2004 04:17:59 +0000 (04:17 +0000)]
Don't change serial port permissions under Linux, since the
kernel driver blocks normal writes anyway.

16 years agoRemove the code that handles the %r format, since it isn't used
Paul Mackerras [Tue, 13 Jan 2004 04:13:08 +0000 (04:13 +0000)]
Remove the code that handles the %r format, since it isn't used
and breaks on S/390.

16 years agoCheck for EAGAIN as well as EWOULDBLOCK, since they are
Paul Mackerras [Tue, 13 Jan 2004 04:12:31 +0000 (04:12 +0000)]
Check for EAGAIN as well as EWOULDBLOCK, since they are
different under Linux on parisc.

16 years agoNote that the inbound and outbound qualifiers can be used with
Paul Mackerras [Tue, 13 Jan 2004 04:04:52 +0000 (04:04 +0000)]
Note that the inbound and outbound qualifiers can be used with
active-filter.  Patch sent in by Marco d'Itri.

16 years agoPPPoE updates: don't exit if discovery fails, cope with both
Paul Mackerras [Tue, 13 Jan 2004 04:03:58 +0000 (04:03 +0000)]
PPPoE updates: don't exit if discovery fails, cope with both
protocol field compression and no compression, recognize
nasXXX and tapXXX as devices over which we can do PPPoE.
Patches sent by Marco d'Itri.

16 years agoInvoke options.ttyxx even if the dev directory isn't at the root
Paul Mackerras [Tue, 13 Jan 2004 04:02:07 +0000 (04:02 +0000)]
Invoke options.ttyxx even if the dev directory isn't at the root
(e.g. if the tty device is /ram1/dev/ttyS0).  Patch sent in by
Marco d'Itri.

16 years agoDon't fall over if the channel doesn't have a disconnect method.
Paul Mackerras [Tue, 13 Jan 2004 04:00:34 +0000 (04:00 +0000)]
Don't fall over if the channel doesn't have a disconnect method.

16 years agoFix a compile warning (IPPROTO_TCP redefined).
Paul Mackerras [Tue, 13 Jan 2004 03:59:37 +0000 (03:59 +0000)]
Fix a compile warning (IPPROTO_TCP redefined).

16 years agoAlways set the DNS1 and DNS2 environment variables from scripts,
Paul Mackerras [Tue, 13 Jan 2004 03:59:06 +0000 (03:59 +0000)]
Always set the DNS1 and DNS2 environment variables from scripts,
even if we didn't explicitly ask the peer to send them.  Patch from
Marco d'Itri.

16 years agoChange some Makefile.linux files to use COPTS and CFLAGS the same way
Paul Mackerras [Tue, 13 Jan 2004 03:57:55 +0000 (03:57 +0000)]
Change some Makefile.linux files to use COPTS and CFLAGS the same way
that pppd/Makefile.linux does.

16 years agoChange references to cuaN in examples and documentation to ttySN.
Paul Mackerras [Tue, 13 Jan 2004 03:55:52 +0000 (03:55 +0000)]
Change references to cuaN in examples and documentation to ttySN.
Yes, rather linux-centric, I know.  Patch from Marco d'Itri
(Debian ppp package maintainer).

16 years agoFix off-by-one error in radius MS-CHAPv2 verification.
Paul Mackerras [Sun, 11 Jan 2004 08:01:30 +0000 (08:01 +0000)]
Fix off-by-one error in radius MS-CHAPv2 verification.
Patch from Anton Golubev.

16 years agobugfix from Erich Schubert (erich at debian.org)
Alexandr D. Kanevskiy [Wed, 17 Dec 2003 08:56:05 +0000 (08:56 +0000)]
bugfix from Erich Schubert (erich at debian.org)

16 years agoFix the ID string
Paul Mackerras [Thu, 27 Nov 2003 22:22:36 +0000 (22:22 +0000)]
Fix the ID string

16 years agoRemove old CHAP implementation
Paul Mackerras [Thu, 27 Nov 2003 22:16:24 +0000 (22:16 +0000)]
Remove old CHAP implementation

16 years agoEnable PPP filtering by default on Linux.
Paul Mackerras [Thu, 27 Nov 2003 21:55:19 +0000 (21:55 +0000)]
Enable PPP filtering by default on Linux.

16 years agoUpdate my email address.
Paul Mackerras [Thu, 27 Nov 2003 21:32:03 +0000 (21:32 +0000)]
Update my email address.

16 years agoRemove references to the old CHAP code.
Paul Mackerras [Thu, 27 Nov 2003 21:25:25 +0000 (21:25 +0000)]
Remove references to the old CHAP code.

16 years agoUpdate this for the new CHAP code. Untested.
Paul Mackerras [Tue, 25 Nov 2003 11:50:10 +0000 (11:50 +0000)]
Update this for the new CHAP code.  Untested.

16 years agoUpdate to 2.4.2
Paul Mackerras [Tue, 25 Nov 2003 11:49:36 +0000 (11:49 +0000)]
Update to 2.4.2

16 years agofix a bug reported by Morgan Nelson.
Alexandr D. Kanevskiy [Tue, 23 Sep 2003 15:11:58 +0000 (15:11 +0000)]
fix a bug reported by Morgan Nelson.
Confirmed on RedHat/ASPLinux 9

16 years agoFixed the old chap.c so that it works with the new auth.c, since
James Carlson [Mon, 28 Jul 2003 12:25:41 +0000 (12:25 +0000)]
Fixed the old chap.c so that it works with the new auth.c, since
existing makefiles still refer to chap.c for all but Linux.
Fixed unsolicited Configure-Nak handling in *_nakci -- usenet report
that 'while' loop terminates too early if there's a boolean.
Fixed tiny typo in chap-new.c comment.

16 years agoskip response length byte before handling the response itself,
Frank Cusack [Thu, 10 Jul 2003 17:59:33 +0000 (17:59 +0000)]
skip response length byte before handling the response itself,
thx to Paul Flinders

17 years ago#include <linux/string.h> for mem*()
Frank Cusack [Mon, 7 Jul 2003 08:23:43 +0000 (08:23 +0000)]
#include <linux/string.h> for mem*()

17 years ago#elif, not #else if
Frank Cusack [Mon, 7 Jul 2003 08:21:36 +0000 (08:21 +0000)]
#elif, not #else if

17 years agodon't barf on RH directory suffixes (-release)
Frank Cusack [Mon, 7 Jul 2003 08:21:20 +0000 (08:21 +0000)]
don't barf on RH directory suffixes (-release)

17 years agoFix a couple of state transitions
Paul Mackerras [Sun, 29 Jun 2003 10:06:14 +0000 (10:06 +0000)]
Fix a couple of state transitions
Make sure we only call np_finished once

17 years agoFix a couple of errors pointed out by Andrew Benham <adsb@adsb.co.uk>.
Paul Mackerras [Sun, 29 Jun 2003 10:04:50 +0000 (10:04 +0000)]
Fix a couple of errors pointed out by Andrew Benham <adsb@adsb.co.uk>.

17 years agoUpdate the what's new list
Paul Mackerras [Sun, 29 Jun 2003 10:04:10 +0000 (10:04 +0000)]
Update the what's new list

17 years agoNew CHAP implementation, rewritten from scratch to avoid the code
Paul Mackerras [Wed, 11 Jun 2003 23:56:26 +0000 (23:56 +0000)]
New CHAP implementation, rewritten from scratch to avoid the code
copyrighted by the uncontactable Gregory Christy.  The new code is
much cleaner and splits out all the digest-specific code to separate
files.  Thus the CHAP-MD5 stuff is now in chap-md5.c and all the
CHAP-MS and CHAP-MSv2 stuff has moved into chap_ms.c, instead of
having half of it in chap.c.

There are a few minor differences in this implementation; we don't
retransmit responses, but instead just wait for a new challenge.
The success/failure messages are more boring as well.  In fact the
digest code now sets the success/failure message.

CHAP_DIGEST_MD5 has been renamed to CHAP_MD5 for consistency.
There is a new function random_bytes() in magic.c, which generates
a string of random bytes.

17 years agoFix a bug where we would keep asking for MS-CHAP v2 even though
Paul Mackerras [Wed, 11 Jun 2003 23:50:53 +0000 (23:50 +0000)]
Fix a bug where we would keep asking for MS-CHAP v2 even though
the peer NAK'd with MD5.

17 years agoAdd copyright notice and rewrite all sections which are identifiably
Paul Mackerras [Wed, 11 Jun 2003 00:11:11 +0000 (00:11 +0000)]
Add copyright notice and rewrite all sections which are identifiably
from the original pppd.8.

17 years agos/opad/xpad/ to be consistent with other vars (r=recv,x=xmit)
Frank Cusack [Sun, 25 May 2003 01:56:23 +0000 (01:56 +0000)]
s/opad/xpad/ to be consistent with other vars (r=recv,x=xmit)

17 years agosmall padding change
Frank Cusack [Sun, 25 May 2003 01:50:12 +0000 (01:50 +0000)]
small padding change

17 years agobail on dirs not of the form linux-x.y.z
Frank Cusack [Sun, 25 May 2003 01:46:25 +0000 (01:46 +0000)]
bail on dirs not of the form linux-x.y.z

17 years agomodify ppp_generic patch to avoid an if() test and extra additions on
Frank Cusack [Tue, 13 May 2003 01:25:36 +0000 (01:25 +0000)]
modify ppp_generic patch to avoid an if() test and extra additions on
every pass through ppp_send_frame(); make a 2.4.19+ version of it;
improve mppeinstall.sh.

17 years agotypo
Frank Cusack [Mon, 12 May 2003 08:37:21 +0000 (08:37 +0000)]
typo

17 years agoRemove an extraneous HAVE_CRYPT_H definition
Frank Cusack [Mon, 12 May 2003 08:18:54 +0000 (08:18 +0000)]
Remove an extraneous HAVE_CRYPT_H definition

17 years agouse librcrypt if available (crypt(3) is apparently in libcrypt on Linux)
Frank Cusack [Mon, 12 May 2003 08:13:24 +0000 (08:13 +0000)]
use librcrypt if available (crypt(3) is apparently in libcrypt on Linux)

17 years agoquiet the compiler, at the expense of #ifdef madness
Frank Cusack [Mon, 12 May 2003 07:47:06 +0000 (07:47 +0000)]
quiet the compiler, at the expense of #ifdef madness

17 years agoWhen not in demand mode, defer create_linkpidfile() until we successfully
Frank Cusack [Mon, 12 May 2003 07:31:36 +0000 (07:31 +0000)]
When not in demand mode, defer create_linkpidfile() until we successfully
get a ppp interface.  This fixes a bug reported by belle_eden@caramail.com
where pppd might wipe out a still-running previous pppd's pid file.

17 years agoRepaired bad LCP Configure-Nak generated to request EAP instead of PAP.
James Carlson [Fri, 9 May 2003 11:49:46 +0000 (11:49 +0000)]
Repaired bad LCP Configure-Nak generated to request EAP instead of PAP.

17 years agoUpdate
Paul Mackerras [Thu, 1 May 2003 12:47:55 +0000 (12:47 +0000)]
Update

17 years agoUpdate.
Paul Mackerras [Thu, 1 May 2003 12:43:16 +0000 (12:43 +0000)]
Update.

17 years agotty_recv_config doesn't return a value any more.
Paul Mackerras [Thu, 1 May 2003 12:42:39 +0000 (12:42 +0000)]
tty_recv_config doesn't return a value any more.

17 years agoFix the case where we get a CCP conf-rej for the old deflate option.
Paul Mackerras [Thu, 1 May 2003 12:30:28 +0000 (12:30 +0000)]
Fix the case where we get a CCP conf-rej for the old deflate option.
Previously we incorrectly thought this was bogus.

17 years agoadd note about allow-number and remotenumber
Frank Cusack [Wed, 30 Apr 2003 04:55:19 +0000 (04:55 +0000)]
add note about allow-number and remotenumber

17 years agoccp_nakci(), ccp_reqci(): If refusing MPPE stateful mode, log an error
Frank Cusack [Fri, 25 Apr 2003 09:41:58 +0000 (09:41 +0000)]
ccp_nakci(), ccp_reqci(): If refusing MPPE stateful mode, log an error
message with a hint.

17 years agoDocument the 'password' option (with warning).
Frank Cusack [Fri, 25 Apr 2003 08:57:58 +0000 (08:57 +0000)]
Document the 'password' option (with warning).

17 years agopromptpass(): handle EINTR (bug report from Damian Gruszka)
Frank Cusack [Fri, 25 Apr 2003 08:21:47 +0000 (08:21 +0000)]
promptpass(): handle EINTR (bug report from Damian Gruszka)

17 years agopromptpass(): read(2) returns ssize_t, not size_t. (Damien Gruszka)
Frank Cusack [Fri, 25 Apr 2003 08:16:46 +0000 (08:16 +0000)]
promptpass(): read(2) returns ssize_t, not size_t.  (Damien Gruszka)

17 years agorc_get_seqnbr(): Avoid "fscanf failure" errors if the sequence file was
Frank Cusack [Fri, 25 Apr 2003 08:10:46 +0000 (08:10 +0000)]
rc_get_seqnbr(): Avoid "fscanf failure" errors if the sequence file was
empty.  This avoids a spurious error at startup if the sequence file is
kept in /var/run, which is cleared on reboot.

17 years agotypo
Frank Cusack [Fri, 25 Apr 2003 07:33:20 +0000 (07:33 +0000)]
typo

17 years agoFix stack overflow. Bug report and fix from Alexandar Atanasov.
Frank Cusack [Wed, 16 Apr 2003 05:55:35 +0000 (05:55 +0000)]
Fix stack overflow.  Bug report and fix from Alexandar Atanasov.

17 years agoupdate
Paul Mackerras [Tue, 8 Apr 2003 13:05:36 +0000 (13:05 +0000)]
update

17 years agoRevert the previous change that required channel send_config and
Paul Mackerras [Mon, 7 Apr 2003 00:01:46 +0000 (00:01 +0000)]
Revert the previous change that required channel send_config and
recv_config routines to return a status code.  Instead we consider
that an error has occurred if the channel routine calls error()
or bumps error_count explicitly.

17 years agoMade path to 'ld' explicit when building kernel modules. This avoids
James Carlson [Mon, 31 Mar 2003 12:07:28 +0000 (12:07 +0000)]
Made path to 'ld' explicit when building kernel modules.  This avoids
trouble with systems that have GNU ld installed and on the path before
the normal /usr/ccs/bin/ld that comes with the system.

17 years agoAdd complete_read(), an EINTR-proof and partial-read-proof read,
Paul Mackerras [Sun, 30 Mar 2003 08:26:56 +0000 (08:26 +0000)]
Add complete_read(), an EINTR-proof and partial-read-proof read,
and use it for reading synchronization pipes.

17 years agofix typo reported by Thomas Klausner.
Frank Cusack [Tue, 25 Mar 2003 09:33:32 +0000 (09:33 +0000)]
fix typo reported by Thomas Klausner.

17 years agoBrian May's Perl script to auto-dial ppp. Has exponentially increasing delays
Russell Coker [Sun, 9 Mar 2003 10:04:35 +0000 (10:04 +0000)]
Brian May's Perl script to auto-dial ppp.  Has exponentially increasing delays
on connect failures to avoid excessive costs.

17 years agoMerging tiny patch from John R.Daily <jdaily@progeny.com> for bug in processing
Russell Coker [Sun, 9 Mar 2003 09:52:19 +0000 (09:52 +0000)]
Merging tiny patch from John R.Daily <jdaily@progeny.com> for bug in processing
results from getnetbyname().

17 years agoadd debugging for coherency count
Frank Cusack [Fri, 7 Mar 2003 05:50:55 +0000 (05:50 +0000)]
add debugging for coherency count

17 years agoIf the peer offers mppe stateful mode (H bit clear), accept it if
Frank Cusack [Wed, 5 Mar 2003 23:01:28 +0000 (23:01 +0000)]
If the peer offers mppe stateful mode (H bit clear), accept it if
mppe-stateful was an option.

This bug wasn't discovered earlier because I haven't seen a system
that offers stateful mode "only".  A bug report from Dmitry Glushenok
shows that Windows RRAS refuses stateless mode for dialup connections.
For dialup, it almost makes sense that one could use stateful mode safely,
but if you accept that argument (difficult to attack a dialup connection)
then it also follows that mppe as a whole is not useful over dialup.

17 years agoclean(): Fix buffer overflow.
Frank Cusack [Tue, 4 Mar 2003 06:17:21 +0000 (06:17 +0000)]
clean(): Fix buffer overflow.

17 years agosafe_fork(): trap EINTR on pipe read
Frank Cusack [Tue, 4 Mar 2003 05:37:22 +0000 (05:37 +0000)]
safe_fork(): trap EINTR on pipe read

17 years ago*_send_config and *_recv_config now return int instead of calling fatal().
Frank Cusack [Tue, 4 Mar 2003 05:21:38 +0000 (05:21 +0000)]
*_send_config and *_recv_config now return int instead of calling fatal().

17 years agostyle
Frank Cusack [Tue, 4 Mar 2003 05:13:59 +0000 (05:13 +0000)]
style

17 years agoA bunch of fixes mostly aimed at fixing the problems we have been
Paul Mackerras [Mon, 3 Mar 2003 05:11:46 +0000 (05:11 +0000)]
A bunch of fixes mostly aimed at fixing the problems we have been
having with leaking fds and with fatal errors occurring when the link
goes down.
Updated patchlevel.h to 2.4.2b2.
Moved open of /dev/ppp to generic_establish_ppp; we now close the
ppp_dev_fd in generic_disestablish_ppp rather than trying to use
PPPIOCDETACH.
*_send_config and *_recv_config now return 0 for success or -1 for
error, rather than calling fatal() when an error occurs.
Added a notifier for when we fork so plugins can close their fds in
the child.
Added a safe_fork() which does a fork and then closes stuff in the
child; the parent waits until the child has done that.
On detach, the parent rewrites the pid files rather than the child,
and the child waits for the parent to die.
Fixed some potential FILE * leaks.
Also moved auth_number() check into auth_check_options.

17 years agostyle
Frank Cusack [Wed, 26 Feb 2003 10:18:10 +0000 (10:18 +0000)]
style

17 years agomake pap_auth_hook docs match code. Reported by David Ananian-Cooper.
Frank Cusack [Tue, 25 Feb 2003 07:43:09 +0000 (07:43 +0000)]
make pap_auth_hook docs match code.  Reported by David Ananian-Cooper.