[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-Id: <20200831.120250.1316279201672077612.davem@davemloft.net>
Date: Mon, 31 Aug 2020 12:02:50 -0700 (PDT)
From: David Miller <davem@...emloft.net>
To: johannes@...solutions.net
Cc: netdev@...r.kernel.org, kuba@...nel.org,
linux-kernel@...r.kernel.org, syzkaller-bugs@...glegroups.com,
johannes.berg@...el.com,
syzbot+353df1490da781637624@...kaller.appspotmail.com
Subject: Re: [PATCH] netlink: policy: correct validation type check
From: Johannes Berg <johannes@...solutions.net>
Date: Mon, 31 Aug 2020 20:28:05 +0200
> From: Johannes Berg <johannes.berg@...el.com>
>
> In the policy export for binary attributes I erroneously used
> a != NLA_VALIDATE_NONE comparison instead of checking for the
> two possible values, which meant that if a validation function
> pointer ended up aliasing the min/max as negatives, we'd hit
> a warning in nla_get_range_unsigned().
>
> Fix this to correctly check for only the two types that should
> be handled here, i.e. range with or without warn-too-long.
>
> Reported-by: syzbot+353df1490da781637624@...kaller.appspotmail.com
> Fixes: 8aa26c575fb3 ("netlink: make NLA_BINARY validation more flexible")
> Signed-off-by: Johannes Berg <johannes.berg@...el.com>
Applied, thank you.
Powered by blists - more mailing lists