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]
Date:	Sat, 3 Nov 2012 20:39:58 +0400
From:	Cyrill Gorcunov <gorcunov@...nvz.org>
To:	Pavel Emelyanov <xemul@...allels.com>
Cc:	NETDEV <netdev@...r.kernel.org>,
	David Miller <davem@...emloft.net>,
	Eric Dumazet <eric.dumazet@...il.com>
Subject: Re: [RFC] net: netlink -- Allow netlink_dump to return error code if
 protocol handler is missed

On Sat, Nov 03, 2012 at 08:17:50PM +0400, Pavel Emelyanov wrote:
> >  static int inet_diag_dump(struct sk_buff *skb, struct netlink_callback *cb)
> > Index: linux-2.6.git/net/netlink/af_netlink.c
> > ===================================================================
> > --- linux-2.6.git.orig/net/netlink/af_netlink.c
> > +++ linux-2.6.git/net/netlink/af_netlink.c
> > @@ -1740,6 +1740,10 @@ static int netlink_dump(struct sock *sk)
> >  		else
> >  			__netlink_sendskb(sk, skb);
> >  		return 0;
> > +	} else if (len < 0) {
> > +		err = len;
> > +		nlk->cb = NULL;
> > +		goto errout_skb;
> 
> When family-level handler is absent and sock_diag returns error this error
> gets propagated back to user without this fix. Why do we need it in case
> we return error from protocol-level handler?

Because as far as I can say the family-level handler already has such error
returning code in __sock_diag_rcv_msg. Or you mean something else?

	Cyrill
--
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