Commit 26805d78 authored by John Johansen's avatar John Johansen Committed by Jiri Slaby

apparmor: fix audit full profile hname on successful load

commit 7ee6da25 upstream.

Currently logging of a successful profile load only logs the basename
of the profile. This can result in confusion when a child profile has
the same name as the another profile in the set. Logging the hname
will ensure there is no confusion.
Signed-off-by: default avatarJohn Johansen <john.johansen@canonical.com>
Acked-by: default avatarSeth Arnold <seth.arnold@canonical.com>
Signed-off-by: default avatarJiri Slaby <jslaby@suse.cz>
parent 0762dc3a
...@@ -1159,7 +1159,7 @@ ssize_t aa_replace_profiles(void *udata, size_t size, bool noreplace) ...@@ -1159,7 +1159,7 @@ ssize_t aa_replace_profiles(void *udata, size_t size, bool noreplace)
list_del_init(&ent->list); list_del_init(&ent->list);
op = (!ent->old && !ent->rename) ? OP_PROF_LOAD : OP_PROF_REPL; op = (!ent->old && !ent->rename) ? OP_PROF_LOAD : OP_PROF_REPL;
audit_policy(op, GFP_ATOMIC, ent->new->base.name, NULL, error); audit_policy(op, GFP_ATOMIC, ent->new->base.hname, NULL, error);
if (ent->old) { if (ent->old) {
__replace_profile(ent->old, ent->new, 1); __replace_profile(ent->old, ent->new, 1);
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment