netdev
[Top] [All Lists]

Re: what pointers does pskb_may_pull() nuke?

To: netdev@xxxxxxxxxxx, design@xxxxxxxxxxxxxxxxxx
Subject: Re: what pointers does pskb_may_pull() nuke?
From: Michael Richardson <mcr@xxxxxxxxxxxxxxxxxxxxxx>
Date: Tue, 04 Dec 2001 00:26:03 -0500
In-reply-to: Your message of "Wed, 28 Nov 2001 00:32:45 GMT." <Pine.LNX.4.33.0111272346140.1142-100000@xxxxxxxxxxxx>
Sender: owner-netdev@xxxxxxxxxxx
-----BEGIN PGP SIGNED MESSAGE-----


>>>>> "Julian" == Julian Anastasov <ja@xxxxxx> writes:
    Julian> after 2.4.4
    >> Is IPH_is_SKB_PULLED set by some other part of the system?

    Julian> I see it in your own code, not in kernel: lib/freeswan.h (1.91)

  Oops, my blush. I only grep'ed the code in net/ipsec :-)

  One thing is that we had mixed reports about the need to reassemble
fragments. We realized that this is because netfilter will reassemble
fragments for us.
  (My User-Mode-Linux tests had netfilter off)

  I thought that 2.2 had a specific option for turning this on. Maybe it
was 2.0! 

  Anyway, it is not clear to us what netfilter option is the minimum required
to cause fragments to be reassembled prior to transport layer. Is just having
netfilter enabled enough to do that?  I'm asking so that we can properly
diagnose the situation.

  We will be adding:

#ifdef IP_FRAGMENT_ASSEMBLE
        /* In Linux 2.4.4, we may have to reassemble fragments. They are
           not assembled automatically to save TCP from having to copy
           twice.
        */
      if (skb_is_nonlinear(skb)) {
        if (skb_linearize(skb, GFP_ATOMIC) != 0) {
          goto rcvleave;
        }
      }
      ipp = (struct iphdr *)skb->nh.iph;
      iphlen = ipp->ihl << 2;
#endif

  we will do this after we have checked for COW on the SKB.      

]       ON HUMILITY: to err is human. To moo, bovine.           |  firewalls  [
]   Michael Richardson, Sandelman Software Works, Ottawa, ON    |net architect[
] mcr@xxxxxxxxxxxxxxxxxxxxxx http://www.sandelman.ottawa.on.ca/ |device driver[
] panic("Just another NetBSD/notebook using, kernel hacking, security guy");  [

  


-----BEGIN PGP SIGNATURE-----
Version: 2.6.3ia
Charset: latin1
Comment: Finger me for keys

iQCVAwUBPAxeaYqHRg3pndX9AQGNOQQAw9bGwP0KVdN8y3bhJkJsU1xcAFXoyjc2
DqYtZDtY4CMP3R5URlH4hG2wWFB2Z+IIV/mdyVkmmLVzP+e8GBw/ZnVa9T9pFmHa
vstQtnRVOdNTpgOswgBZfzI3l4VMScA0WAVYREZEsxU7NZVhLzbIUZH5O28EEzpC
HfrUgs2ihhc=
=BNOW
-----END PGP SIGNATURE-----

<Prev in Thread] Current Thread [Next in Thread>