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: <CAHC9VhTWye8Pm3EUr-Fy-mxq+6H1ThtAekqZd0nXX70f8xP5rw@mail.gmail.com>
Date: Tue, 6 Aug 2024 17:55:52 -0400
From: Paul Moore <paul@...l-moore.com>
To: Zhen Lei <thunder.leizhen@...wei.com>, 
	Stephen Smalley <stephen.smalley.work@...il.com>
Cc: thunder.leizhen@...weicloud.com, Ondrej Mosnacek <omosnace@...hat.com>, 
	selinux@...r.kernel.org, linux-kernel@...r.kernel.org, 
	Nick Kralevich <nnk@...gle.com>, Jeff Vander Stoep <jeffv@...gle.com>
Subject: Re: [PATCH 1/1] selinux: Fix potential counting error in avc_add_xperms_decision()

On Tue, Aug 6, 2024 at 9:26 AM Stephen Smalley
<stephen.smalley.work@...il.com> wrote:
> On Tue, Aug 6, 2024 at 2:51 AM <thunder.leizhen@...weicloud.com> wrote:
> > From: Zhen Lei <thunder.leizhen@...wei.com>
> >
> > The count increases only when a node is successfully added to
> > the linked list.
> >
> > Fixes: fa1aa143ac4a ("selinux: extended permissions for ioctls")
> > Signed-off-by: Zhen Lei <thunder.leizhen@...wei.com>
>
> This looks correct to me ...

It looks good to me too, unless I hear any objections I'm going to
merge this into selinux/stable-6.11 and send it up to Linux during the
v6.11-rcX cycle.

> ... but I also notice that the caller is not
> checking or handling the return code for the -ENOMEM situation.

Good catch.  We should also fix this, ideally in the same PR where we
send the count/len fix.

Zhen Lei, would you mind working on a separate fix for checking the
error code in the caller?

-- 
paul-moore.com

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ