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] [day] [month] [year] [list]
Message-ID: <14790.1332171540@redhat.com>
Date:	Mon, 19 Mar 2012 15:39:00 +0000
From:	David Howells <dhowells@...hat.com>
To:	Jeff Layton <jlayton@...hat.com>
Cc:	dhowells@...hat.com, steved@...hat.com, jmorris@...ei.org,
	linux-security-module@...r.kernel.org, keyrings@...ux-nfs.org,
	linux-nfs@...r.kernel.org, linux-kernel@...r.kernel.org
Subject: Re: [Keyrings] [PATCH 7/9] KEYS: Permit in-place link replacement in keyring list

Jeff Layton <jlayton@...hat.com> wrote:

> Why is it safe to use key_put(rcu_access_pointer(...)) ? Clearly that
> pointer will end up being dereferenced, right?

Simple.  This key_put() is called from within keyring_destroy() and that is
only ever called from the garbage collector - which is non-reentrant.  Add to
that that key_put() never actually destroys a now-unused key, but merely
schedules the gc for a future run, and it's *that* that searches out unused
keys and deletes them.

David
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ