lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-Id: <1210032076.8012.49.camel@johannes.berg>
Date:	Tue, 06 May 2008 02:01:16 +0200
From:	Johannes Berg <johannes@...solutions.net>
To:	David Miller <davem@...emloft.net>
Cc:	tomasw@...il.com, linville@...driver.com, netdev@...r.kernel.org,
	linux-wireless@...r.kernel.org, herbert@...dor.apana.org.au
Subject: Re: [RFC v2] mac80211: assign needed_headroom/tailroom for netdevs


> > Which buffer? skb->data..skb->tail? And isn't that, in mac80211's case,
> > at least currently all the buffer anyway?
> 
> Right.
> 
> For TSO or cases using frag lists of frag page vectors, it gets
> more complicated.

Yeah, but at least right now we don't accept any of those. That might
change, but even then we'll only care about the headroom (and maybe for
TKIP the crypto MIC that's at the end, assuming the hardware does the
encryption which it usually does), but we can stick that elsewhere and
just DMA it on.

> Basically, skb_header_cloned()==false means that you can modify
> anything covered by skb->data..skb->tail

Ok.

> > Interesting point. I'll have to see when socket filters are run,
> > wpa_supplicant could have a tap open I think. Maybe that's why I'm
> > seeing so many cloned packets. I think I'll stacktrace skb_clone and
> > print that out.
> 
> Note that we can even optimize that case even further if we really
> have to.
> 
> But try to see why the filter used by WPA Supplicant is not effective.
> If the filter fails to match, the packet is free'd immediately using
> kfree_skb() which should undo clone'age.

Right. I just checked, and realised I remembered wrongly, wpa_supplicant
actually binds the socket to the ethertype it wants so
dev_queue_xmit_nit() shouldn't be called. I'll have to check why I got
so many cloned packets, best see if it still happens with the
header_cloned() change.

johannes

Download attachment "signature.asc" of type "application/pgp-signature" (829 bytes)

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ