]> git.proxmox.com Git - mirror_ubuntu-hirsute-kernel.git/commit
UBUNTU: SAUCE: LSM: Use lsmblob in security_secid_to_secctx
authorCasey Schaufler <casey@schaufler-ca.com>
Wed, 19 Aug 2020 16:32:48 +0000 (09:32 -0700)
committerAndrea Righi <andrea.righi@canonical.com>
Mon, 15 Feb 2021 07:25:59 +0000 (08:25 +0100)
commitad80741e8d67650b47f8602045e1c8e7504237a9
tree8ff03180e7b5c9536d8e1d0b95eda233dcc52442
parente5881044b2e856b2d790eceaf9e24e24d80d45f9
UBUNTU: SAUCE: LSM: Use lsmblob in security_secid_to_secctx

Change security_secid_to_secctx() to take a lsmblob as input
instead of a u32 secid. It will then call the LSM hooks
using the lsmblob element allocated for that module. The
callers have been updated as well. This allows for the
possibility that more than one module may be called upon
to translate a secid to a string, as can occur in the
audit code.

Reviewed-by: Kees Cook <keescook@chromium.org>
Reviewed-by: John Johansen <john.johansen@canonical.com>
Acked-by: Stephen Smalley <sds@tycho.nsa.gov>
Signed-off-by: Casey Schaufler <casey@schaufler-ca.com>
Signed-off-by: John Johansen <john.johansen@canonical.com>
Acked-by: Andrea Righi <andrea.righi@canonical.com>
Signed-off-by: Seth Forshee <seth.forshee@canonical.com>
12 files changed:
drivers/android/binder.c
include/linux/security.h
include/net/scm.h
kernel/audit.c
kernel/auditsc.c
net/ipv4/ip_sockglue.c
net/netfilter/nf_conntrack_netlink.c
net/netfilter/nf_conntrack_standalone.c
net/netfilter/nfnetlink_queue.c
net/netlabel/netlabel_unlabeled.c
net/netlabel/netlabel_user.c
security/security.c