ppp
ppp copied to clipboard
Cannot use VJ compression with pppol2tp plugin
In the file pppd/plugins/pppol2tp/pppol2tp.c
there is this code:
/* Setup option defaults. Compression options are disabled! */
modem = 0;
lcp_allowoptions[0].neg_accompression = 1;
lcp_wantoptions[0].neg_accompression = 0;
lcp_allowoptions[0].neg_pcompression = 1;
lcp_wantoptions[0].neg_pcompression = 0;
and I have been wondering why no matter what options I was trying to tweak, I couldn't make my side of PPP link use VJ:
Feb 26 10:31:00 whippet2 pppd[72589]: sent [IPCP ConfReq id=0x1 <addr 0.0.0.0>] Feb 26 10:31:00 whippet2 pppd[72589]: rcvd [IPCP ConfReq id=0x1 <compress VJ 0f 01> <addr 10.255.255.0>] Feb 26 10:31:00 whippet2 pppd[72589]: sent [IPCP ConfRej id=0x1 <compress VJ 0f 01>] Feb 26 10:31:00 whippet2 pppd[72589]: rcvd [IPCP ConfNak id=0x1 <addr 198.18.193.208>] Feb 26 10:31:00 whippet2 pppd[72589]: sent [IPCP ConfReq id=0x2 <addr 198.18.193.208>] Feb 26 10:31:00 whippet2 pppd[72589]: rcvd [IPCP ConfReq id=0x2 <addr 10.255.255.0>] Feb 26 10:31:00 whippet2 pppd[72589]: sent [IPCP ConfAck id=0x2 <addr 10.255.255.0>] Feb 26 10:31:00 whippet2 pppd[72589]: rcvd [IPCP ConfAck id=0x2 <addr 198.18.193.208>]
Any idea why this restriction is in place? The other side was willing to use compression with me.
thx,
I have found a part of the answer. In L2TP RFC 2661, section 8.1, it is written the following:
If VJ compression is used, and neither PPP reliable delivery nor sequence numbers are enabled, each lost packet results in a 1 in 2**16 chance of a TCP segment being forwarded with incorrect contents [RFC1144]. Where the combination of the packet loss rate with this statistical exposure is unacceptable, TCP header compression SHOULD NOT be used.
May I suggest that a reference to this be added to the comment in the code above?
I still have to dig more the project code to figure out if VJ compression match pcompression or accompression and if the same reasoning applies to both pppd compressions...
pcompression and accompression operate at a lower level than VJ compression and are not related to it.