From: David F. Skoll Date: Tue, 28 May 2002 17:00:57 +0000 (+0000) Subject: Frank Cusack's latest patch. X-Git-Tag: ppp-2.4.7~416 X-Git-Url: https://git.ozlabs.org/?a=commitdiff_plain;h=28b9d996e0487c5b0ae71aaa40b4db76f7b1fa1e;p=ppp.git Frank Cusack's latest patch. --- diff --git a/README.MPPE b/README.MPPE index cdada34..94b8456 100644 --- a/README.MPPE +++ b/README.MPPE @@ -60,13 +60,16 @@ BUILDING THE PPPD The userland component of PPPD has no additional requirements above those for MS-CHAP and MS-CHAPv2. The kernel, however, requires SHA-1 -and ARCFOUR. Public domain implementations of these are provided. Until -such time as MPPE support ships with kernels, you can use the Linux-2.2 -implementation that comes with PPPD. Run the linux/mppe/mppeinstall.sh -script, then rebuild your kernel. The ppp_mppe.o module is added, and the -ppp.o module (2.2) or ppp_generic.o (2.4) is modified (unfortunately). -You'll need the new ppp.o/ppp_generic.o since it does the right thing -for the 4 extra bytes problem discussed above. +and ARCFOUR. Public domain implementations of these are provided. + +Until such time as MPPE support ships with kernels, you can use +the Linux 2.2 or 2.4 implementation that comes with PPPD. Run the +ppp/linux/mppe/mppeinstall.sh script, giving it the location to your +kernel source. Then add the CONFIG_PPP_MPPE option to your config and +rebuild the kernel. The ppp_mppe.o module is added, and the ppp.o module +(2.2) or ppp_generic.o (2.4) is modified (unfortunately). You'll need +the new ppp.o/ppp_generic.o since it does the right thing for the 4 +extra bytes problem discussed above. CONFIGURATION diff --git a/pppd/ccp.c b/pppd/ccp.c index 40bf77f..3e408ba 100644 --- a/pppd/ccp.c +++ b/pppd/ccp.c @@ -25,7 +25,7 @@ * OR MODIFICATIONS. */ -#define RCSID "$Id: ccp.c,v 1.35 2002/05/21 17:26:49 dfs Exp $" +#define RCSID "$Id: ccp.c,v 1.36 2002/05/28 17:00:57 dfs Exp $" #include #include @@ -453,7 +453,7 @@ ccp_input(unit, p, len) notice("Compression disabled by peer."); #ifdef MPPE if (ccp_gotoptions[unit].mppe) { - notice("MPPE disabled, closing LCP"); + error("MPPE disabled, closing LCP"); lcp_close(unit, "MPPE disabled by peer"); } #endif @@ -513,6 +513,7 @@ ccp_protrej(unit) #ifdef MPPE if (ccp_gotoptions[unit].mppe) + error("MPPE required but peer negotiation failed"); lcp_close(unit, "MPPE required but peer negotiation failed"); #endif @@ -899,8 +900,10 @@ ccp_nakci(f, p, len) /* Peer must have set options we didn't request (suggest) */ try.mppe = 0; - if (!try.mppe) + if (!try.mppe) { + error("MPPE required but peer negotiation failed"); lcp_close(f->unit, "MPPE required but peer negotiation failed"); + } } #endif /* MPPE */ if (go->deflate && len >= CILEN_DEFLATE @@ -977,6 +980,7 @@ ccp_rejci(f, p, len) #ifdef MPPE if (go->mppe && len >= CILEN_MPPE && p[0] == CI_MPPE && p[1] == CILEN_MPPE) { + error("MPPE required but peer refused"); lcp_close(f->unit, "MPPE required but peer refused"); p += CILEN_MPPE; len -= CILEN_MPPE; @@ -1314,8 +1318,10 @@ ccp_reqci(f, p, lenp, dont_nak) *lenp = retp - p0; } #ifdef MPPE - if (ret == CONFREJ && ao->mppe && !seen_ci_mppe) + if (ret == CONFREJ && ao->mppe && !seen_ci_mppe) { + error("MPPE required but peer negotiation failed"); lcp_close(f->unit, "MPPE required but peer negotiation failed"); + } #endif return ret; } @@ -1431,8 +1437,10 @@ ccp_down(f) ccp_localstate[f->unit] = 0; ccp_flags_set(f->unit, 1, 0); #ifdef MPPE - if (ccp_gotoptions[f->unit].mppe) + if (ccp_gotoptions[f->unit].mppe) { + error("MPPE disabled"); lcp_close(f->unit, "MPPE disabled"); + } #endif }