• Paul Moore's avatar
    selinux,smack: remove the capability checks in the removexattr hooks · dd44477e
    Paul Moore authored
    Commit 61df7b82 ("lsm: fixup the inode xattr capability handling")
    moved the responsibility of doing the inode xattr capability checking
    out of the individual LSMs and into the LSM framework itself.
    Unfortunately, while the original commit added the capability checks
    to both the setxattr and removexattr code in the LSM framework, it
    only removed the setxattr capability checks from the individual LSMs,
    leaving duplicated removexattr capability checks in both the SELinux
    and Smack code.
    
    This patch removes the duplicated code from SELinux and Smack.
    
    Fixes: 61df7b82 ("lsm: fixup the inode xattr capability handling")
    Acked-by: default avatarCasey Schaufler <casey@schaufler-ca.com>
    Signed-off-by: default avatarPaul Moore <paul@paul-moore.com>
    dd44477e
smack_lsm.c 129 KB