apparmor: Fix failed mount permission check error message
authorJohn Johansen <john.johansen@canonical.com>
Tue, 25 Jan 2022 08:37:42 +0000 (00:37 -0800)
committerJohn Johansen <john.johansen@canonical.com>
Wed, 26 Jan 2022 09:33:06 +0000 (01:33 -0800)
commit7b4c6bfb3b41fe5e26fcd836f32ce8dbdd6f99d0
treea339f0d58a8a06ac01f3c5414fd2bc841ad22253
parenta5a122fe88a5cd1f07866fd4615f1c5c8aa4981e
apparmor: Fix failed mount permission check error message

When the mount check fails due to a permission check failure instead
of explicitly at one of the subcomponent checks, AppArmor is reporting
a failure in the flags match. However this is not true and AppArmor
can not attribute the error at this point to any particular component,
and should only indicate the mount failed due to missing permissions.

Fixes: 2ea3ffb7782a ("apparmor: add mount mediation")
Signed-off-by: John Johansen <john.johansen@canonical.com>
security/apparmor/mount.c