summaryrefslogtreecommitdiff
path: root/security/apparmor/task.c
diff options
context:
space:
mode:
authorJohn Johansen <john.johansen@canonical.com>2022-04-19 16:25:55 -0700
committerJohn Johansen <john.johansen@canonical.com>2022-10-03 14:49:03 -0700
commit8c4b785a86be1219f7d50f7b38266c454d6a9bbc (patch)
tree80e4ed818228d64dae3d8f5b90b009c0a2015e40 /security/apparmor/task.c
parent90917d5b6866df79d892087ba51b46c983d2fcfe (diff)
apparmor: add mediation class information to auditing
Audit messages currently don't contain the mediation class which can make them less clear than they should be in some circumstances. With newer mediation classes coming this potential confusion will become worse. Fix this by adding the mediatin class to the messages. Signed-off-by: John Johansen <john.johansen@canonical.com>
Diffstat (limited to 'security/apparmor/task.c')
-rw-r--r--security/apparmor/task.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/security/apparmor/task.c b/security/apparmor/task.c
index 503dc0877fb1..b19900f85c14 100644
--- a/security/apparmor/task.c
+++ b/security/apparmor/task.c
@@ -285,7 +285,7 @@ int aa_may_ptrace(struct aa_label *tracer, struct aa_label *tracee,
{
struct aa_profile *profile;
u32 xrequest = request << PTRACE_PERM_SHIFT;
- DEFINE_AUDIT_DATA(sa, LSM_AUDIT_DATA_NONE, OP_PTRACE);
+ DEFINE_AUDIT_DATA(sa, LSM_AUDIT_DATA_NONE, AA_CLASS_PTRACE, OP_PTRACE);
return xcheck_labels(tracer, tracee, profile,
profile_tracer_perm(profile, tracee, request, &sa),