Linux filesystem development
 help / color / mirror / Atom feed
* [PATCH 0/3] vfs: call audit_inode_child() in lookup_open() on failure
@ 2026-07-10 16:42 Jori Koolstra
  2026-07-10 16:42 ` [PATCH 1/3] vfs: move create error && negative dentry case in lookup_open() up Jori Koolstra
                   ` (3 more replies)
  0 siblings, 4 replies; 8+ messages in thread
From: Jori Koolstra @ 2026-07-10 16:42 UTC (permalink / raw)
  To: Alexander Viro, Christian Brauner, Paul Moore, Eric Paris
  Cc: Jan Kara, NeilBrown, linux-fsdevel, audit, linux-kernel,
	Jori Koolstra

While reworking lookup_open() to implement O_CREAT|O_DIRECTORY I came
across inconsistency in how audit_inode_child() is called in various
file create paths.

audit_inode_child() is called in may_create_dentry() so that failed
filesystem operations still register an audit entry. On success, the
entry is overwritten when, for instance, fsnotify_create() is called.
This is the calling convention in vfs_create() and vfs_mkdir().
In lookup_open(), however, when atomic_open() should have created a
file but didn't, no call to audit_inode_child() is made. The same is
true for the regular ->create() path.

On the suggestion of Brauner, I am splitting this series from the
O_CREAT|O_DIRECTORY work, so that this can be discussed with the audit
people without delaying that work.

Jori Koolstra (3):
  vfs: move create error && negative dentry case in lookup_open() up
  vfs: call audit_inode_child() in lookup_open() on failure
  fs/namei.c: update kerneldoc of atomic_open()

 fs/namei.c | 128 ++++++++++++++++++++++++++++++++---------------------
 1 file changed, 78 insertions(+), 50 deletions(-)

-- 
2.55.0


^ permalink raw reply	[flat|nested] 8+ messages in thread

end of thread, other threads:[~2026-07-24 21:10 UTC | newest]

Thread overview: 8+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2026-07-10 16:42 [PATCH 0/3] vfs: call audit_inode_child() in lookup_open() on failure Jori Koolstra
2026-07-10 16:42 ` [PATCH 1/3] vfs: move create error && negative dentry case in lookup_open() up Jori Koolstra
2026-07-24 21:10   ` Paul Moore
2026-07-10 16:42 ` [PATCH 2/3] vfs: call audit_inode_child() in lookup_open() on failure Jori Koolstra
2026-07-24 21:10   ` Paul Moore
2026-07-10 16:42 ` [PATCH 3/3] fs/namei.c: update kerneldoc of atomic_open() Jori Koolstra
2026-07-24 21:10   ` Paul Moore
2026-07-22 14:40 ` [PATCH 0/3] vfs: call audit_inode_child() in lookup_open() on failure Christian Brauner

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox