selinux/libselinux
Vit Mojzis f18f9e5ea1 libselinux/matchpathcon: RESOURCE_LEAK: Variable "con"
Fixes:
 Error: RESOURCE_LEAK (CWE-772):
 libselinux-3.6/src/matchpathcon.c:519: alloc_arg: "lgetfilecon_raw" allocates memory that is stored into "con". [Note: The source code implementation of the function has been overridden by a user model.]
 libselinux-3.6/src/matchpathcon.c:528: leaked_storage: Variable "con" going out of scope leaks the storage it points to.
 \#  526|
 \#  527|           if (!hnd && (matchpathcon_init_prefix(NULL, NULL) < 0))
 \#  528|->                         return -1;
 \#  529|
 \#  530|           if (selabel_lookup_raw(hnd, &fcontext, path, mode) != 0) {

Signed-off-by: Vit Mojzis <vmojzis@redhat.com>
Acked-by: James Carter <jwcart2@gmail.com>
2024-10-30 08:15:45 -04:00
..
include libselinux: formally deprecate security_compute_user() 2024-10-30 07:57:49 -04:00
man libselinux: deprecate security_disable(3) 2024-08-14 08:25:53 -04:00
src libselinux/matchpathcon: RESOURCE_LEAK: Variable "con" 2024-10-30 08:15:45 -04:00
utils tree-wide: fix misc typos 2024-06-14 09:10:56 -04:00
LICENSE
Makefile libselinux: use PCRE2 by default 2021-12-09 11:07:00 -05:00
VERSION Release 3.7 2024-06-26 17:30:41 +02:00