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:	Wed, 31 Jul 2013 19:12:57 -0700 (PDT)
From:	David Miller <davem@...emloft.net>
To:	pablo@...filter.org
Cc:	netdev@...r.kernel.org
Subject: Re: [PATCH] genetlink: fix usage of NLM_F_EXCL or NLM_F_REPLACE

From: Pablo Neira Ayuso <pablo@...filter.org>
Date: Thu, 1 Aug 2013 04:00:49 +0200

> On Thu, Aug 01, 2013 at 02:37:10AM +0200, Pablo Neira Ayuso wrote:
>> On Wed, Jul 31, 2013 at 05:03:48PM -0700, David Miller wrote:
> [...]
>> > Therefore I don't see how NLM_F_REPLACE and NLM_F_EXCL can be used
>> > at all, in those places, because the check is still "& NLM_F_DUMP"
>> 
>> The kind = type&3; is doing the magic there for rtnetlink. kind == 2
>> means that this is a get command, and you can only set NLM_F_DUMP
>> using the get command.
>> 
>> Since it doesn't make sense to use NLM_F_EXCL or NLM_F_REPLACE for get
>> commands, there is no room for ambiguity and rtnetlink is fine.
> 
> I had re-read what I wrote to get your point. We can fix in a
> different way by checking for: ops->flags & GENL_CMD_CAP_DUMP, which
> means we have a .dumpit callback, so only in that case genetlink
> should interpret the flags as NLM_F_DUMP.
> 
> Please, see patch attached.

Thanks for the RFC patch, I'll think about this some more and reply.
--
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