Skip site navigation (1)Skip section navigation (2)
Date:      Sun, 6 Jul 1997 16:56:47 -0700 (PDT)
From:      Archie Cobbs <archie@whistle.com>
To:        freebsd-hackers@FreeBSD.ORG
Subject:   Re: VJ compression and MAX_HDR
Message-ID:  <199707062356.QAA13745@bubba.whistle.com>
In-Reply-To: <199707062332.QAA13618@bubba.whistle.com> from Archie Cobbs at "Jul 6, 97 04:32:28 pm"

next in thread | previous in thread | raw e-mail | index | archive | help

> In slcompress.h, MAX_HDR is defined so:
> 
>   #define MAX_HDR MLEN          /* XXX 4bsd-ism: should really be 128 */
> 
> MLEN is like 108 or something.
> 
> This means that when Van Jacobson compression is active, any packets
> sent to us with combined IP and TCP header length greater than MLEN
> will be dropped, always.
> 
> This is an admittedly rare case, but my question is, why was this
> done? What code would break if MAX_HDR is changed back to 128?
> 
> Searching for "MAX_HDR" in every source file in /usr/src/sys shows
> that it only appears in slcompress.c and slcompress.h; moreover,
> the code in if_ppp.c and if_sl.c seems to properly handle uncompressed
> headers having length greater than MLEN (from a cursory glance).
> 
> Therefore, may I propose the following patch? Or else someone please
> elighten me.

After further review, it looks like the genesis of this change is
the fact that sl_compress_tcp() requires the full TCP/IP headers
to lie within the first mbuf, and sl_uncompress_tcp() requires the
TCP/IP header (in the TYPE_UNCOMPRESSED_TCP case) to also be in a
contiguous buffer...

Plus the fact that m_pullup() won't work for values greater than MHLEN
doesn't help.

Hmm.. 

-Archie

___________________________________________________________________________
Archie Cobbs   *   Whistle Communications, Inc.  *   http://www.whistle.com



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?199707062356.QAA13745>