]> git.baikalelectronics.ru Git - kernel.git/commit
dump_common_audit_data(): fix racy accesses to ->d_name
authorAl Viro <viro@zeniv.linux.org.uk>
Tue, 5 Jan 2021 19:43:46 +0000 (14:43 -0500)
committerAl Viro <viro@zeniv.linux.org.uk>
Sat, 16 Jan 2021 20:11:35 +0000 (15:11 -0500)
commit2511bb9de7858a30232818f3ffcb83f010ed15ae
tree7252b0d4174a46d062a76fea648fdde2fd992f9a
parent272a62df41fb3f543fcf2ebc111d92d1f034b8b5
dump_common_audit_data(): fix racy accesses to ->d_name

We are not guaranteed the locking environment that would prevent
dentry getting renamed right under us.  And it's possible for
old long name to be freed after rename, leading to UAF here.

Cc: stable@kernel.org # v2.6.2+
Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
security/lsm_audit.c