diff options
author | John Johansen <john.johansen@canonical.com> | 2017-01-16 00:42:55 -0800 |
---|---|---|
committer | John Johansen <john.johansen@canonical.com> | 2017-01-16 01:18:42 -0800 |
commit | 5ac8c355ae0013d82b3a07b49aebeadfce9b6e52 (patch) | |
tree | 41f24f5f9198ef4ba7a34624938e51b2305e21f0 /security/apparmor/include/crypto.h | |
parent | fc1c9fd10a53a17abb3348adb2ec5d29813a0397 (diff) |
apparmor: allow introspecting the loaded policy pre internal transform
Store loaded policy and allow introspecting it through apparmorfs. This
has several uses from debugging, policy validation, and policy checkpoint
and restore for containers.
Signed-off-by: John Johansen <john.johansen@canonical.com>
Diffstat (limited to 'security/apparmor/include/crypto.h')
-rw-r--r-- | security/apparmor/include/crypto.h | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/security/apparmor/include/crypto.h b/security/apparmor/include/crypto.h index dc418e5024d9..c1469f8db174 100644 --- a/security/apparmor/include/crypto.h +++ b/security/apparmor/include/crypto.h @@ -18,9 +18,14 @@ #ifdef CONFIG_SECURITY_APPARMOR_HASH unsigned int aa_hash_size(void); +char *aa_calc_hash(void *data, size_t len); int aa_calc_profile_hash(struct aa_profile *profile, u32 version, void *start, size_t len); #else +static inline char *aa_calc_hash(void *data, size_t len) +{ + return NULL; +} static inline int aa_calc_profile_hash(struct aa_profile *profile, u32 version, void *start, size_t len) { |