UPSTREAM: security: Add a "locked down" LSM hook
Add a mechanism to allow LSMs to make a policy decision around whether kernel functionality that would allow tampering with or examining the runtime state of the kernel should be permitted. Change-Id: Ie70dc489691e2f8413fe593c633a00e6e97bd63a Signed-off-by: Matthew Garrett <mjg59@google.com> Acked-by: Kees Cook <keescook@chromium.org> Acked-by: Casey Schaufler <casey@schaufler-ca.com> Signed-off-by: James Morris <jmorris@namei.org> Signed-off-by: Sorayukii <sorayukii69@gmail.com>
This commit is contained in:
parent
09b536572a
commit
4429a0e046
1 changed files with 46 additions and 0 deletions
|
|
@ -1741,3 +1741,10 @@ int security_perf_event_write(struct perf_event *event)
|
|||
return call_int_hook(perf_event_write, 0, event);
|
||||
}
|
||||
#endif /* CONFIG_PERF_EVENTS */
|
||||
|
||||
int security_locked_down(enum lockdown_reason what)
|
||||
{
|
||||
return call_int_hook(locked_down, 0, what);
|
||||
}
|
||||
EXPORT_SYMBOL(security_locked_down);
|
||||
|
||||
|
|
|
|||
Loading…
Reference in a new issue