LSM: SafeSetID: add read handler

For debugging a running system, it is very helpful to be able to see what
policy the system is using. Add a read handler that can dump out a copy of
the loaded policy.

Signed-off-by: Jann Horn <jannh@google.com>
Signed-off-by: Micah Morton <mortonm@chromium.org>
This commit is contained in:
Jann Horn
2019-04-11 13:11:54 -07:00
committed by Micah Morton
parent 03638e62f5
commit fbd9acb2dc
2 changed files with 32 additions and 4 deletions

View File

@@ -41,6 +41,7 @@ struct setuid_rule {
struct setuid_ruleset {
DECLARE_HASHTABLE(rules, SETID_HASH_BITS);
char *policy_str;
struct rcu_head rcu;
};