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: <1303799597.2747.214.camel@edumazet-laptop>
Date:	Tue, 26 Apr 2011 08:33:17 +0200
From:	Eric Dumazet <eric.dumazet@...il.com>
To:	Greg Rose <gregory.v.rose@...el.com>
Cc:	netdev@...r.kernel.org, bhutchings@...arflare.com,
	davem@...emloft.net
Subject: Re: [RFC PATCH] netlink: Increase netlink dump skb message size

Le lundi 25 avril 2011 à 15:01 -0700, Greg Rose a écrit :
> The message size allocated for rtnl info dumps was limited to a single page.
> This is not enough for additional interface info available with devices
> that support SR-IOV.  Check that the amount of data allocated is sufficient
> for the amount of data requested.
> 
> Signed-off-by: Greg Rose <gregory.v.rose@...el.com>
> ---
> 
>  include/linux/rtnetlink.h |    1 +
>  net/core/rtnetlink.c      |    6 ++++++
>  net/netlink/af_netlink.c  |   37 +++++++++++++++++++++++++++++++------
>  3 files changed, 38 insertions(+), 6 deletions(-)
> 

Hmm, thats a hack, because netlink_dump() is generic and you add
something very specific.

I prefer something that allows one dump() to reallocate a bigger skb

Maybe changing->dump() prototype to struct sk_buff **pskb instead of
struct sk_buff *skb.

diff --git a/net/netlink/af_netlink.c b/net/netlink/af_netlink.c
index c8f35b5..7fa6735 100644
--- a/net/netlink/af_netlink.c
+++ b/net/netlink/af_netlink.c
@@ -1681,7 +1681,7 @@ static int netlink_dump(struct sock *sk)
 		goto errout_skb;
 	}
 
-	len = cb->dump(skb, cb);
+	len = cb->dump(&skb, cb);
 
 	if (len > 0) {
 		mutex_unlock(nlk->cb_mutex);


--
To unsubscribe from this list: send the line "unsubscribe netdev" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ