WSL2-Linux-Kernel/security/selinux/ss
Christian Göttsche 22426e1ce6 selinux: set next pointer before attaching to list
commit 70d91dc9b2 upstream.

Set the next pointer in filename_trans_read_helper() before attaching
the new node under construction to the list, otherwise garbage would be
dereferenced on subsequent failure during cleanup in the out goto label.

Cc: <stable@vger.kernel.org>
Fixes: 4300590243 ("selinux: implement new format of filename transitions")
Signed-off-by: Christian Göttsche <cgzones@googlemail.com>
Signed-off-by: Paul Moore <paul@paul-moore.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2023-08-30 16:18:17 +02:00
..
avtab.c selinux: constify some avtab function arguments 2021-05-10 21:35:02 -04:00
avtab.h selinux: constify some avtab function arguments 2021-05-10 21:35:02 -04:00
conditional.c selinux: fix double free of cond_list on error paths 2022-02-08 18:34:02 +01:00
conditional.h selinux: refactor changing booleans 2020-08-17 21:00:33 -04:00
constraint.h License cleanup: add SPDX GPL-2.0 license identifier to files with no license 2017-11-02 11:10:55 +01:00
context.c selinux: hash context structure directly 2020-04-17 16:04:34 -04:00
context.h selinux: move context hashing under sidtab 2020-04-17 16:04:38 -04:00
ebitmap.c selinux: mark some global variables __ro_after_init 2021-01-12 10:08:55 -05:00
ebitmap.h selinux: hash context structure directly 2020-04-17 16:04:34 -04:00
hashtab.c selinux: fix bad cleanup on error in hashtab_duplicate() 2022-05-25 09:57:27 +02:00
hashtab.h selinux: refactor changing booleans 2020-08-17 21:00:33 -04:00
mls.c treewide: Use fallthrough pseudo-keyword 2020-08-23 17:36:59 -05:00
mls.h selinux: hash context structure directly 2020-04-17 16:04:34 -04:00
mls_types.h License cleanup: add SPDX GPL-2.0 license identifier to files with no license 2017-11-02 11:10:55 +01:00
policydb.c selinux: set next pointer before attaching to list 2023-08-30 16:18:17 +02:00
policydb.h selinux: Add boundary check in put_entry() 2022-08-17 14:23:05 +02:00
services.c selinux: enable use of both GFP_KERNEL and GFP_ATOMIC in convert_context() 2022-10-29 10:12:54 +02:00
services.h selinux: convert policy read-write lock to RCU 2020-08-25 08:34:47 -04:00
sidtab.c selinux: enable use of both GFP_KERNEL and GFP_ATOMIC in convert_context() 2022-10-29 10:12:54 +02:00
sidtab.h selinux: enable use of both GFP_KERNEL and GFP_ATOMIC in convert_context() 2022-10-29 10:12:54 +02:00
symtab.c selinux: prepare for inlining of hashtab functions 2020-07-09 19:05:36 -04:00
symtab.h selinux: specialize symtab insert and search functions 2020-07-08 20:21:43 -04:00