[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <20250619-fixpunkt-querfeldein-53eb22d0135f@brauner>
Date: Thu, 19 Jun 2025 12:38:25 +0200
From: Christian Brauner <brauner@...nel.org>
To: Vlastimil Babka <vbabka@...e.cz>
Cc: Shivank Garg <shivankg@....com>, david@...hat.com,
akpm@...ux-foundation.org, paul@...l-moore.com, rppt@...nel.org, viro@...iv.linux.org.uk,
seanjc@...gle.com, willy@...radead.org, pbonzini@...hat.com, tabba@...gle.com,
afranji@...gle.com, ackerleytng@...gle.com, jack@...e.cz, hch@...radead.org,
cgzones@...glemail.com, ira.weiny@...el.com, roypat@...zon.co.uk,
linux-fsdevel@...r.kernel.org, linux-mm@...ck.org, linux-kernel@...r.kernel.org,
linux-security-module@...r.kernel.org
Subject: Re: [PATCH] fs: export anon_inode_make_secure_inode() and fix
secretmem LSM bypass
On Thu, Jun 19, 2025 at 11:13:49AM +0200, Vlastimil Babka wrote:
> On 6/19/25 09:31, Shivank Garg wrote:
> > Export anon_inode_make_secure_inode() to allow KVM guest_memfd to create
> > anonymous inodes with proper security context. This replaces the current
> > pattern of calling alloc_anon_inode() followed by
> > inode_init_security_anon() for creating security context manually.
> >
> > This change also fixes a security regression in secretmem where the
> > S_PRIVATE flag was not cleared after alloc_anon_inode(), causing
> > LSM/SELinux checks to be bypassed for secretmem file descriptors.
> >
> > As guest_memfd currently resides in the KVM module, we need to export this
>
> Could we use the new EXPORT_SYMBOL_GPL_FOR_MODULES() thingy to make this
> explicit for KVM?
Oh? Enlighten me about that, if you have a second, please.
Powered by blists - more mailing lists