[PATCH v3 2/5] LSM: Replace context+len with lsm_context
Paul Moore
paul at paul-moore.com
Thu Oct 31 22:53:38 UTC 2024
On Oct 23, 2024 Casey Schaufler <casey at schaufler-ca.com> wrote:
>
> Replace the (secctx,seclen) pointer pair with a single
> lsm_context pointer to allow return of the LSM identifier
> along with the context and context length. This allows
> security_release_secctx() to know how to release the
> context. Callers have been modified to use or save the
> returned data from the new structure.
>
> security_secid_to_secctx() and security_lsmproc_to_secctx()
> will now return the length value on success instead of 0.
>
> Signed-off-by: Casey Schaufler <casey at schaufler-ca.com>
> Cc: netdev at vger.kernel.org
> Cc: audit at vger.kernel.org
> Cc: netfilter-devel at vger.kernel.org
> Cc: Todd Kjos <tkjos at google.com>
> ---
> drivers/android/binder.c | 5 ++-
> include/linux/lsm_hook_defs.h | 5 ++-
> include/linux/security.h | 9 +++---
> include/net/scm.h | 5 ++-
> kernel/audit.c | 9 +++---
> kernel/auditsc.c | 16 ++++------
> net/ipv4/ip_sockglue.c | 4 +--
> net/netfilter/nf_conntrack_netlink.c | 8 ++---
> net/netfilter/nf_conntrack_standalone.c | 4 +--
> net/netfilter/nfnetlink_queue.c | 27 +++++++---------
> net/netlabel/netlabel_unlabeled.c | 14 +++------
> net/netlabel/netlabel_user.c | 3 +-
> security/apparmor/include/secid.h | 5 ++-
> security/apparmor/secid.c | 26 +++++++--------
> security/security.c | 34 +++++++++-----------
> security/selinux/hooks.c | 23 +++++++++++---
> security/smack/smack_lsm.c | 42 +++++++++++++++----------
> 17 files changed, 118 insertions(+), 121 deletions(-)
See my note on patch 1/5, merging into lsm/dev.
--
paul-moore.com
More information about the Linux-security-module-archive
mailing list