[PATCH 72/97] LSM: Add secmark refcounting to call_one list - part 2

Casey Schaufler casey at schaufler-ca.com
Thu Feb 28 22:43:31 UTC 2019


Add secmark_refcount_dec and secmark_refcount_inc to the
LSM hooks for which only the designated module is called.

Signed-off-by: Casey Schaufler <casey at schaufler-ca.com>
---
 security/security.c | 2 ++
 1 file changed, 2 insertions(+)

diff --git a/security/security.c b/security/security.c
index af3f6a89ee88..fc446af4c3bf 100644
--- a/security/security.c
+++ b/security/security.c
@@ -2125,6 +2125,8 @@ int security_setprocattr(const char *lsm, const char *name, void *value,
 		loh->secctx_to_secid = secctx_to_secid;
 		loh->socket_getpeersec_stream = socket_getpeersec_stream;
 		loh->secmark_relabel_packet = secmark_relabel_packet;
+		loh->secmark_refcount_inc = secmark_refcount_inc;
+		loh->secmark_refcount_dec = secmark_refcount_dec;
 
 		return size;
 	}
-- 
2.17.0



More information about the Linux-security-module-archive mailing list