apparmor: fix ptrace read check
authorJohn Johansen <john.johansen@canonical.com>
Thu, 7 Jun 2018 07:45:30 +0000 (00:45 -0700)
committerJohn Johansen <john.johansen@canonical.com>
Thu, 7 Jun 2018 08:51:02 +0000 (01:51 -0700)
commit338d0be437ef10e247a35aed83dbab182cf406a2
treea35737ad4aff38dbb6f9b228ee1999fb8b51b894
parent3ddae9876a7045a8d08ab372eff232a5da5199b8
apparmor: fix ptrace read check

The ptrace read check is incorrect resulting in policy that is
broader than it needs to be. Fix the check so that read access
permission can be properly detected when other ptrace flags are
set.

Fixes: b2d09ae449ce ("apparmor: move ptrace checks to using labels")
Signed-off-by: John Johansen <john.johansen@canonical.com>
security/apparmor/lsm.c