aboutsummaryrefslogtreecommitdiffstats
path: root/security/capability.c
diff options
context:
space:
mode:
Diffstat (limited to 'security/capability.c')
-rw-r--r--security/capability.c19
1 files changed, 19 insertions, 0 deletions
diff --git a/security/capability.c b/security/capability.c
index 06400cf07757..93a2ffe65905 100644
--- a/security/capability.c
+++ b/security/capability.c
@@ -373,6 +373,11 @@ static int cap_task_create(unsigned long clone_flags)
373 return 0; 373 return 0;
374} 374}
375 375
376static int cap_cred_alloc_blank(struct cred *cred, gfp_t gfp)
377{
378 return 0;
379}
380
376static void cap_cred_free(struct cred *cred) 381static void cap_cred_free(struct cred *cred)
377{ 382{
378} 383}
@@ -386,6 +391,10 @@ static void cap_cred_commit(struct cred *new, const struct cred *old)
386{ 391{
387} 392}
388 393
394static void cap_cred_transfer(struct cred *new, const struct cred *old)
395{
396}
397
389static int cap_kernel_act_as(struct cred *new, u32 secid) 398static int cap_kernel_act_as(struct cred *new, u32 secid)
390{ 399{
391 return 0; 400 return 0;
@@ -836,6 +845,13 @@ static int cap_key_getsecurity(struct key *key, char **_buffer)
836 return 0; 845 return 0;
837} 846}
838 847
848static int cap_key_session_to_parent(const struct cred *cred,
849 const struct cred *parent_cred,
850 struct key *key)
851{
852 return 0;
853}
854
839#endif /* CONFIG_KEYS */ 855#endif /* CONFIG_KEYS */
840 856
841#ifdef CONFIG_AUDIT 857#ifdef CONFIG_AUDIT
@@ -961,9 +977,11 @@ void security_fixup_ops(struct security_operations *ops)
961 set_to_cap_if_null(ops, file_receive); 977 set_to_cap_if_null(ops, file_receive);
962 set_to_cap_if_null(ops, dentry_open); 978 set_to_cap_if_null(ops, dentry_open);
963 set_to_cap_if_null(ops, task_create); 979 set_to_cap_if_null(ops, task_create);
980 set_to_cap_if_null(ops, cred_alloc_blank);
964 set_to_cap_if_null(ops, cred_free); 981 set_to_cap_if_null(ops, cred_free);
965 set_to_cap_if_null(ops, cred_prepare); 982 set_to_cap_if_null(ops, cred_prepare);
966 set_to_cap_if_null(ops, cred_commit); 983 set_to_cap_if_null(ops, cred_commit);
984 set_to_cap_if_null(ops, cred_transfer);
967 set_to_cap_if_null(ops, kernel_act_as); 985 set_to_cap_if_null(ops, kernel_act_as);
968 set_to_cap_if_null(ops, kernel_create_files_as); 986 set_to_cap_if_null(ops, kernel_create_files_as);
969 set_to_cap_if_null(ops, kernel_module_request); 987 set_to_cap_if_null(ops, kernel_module_request);
@@ -1063,6 +1081,7 @@ void security_fixup_ops(struct security_operations *ops)
1063 set_to_cap_if_null(ops, key_free); 1081 set_to_cap_if_null(ops, key_free);
1064 set_to_cap_if_null(ops, key_permission); 1082 set_to_cap_if_null(ops, key_permission);
1065 set_to_cap_if_null(ops, key_getsecurity); 1083 set_to_cap_if_null(ops, key_getsecurity);
1084 set_to_cap_if_null(ops, key_session_to_parent);
1066#endif /* CONFIG_KEYS */ 1085#endif /* CONFIG_KEYS */
1067#ifdef CONFIG_AUDIT 1086#ifdef CONFIG_AUDIT
1068 set_to_cap_if_null(ops, audit_rule_init); 1087 set_to_cap_if_null(ops, audit_rule_init);