audit: audit feature to set loginuid immutable
This adds a new 'audit_feature' bit which allows userspace to set it such that the loginuid is absolutely immutable, even if you have CAP_AUDIT_CONTROL. Signed-off-by: Eric Paris <eparis@redhat.com> Signed-off-by: Richard Guy Briggs <rgb@redhat.com> Signed-off-by: Eric Paris <eparis@redhat.com>
This commit is contained in:
parent
d040e5af38
commit
21b85c31d2
3 changed files with 7 additions and 2 deletions
|
@ -387,7 +387,8 @@ struct audit_features {
|
|||
};
|
||||
|
||||
#define AUDIT_FEATURE_ONLY_UNSET_LOGINUID 0
|
||||
#define AUDIT_LAST_FEATURE AUDIT_FEATURE_ONLY_UNSET_LOGINUID
|
||||
#define AUDIT_FEATURE_LOGINUID_IMMUTABLE 1
|
||||
#define AUDIT_LAST_FEATURE AUDIT_FEATURE_LOGINUID_IMMUTABLE
|
||||
|
||||
#define audit_feature_valid(x) ((x) >= 0 && (x) <= AUDIT_LAST_FEATURE)
|
||||
#define AUDIT_FEATURE_TO_MASK(x) (1 << ((x) & 31)) /* mask for __u32 */
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue