/linux-4.1.27/kernel/ |
D | cred.c | 38 struct cred init_cred = { 62 static inline void set_cred_subscribers(struct cred *cred, int n) in set_cred_subscribers() argument 65 atomic_set(&cred->subscribers, n); in set_cred_subscribers() 69 static inline int read_cred_subscribers(const struct cred *cred) in read_cred_subscribers() argument 72 return atomic_read(&cred->subscribers); in read_cred_subscribers() 78 static inline void alter_cred_subscribers(const struct cred *_cred, int n) in alter_cred_subscribers() 81 struct cred *cred = (struct cred *) _cred; in alter_cred_subscribers() local 83 atomic_add(n, &cred->subscribers); in alter_cred_subscribers() 92 struct cred *cred = container_of(rcu, struct cred, rcu); in put_cred_rcu() local 94 kdebug("put_cred_rcu(%p)", cred); in put_cred_rcu() [all …]
|
D | uid16.c | 62 const struct cred *cred = current_cred(); in SYSCALL_DEFINE3() local 66 ruid = high2lowuid(from_kuid_munged(cred->user_ns, cred->uid)); in SYSCALL_DEFINE3() 67 euid = high2lowuid(from_kuid_munged(cred->user_ns, cred->euid)); in SYSCALL_DEFINE3() 68 suid = high2lowuid(from_kuid_munged(cred->user_ns, cred->suid)); in SYSCALL_DEFINE3() 86 const struct cred *cred = current_cred(); in SYSCALL_DEFINE3() local 90 rgid = high2lowgid(from_kgid_munged(cred->user_ns, cred->gid)); in SYSCALL_DEFINE3() 91 egid = high2lowgid(from_kgid_munged(cred->user_ns, cred->egid)); in SYSCALL_DEFINE3() 92 sgid = high2lowgid(from_kgid_munged(cred->user_ns, cred->sgid)); in SYSCALL_DEFINE3() 153 const struct cred *cred = current_cred(); in SYSCALL_DEFINE2() local 159 i = cred->group_info->ngroups; in SYSCALL_DEFINE2() [all …]
|
D | groups.c | 159 void set_groups(struct cred *new, struct group_info *group_info) in set_groups() 178 struct cred *new; in set_current_groups() 192 const struct cred *cred = current_cred(); in SYSCALL_DEFINE2() local 199 i = cred->group_info->ngroups; in SYSCALL_DEFINE2() 205 if (groups_to_user(grouplist, cred->group_info)) { in SYSCALL_DEFINE2() 257 const struct cred *cred = current_cred(); in in_group_p() local 260 if (!gid_eq(grp, cred->fsgid)) in in_group_p() 261 retval = groups_search(cred->group_info, grp); in in_group_p() 269 const struct cred *cred = current_cred(); in in_egroup_p() local 272 if (!gid_eq(grp, cred->egid)) in in_egroup_p() [all …]
|
D | user_namespace.c | 33 static void set_cred_user_ns(struct cred *cred, struct user_namespace *user_ns) in set_cred_user_ns() argument 38 cred->securebits = SECUREBITS_DEFAULT; in set_cred_user_ns() 39 cred->cap_inheritable = CAP_EMPTY_SET; in set_cred_user_ns() 40 cred->cap_permitted = CAP_FULL_SET; in set_cred_user_ns() 41 cred->cap_effective = CAP_FULL_SET; in set_cred_user_ns() 42 cred->cap_bset = CAP_FULL_SET; in set_cred_user_ns() 44 key_put(cred->request_key_auth); in set_cred_user_ns() 45 cred->request_key_auth = NULL; in set_cred_user_ns() 48 cred->user_ns = user_ns; in set_cred_user_ns() 59 int create_user_ns(struct cred *new) in create_user_ns() [all …]
|
D | sys.c | 137 const struct cred *cred = current_cred(), *pcred = __task_cred(p); in set_one_prio_perm() local 139 if (uid_eq(pcred->uid, cred->euid) || in set_one_prio_perm() 140 uid_eq(pcred->euid, cred->euid)) in set_one_prio_perm() 179 const struct cred *cred = current_cred(); in SYSCALL_DEFINE3() local 215 uid = make_kuid(cred->user_ns, who); in SYSCALL_DEFINE3() 216 user = cred->user; in SYSCALL_DEFINE3() 218 uid = cred->uid; in SYSCALL_DEFINE3() 219 else if (!uid_eq(uid, cred->uid)) { in SYSCALL_DEFINE3() 228 if (!uid_eq(uid, cred->uid)) in SYSCALL_DEFINE3() 249 const struct cred *cred = current_cred(); in SYSCALL_DEFINE2() local [all …]
|
D | auditsc.c | 359 const struct cred *cred, in audit_field_compare() argument 367 return audit_compare_uid(cred->uid, name, f, ctx); in audit_field_compare() 369 return audit_compare_gid(cred->gid, name, f, ctx); in audit_field_compare() 371 return audit_compare_uid(cred->euid, name, f, ctx); in audit_field_compare() 373 return audit_compare_gid(cred->egid, name, f, ctx); in audit_field_compare() 377 return audit_compare_uid(cred->suid, name, f, ctx); in audit_field_compare() 379 return audit_compare_gid(cred->sgid, name, f, ctx); in audit_field_compare() 381 return audit_compare_uid(cred->fsuid, name, f, ctx); in audit_field_compare() 383 return audit_compare_gid(cred->fsgid, name, f, ctx); in audit_field_compare() 386 return audit_uid_comparator(cred->uid, f->op, tsk->loginuid); in audit_field_compare() [all …]
|
D | audit.c | 1863 const struct cred *cred; in audit_log_task_info() local 1871 cred = current_cred(); in audit_log_task_info() 1887 from_kuid(&init_user_ns, cred->uid), in audit_log_task_info() 1888 from_kgid(&init_user_ns, cred->gid), in audit_log_task_info() 1889 from_kuid(&init_user_ns, cred->euid), in audit_log_task_info() 1890 from_kuid(&init_user_ns, cred->suid), in audit_log_task_info() 1891 from_kuid(&init_user_ns, cred->fsuid), in audit_log_task_info() 1892 from_kgid(&init_user_ns, cred->egid), in audit_log_task_info() 1893 from_kgid(&init_user_ns, cred->sgid), in audit_log_task_info() 1894 from_kgid(&init_user_ns, cred->fsgid), in audit_log_task_info()
|
D | signal.c | 745 const struct cred *cred = current_cred(); in kill_ok_by_cred() local 746 const struct cred *tcred = __task_cred(t); in kill_ok_by_cred() 748 if (uid_eq(cred->euid, tcred->suid) || in kill_ok_by_cred() 749 uid_eq(cred->euid, tcred->uid) || in kill_ok_by_cred() 750 uid_eq(cred->uid, tcred->suid) || in kill_ok_by_cred() 751 uid_eq(cred->uid, tcred->uid)) in kill_ok_by_cred() 1370 static int kill_as_cred_perm(const struct cred *cred, in kill_as_cred_perm() argument 1373 const struct cred *pcred = __task_cred(target); in kill_as_cred_perm() 1374 if (!uid_eq(cred->euid, pcred->suid) && !uid_eq(cred->euid, pcred->uid) && in kill_as_cred_perm() 1375 !uid_eq(cred->uid, pcred->suid) && !uid_eq(cred->uid, pcred->uid)) in kill_as_cred_perm() [all …]
|
D | ptrace.c | 221 const struct cred *cred = current_cred(), *tcred; in __ptrace_may_access() local 245 caller_uid = cred->fsuid; in __ptrace_may_access() 246 caller_gid = cred->fsgid; in __ptrace_may_access() 256 caller_uid = cred->uid; in __ptrace_may_access() 257 caller_gid = cred->gid; in __ptrace_may_access()
|
D | kmod.c | 219 struct cred *new; in ____call_usermodehelper() 503 int (*init)(struct subprocess_info *info, struct cred *new), in call_usermodehelper_setup()
|
D | tsacct.c | 33 const struct cred *tcred; in bacct_add_tsk()
|
D | nsproxy.c | 177 struct nsproxy **new_nsp, struct cred *new_cred, struct fs_struct *new_fs) in unshare_nsproxy_namespaces()
|
D | capability.c | 228 struct cred *new; in SYSCALL_DEFINE2()
|
D | Makefile | 11 notifier.o ksysfs.o cred.o reboot.o \
|
D | acct.c | 472 const struct cred *orig_cred; in do_acct_process()
|
D | cgroup.c | 2387 const struct cred *cred = current_cred(), *tcred; in __cgroup_procs_write() local 2413 if (!uid_eq(cred->euid, GLOBAL_ROOT_UID) && in __cgroup_procs_write() 2414 !uid_eq(cred->euid, tcred->uid) && in __cgroup_procs_write() 2415 !uid_eq(cred->euid, tcred->suid)) { in __cgroup_procs_write()
|
D | fork.c | 1641 atomic_dec(&p->cred->user->processes); in copy_process() 1929 struct cred *new_cred = NULL; in SYSCALL_DEFINE1()
|
/linux-4.1.27/include/linux/ |
D | cred.h | 23 struct cred; 87 extern void set_groups(struct cred *, struct group_info *); 118 struct cred { struct 157 extern void __put_cred(struct cred *); argument 160 extern const struct cred *get_task_cred(struct task_struct *); 161 extern struct cred *cred_alloc_blank(void); 162 extern struct cred *prepare_creds(void); 163 extern struct cred *prepare_exec_creds(void); 164 extern int commit_creds(struct cred *); 165 extern void abort_creds(struct cred *); [all …]
|
D | security.h | 32 struct cred; 76 extern int cap_capable(const struct cred *cred, struct user_namespace *ns, 82 extern int cap_capset(struct cred *new, const struct cred *old, 96 extern int cap_task_fix_setuid(struct cred *new, const struct cred *old, int flags); 1476 int (*capset) (struct cred *new, 1477 const struct cred *old, 1481 int (*capable) (const struct cred *cred, struct user_namespace *ns, 1593 int (*file_open) (struct file *file, const struct cred *cred); 1597 int (*cred_alloc_blank) (struct cred *cred, gfp_t gfp); 1598 void (*cred_free) (struct cred *cred); [all …]
|
D | key.h | 79 struct cred; 217 const struct cred *cred, 291 const struct cred *cred, 353 extern int install_thread_keyring_to_cred(struct cred *cred);
|
D | user_namespace.h | 55 extern int create_user_ns(struct cred *new); 56 extern int unshare_userns(unsigned long unshare_flags, struct cred **new_cred); 82 static inline int create_user_ns(struct cred *new) in create_user_ns() 88 struct cred **new_cred) in unshare_userns()
|
D | audit.h | 249 const struct cred *new, 250 const struct cred *old); 251 extern void __audit_log_capset(const struct cred *new, const struct cred *old); 308 const struct cred *new, in audit_log_bprm_fcaps() 309 const struct cred *old) in audit_log_bprm_fcaps() 316 static inline void audit_log_capset(const struct cred *new, in audit_log_capset() 317 const struct cred *old) in audit_log_capset() 424 const struct cred *new, in audit_log_bprm_fcaps() 425 const struct cred *old) in audit_log_bprm_fcaps() 429 static inline void audit_log_capset(const struct cred *new, in audit_log_capset() [all …]
|
D | kmod.h | 48 struct cred; 64 int (*init)(struct subprocess_info *info, struct cred *new); 74 int (*init)(struct subprocess_info *info, struct cred *new),
|
D | nfs_fs.h | 53 struct rpc_cred * cred; member 81 struct rpc_cred *cred; member 97 struct rpc_cred *cred; member 366 extern struct nfs_open_context *nfs_find_open_context(struct inode *inode, struct rpc_cred *cred, f… 442 return ctx->cred; in nfs_file_cred() 466 extern int nfs_may_open(struct inode *inode, struct rpc_cred *cred, int openflags);
|
D | binfmts.h | 36 struct cred *cred; /* new credentials */ member
|
D | nsproxy.h | 70 struct cred *, struct fs_struct *);
|
D | init_task.h | 130 extern struct cred init_cred; 224 RCU_POINTER_INITIALIZER(cred, &init_cred), \
|
D | nfs_xdr.h | 251 struct rpc_cred *cred; member 289 struct rpc_cred *cred; member 313 struct rpc_cred *cred; member 1324 struct rpc_cred *cred; member 1383 struct rpc_cred *cred; member 1412 struct rpc_cred *cred; member 1420 struct rpc_cred *cred; member
|
D | pnfs_osd_xdr.h | 106 void *cred; member
|
D | socket.h | 13 struct cred;
|
D | sched.h | 1456 const struct cred __rcu *real_cred; /* objective and real subjective task 1458 const struct cred __rcu *cred; /* effective (overridable) subjective task member 2396 const struct cred *, u32);
|
D | fs.h | 49 struct cred; 849 const struct cred *f_cred; 2206 extern struct file * dentry_open(const struct path *, int, const struct cred *);
|
/linux-4.1.27/net/sunrpc/ |
D | auth.c | 300 rpcauth_unhash_cred_locked(struct rpc_cred *cred) in rpcauth_unhash_cred_locked() argument 302 hlist_del_rcu(&cred->cr_hash); in rpcauth_unhash_cred_locked() 304 clear_bit(RPCAUTH_CRED_HASHED, &cred->cr_flags); in rpcauth_unhash_cred_locked() 308 rpcauth_unhash_cred(struct rpc_cred *cred) in rpcauth_unhash_cred() argument 313 cache_lock = &cred->cr_auth->au_credcache->lock; in rpcauth_unhash_cred() 315 ret = atomic_read(&cred->cr_count) == 0; in rpcauth_unhash_cred() 317 rpcauth_unhash_cred_locked(cred); in rpcauth_unhash_cred() 353 rpcauth_key_timeout_notify(struct rpc_auth *auth, struct rpc_cred *cred) in rpcauth_key_timeout_notify() argument 355 if (!cred->cr_auth->au_ops->key_timeout) in rpcauth_key_timeout_notify() 357 return cred->cr_auth->au_ops->key_timeout(auth, cred); in rpcauth_key_timeout_notify() [all …]
|
D | auth_unix.c | 63 struct unx_cred *cred; in unx_create_cred() local 71 if (!(cred = kmalloc(sizeof(*cred), GFP_NOFS))) in unx_create_cred() 74 rpcauth_init_cred(&cred->uc_base, acred, auth, &unix_credops); in unx_create_cred() 75 cred->uc_base.cr_flags = 1UL << RPCAUTH_CRED_UPTODATE; in unx_create_cred() 82 cred->uc_gid = acred->gid; in unx_create_cred() 84 cred->uc_gids[i] = GROUP_AT(acred->group_info, i); in unx_create_cred() 86 cred->uc_gids[i] = INVALID_GID; in unx_create_cred() 88 return &cred->uc_base; in unx_create_cred() 106 unx_destroy_cred(struct rpc_cred *cred) in unx_destroy_cred() argument 108 call_rcu(&cred->cr_rcu, unx_free_cred_callback); in unx_destroy_cred() [all …]
|
D | auth_generic.c | 66 struct rpc_cred *cred, int lookupflags) in generic_bind_cred() argument 69 struct auth_cred *acred = &container_of(cred, struct generic_cred, gc_base)->acred; in generic_bind_cred() 113 generic_free_cred(struct rpc_cred *cred) in generic_free_cred() argument 115 struct generic_cred *gcred = container_of(cred, struct generic_cred, gc_base); in generic_free_cred() 126 struct rpc_cred *cred = container_of(head, struct rpc_cred, cr_rcu); in generic_free_cred_callback() local 127 generic_free_cred(cred); in generic_free_cred_callback() 131 generic_destroy_cred(struct rpc_cred *cred) in generic_destroy_cred() argument 133 call_rcu(&cred->cr_rcu, generic_free_cred_callback); in generic_destroy_cred() 151 generic_match(struct auth_cred *acred, struct rpc_cred *cred, int flags) in generic_match() argument 153 struct generic_cred *gcred = container_of(cred, struct generic_cred, gc_base); in generic_match() [all …]
|
D | svcauth_unix.c | 661 struct svc_cred *cred = &rqstp->rq_cred; in svcauth_unix_set_client() local 707 gi = unix_gid_find(cred->cr_uid, rqstp); in svcauth_unix_set_client() 716 put_group_info(cred->cr_group_info); in svcauth_unix_set_client() 717 cred->cr_group_info = gi; in svcauth_unix_set_client() 729 struct svc_cred *cred = &rqstp->rq_cred; in svcauth_null_accept() local 731 cred->cr_group_info = NULL; in svcauth_null_accept() 732 cred->cr_principal = NULL; in svcauth_null_accept() 750 cred->cr_uid = INVALID_UID; in svcauth_null_accept() 751 cred->cr_gid = INVALID_GID; in svcauth_null_accept() 752 cred->cr_group_info = groups_alloc(0); in svcauth_null_accept() [all …]
|
D | auth_null.c | 47 nul_destroy_cred(struct rpc_cred *cred) in nul_destroy_cred() argument 55 nul_match(struct auth_cred *acred, struct rpc_cred *cred, int taskflags) in nul_match() argument
|
D | clnt.c | 2419 struct rpc_task *rpc_call_null(struct rpc_clnt *clnt, struct rpc_cred *cred, int flags) in rpc_call_null() argument 2423 .rpc_cred = cred, in rpc_call_null()
|
/linux-4.1.27/security/keys/ |
D | process_keys.c | 46 const struct cred *cred; in install_user_keyrings() local 54 cred = current_cred(); in install_user_keyrings() 55 user = cred->user; in install_user_keyrings() 56 uid = from_kuid(cred->user_ns, user->uid); in install_user_keyrings() 78 cred, user_keyring_perm, in install_user_keyrings() 94 cred, user_keyring_perm, in install_user_keyrings() 131 int install_thread_keyring_to_cred(struct cred *new) in install_thread_keyring_to_cred() 150 struct cred *new; in install_thread_keyring() 174 int install_process_keyring_to_cred(struct cred *new) in install_process_keyring_to_cred() 200 struct cred *new; in install_process_keyring() [all …]
|
D | request_key_auth.c | 117 if (rka->cred) { in request_key_auth_revoke() 118 put_cred(rka->cred); in request_key_auth_revoke() 119 rka->cred = NULL; in request_key_auth_revoke() 132 if (rka->cred) { in request_key_auth_destroy() 133 put_cred(rka->cred); in request_key_auth_destroy() 134 rka->cred = NULL; in request_key_auth_destroy() 151 const struct cred *cred = current->cred; in request_key_auth_new() local 173 if (cred->request_key_auth) { in request_key_auth_new() 175 down_read(&cred->request_key_auth->sem); in request_key_auth_new() 179 if (test_bit(KEY_FLAG_REVOKED, &cred->request_key_auth->flags)) in request_key_auth_new() [all …]
|
D | request_key.c | 56 static int umh_keys_init(struct subprocess_info *info, struct cred *cred) in umh_keys_init() argument 60 return install_session_keyring_to_cred(cred, keyring); in umh_keys_init() 98 const struct cred *cred = current_cred(); in call_sbin_request_key() local 116 cred = get_current_cred(); in call_sbin_request_key() 117 keyring = keyring_alloc(desc, cred->fsuid, cred->fsgid, cred, in call_sbin_request_key() 120 put_cred(cred); in call_sbin_request_key() 132 sprintf(uid_str, "%d", from_kuid(&init_user_ns, cred->fsuid)); in call_sbin_request_key() 133 sprintf(gid_str, "%d", from_kgid(&init_user_ns, cred->fsgid)); in call_sbin_request_key() 140 cred->thread_keyring ? cred->thread_keyring->serial : 0); in call_sbin_request_key() 143 if (cred->process_keyring) in call_sbin_request_key() [all …]
|
D | permission.c | 30 int key_task_permission(const key_ref_t key_ref, const struct cred *cred, in key_task_permission() argument 40 if (uid_eq(key->uid, cred->fsuid)) { in key_task_permission() 48 if (gid_eq(key->gid, cred->fsgid)) { in key_task_permission() 53 ret = groups_search(cred->group_info, key->gid); in key_task_permission() 77 return security_key_permission(key_ref, cred, perm); in key_task_permission()
|
D | internal.h | 112 const struct cred *cred; member 142 extern int install_thread_keyring_to_cred(struct cred *); 143 extern int install_process_keyring_to_cred(struct cred *); 144 extern int install_session_keyring_to_cred(struct cred *, struct key *); 173 const struct cred *cred, 190 const struct cred *cred; member
|
D | keyctl.c | 988 struct cred *new; in keyctl_change_reqkey_auth() 1013 const struct cred *cred = current_cred(); in keyctl_instantiate_key_common() local 1032 instkey = cred->request_key_auth; in keyctl_instantiate_key_common() 1180 const struct cred *cred = current_cred(); in keyctl_reject_key() local 1199 instkey = cred->request_key_auth; in keyctl_reject_key() 1237 struct cred *new; in keyctl_set_reqkey_keyring() 1468 const struct cred *mycred, *pcred; in keyctl_session_to_parent() 1471 struct cred *cred; in keyctl_session_to_parent() local 1483 cred = cred_alloc_blank(); in keyctl_session_to_parent() 1484 if (!cred) in keyctl_session_to_parent() [all …]
|
D | key.c | 225 kuid_t uid, kgid_t gid, const struct cred *cred, in key_alloc() argument 305 ret = security_key_alloc(key, cred, flags); in key_alloc() 786 const struct cred *cred = current_cred(); in key_create_or_update() local 876 cred->fsuid, cred->fsgid, cred, perm, flags); in key_create_or_update()
|
D | keyring.c | 493 const struct cred *cred, key_perm_t perm, in keyring_alloc() argument 500 uid, gid, cred, perm, flags); in keyring_alloc() 565 ctx->cred, KEY_NEED_SEARCH) < 0) { in keyring_search_iterator() 745 ctx->cred, KEY_NEED_SEARCH) < 0) in search_nested_keyrings() 867 err = key_task_permission(keyring_ref, ctx->cred, KEY_NEED_SEARCH); in keyring_search_aux() 896 .cred = current_cred(), in keyring_search()
|
D | proc.c | 190 .cred = current_cred(), in proc_keys_show() 215 rc = key_task_permission(key_ref, ctx.cred, KEY_NEED_VIEW); in proc_keys_show()
|
/linux-4.1.27/drivers/staging/lustre/lustre/libcfs/linux/ |
D | linux-curproc.c | 60 struct cred *cred; in cfs_cap_raise() local 62 cred = prepare_creds(); in cfs_cap_raise() 63 if (cred) { in cfs_cap_raise() 64 cap_raise(cred->cap_effective, cap); in cfs_cap_raise() 65 commit_creds(cred); in cfs_cap_raise() 71 struct cred *cred; in cfs_cap_lower() local 73 cred = prepare_creds(); in cfs_cap_lower() 74 if (cred) { in cfs_cap_lower() 75 cap_lower(cred->cap_effective, cap); in cfs_cap_lower() 76 commit_creds(cred); in cfs_cap_lower()
|
/linux-4.1.27/security/ |
D | commoncap.c | 76 int cap_capable(const struct cred *cred, struct user_namespace *targ_ns, in cap_capable() argument 87 if (ns == cred->user_ns) in cap_capable() 88 return cap_raised(cred->cap_effective, cap) ? 0 : -EPERM; in cap_capable() 98 if ((ns->parent == cred->user_ns) && uid_eq(ns->owner, cred->euid)) in cap_capable() 144 const struct cred *cred, *child_cred; in cap_ptrace_access_check() local 148 cred = current_cred(); in cap_ptrace_access_check() 151 caller_caps = &cred->cap_effective; in cap_ptrace_access_check() 153 caller_caps = &cred->cap_permitted; in cap_ptrace_access_check() 154 if (cred->user_ns == child_cred->user_ns && in cap_ptrace_access_check() 181 const struct cred *cred, *child_cred; in cap_ptrace_traceme() local [all …]
|
D | security.c | 191 int security_capset(struct cred *new, const struct cred *old, in security_capset() 200 int security_capable(const struct cred *cred, struct user_namespace *ns, in security_capable() argument 203 return security_ops->capable(cred, ns, cap, SECURITY_CAP_AUDIT); in security_capable() 206 int security_capable_noaudit(const struct cred *cred, struct user_namespace *ns, in security_capable_noaudit() argument 209 return security_ops->capable(cred, ns, cap, SECURITY_CAP_NOAUDIT); in security_capable_noaudit() 816 int security_file_open(struct file *file, const struct cred *cred) in security_file_open() argument 820 ret = security_ops->file_open(file, cred); in security_file_open() 840 int security_cred_alloc_blank(struct cred *cred, gfp_t gfp) in security_cred_alloc_blank() argument 842 return security_ops->cred_alloc_blank(cred, gfp); in security_cred_alloc_blank() 845 void security_cred_free(struct cred *cred) in security_cred_free() argument [all …]
|
D | capability.c | 385 static int cap_file_open(struct file *file, const struct cred *cred) in cap_file_open() argument 399 static int cap_cred_alloc_blank(struct cred *cred, gfp_t gfp) in cap_cred_alloc_blank() argument 404 static void cap_cred_free(struct cred *cred) in cap_cred_free() argument 408 static int cap_cred_prepare(struct cred *new, const struct cred *old, gfp_t gfp) in cap_cred_prepare() 413 static void cap_cred_transfer(struct cred *new, const struct cred *old) in cap_cred_transfer() 417 static int cap_kernel_act_as(struct cred *new, u32 secid) in cap_kernel_act_as() 422 static int cap_kernel_create_files_as(struct cred *new, struct inode *inode) in cap_kernel_create_files_as() 894 static int cap_key_alloc(struct key *key, const struct cred *cred, in cap_key_alloc() argument 904 static int cap_key_permission(key_ref_t key_ref, const struct cred *cred, in cap_key_permission() argument
|
/linux-4.1.27/security/tomoyo/ |
D | tomoyo.c | 18 static int tomoyo_cred_alloc_blank(struct cred *new, gfp_t gfp) in tomoyo_cred_alloc_blank() 33 static int tomoyo_cred_prepare(struct cred *new, const struct cred *old, in tomoyo_cred_prepare() 49 static void tomoyo_cred_transfer(struct cred *new, const struct cred *old) in tomoyo_cred_transfer() 59 static void tomoyo_cred_free(struct cred *cred) in tomoyo_cred_free() argument 61 struct tomoyo_domain_info *domain = cred->security; in tomoyo_cred_free() 102 bprm->cred->security)->users); in tomoyo_bprm_set_creds() 107 bprm->cred->security = NULL; in tomoyo_bprm_set_creds() 120 struct tomoyo_domain_info *domain = bprm->cred->security; in tomoyo_bprm_check_security() 328 static int tomoyo_file_open(struct file *f, const struct cred *cred) in tomoyo_file_open() argument 547 struct cred *cred = (struct cred *) current_cred(); in tomoyo_init() local [all …]
|
D | securityfs_if.c | 73 struct cred *cred = prepare_creds(); in tomoyo_write_self() local 74 if (!cred) { in tomoyo_write_self() 78 cred->security; in tomoyo_write_self() 79 cred->security = new_domain; in tomoyo_write_self() 82 commit_creds(cred); in tomoyo_write_self()
|
D | domain.c | 843 bprm->cred->security = domain; in tomoyo_find_next_domain()
|
D | common.c | 929 (!uid_eq(task->cred->uid, GLOBAL_ROOT_UID) || in tomoyo_manager() 930 !uid_eq(task->cred->euid, GLOBAL_ROOT_UID))) in tomoyo_manager()
|
/linux-4.1.27/security/apparmor/ |
D | lsm.c | 49 static void apparmor_cred_free(struct cred *cred) in apparmor_cred_free() argument 51 aa_free_task_context(cred_cxt(cred)); in apparmor_cred_free() 52 cred_cxt(cred) = NULL; in apparmor_cred_free() 58 static int apparmor_cred_alloc_blank(struct cred *cred, gfp_t gfp) in apparmor_cred_alloc_blank() argument 65 cred_cxt(cred) = cxt; in apparmor_cred_alloc_blank() 72 static int apparmor_cred_prepare(struct cred *new, const struct cred *old, in apparmor_cred_prepare() 88 static void apparmor_cred_transfer(struct cred *new, const struct cred *old) in apparmor_cred_transfer() 120 const struct cred *cred; in apparmor_capget() local 123 cred = __task_cred(target); in apparmor_capget() 124 profile = aa_cred_profile(cred); in apparmor_capget() [all …]
|
D | domain.c | 357 cxt = cred_cxt(bprm->cred); in apparmor_bprm_set_creds() 552 struct aa_task_cxt *new_cxt = cred_cxt(bprm->cred); in apparmor_bprm_committing_creds() 610 const struct cred *cred; in aa_change_hat() local 628 cred = get_current_cred(); in aa_change_hat() 629 cxt = cred_cxt(cred); in aa_change_hat() 630 profile = aa_cred_profile(cred); in aa_change_hat() 727 put_cred(cred); in aa_change_hat() 750 const struct cred *cred; in aa_change_profile() local 769 cred = get_current_cred(); in aa_change_profile() 770 profile = aa_cred_profile(cred); in aa_change_profile() [all …]
|
D | context.c | 97 struct cred *new; in aa_replace_current_profile() 135 struct cred *new = prepare_creds(); in aa_set_current_onexec() 161 struct cred *new = prepare_creds(); in aa_set_current_hat() 199 struct cred *new = prepare_creds(); in aa_restore_previous_profile()
|
/linux-4.1.27/include/linux/sunrpc/ |
D | svcauth.h | 30 static inline void init_svc_cred(struct svc_cred *cred) in init_svc_cred() argument 32 cred->cr_group_info = NULL; in init_svc_cred() 33 cred->cr_principal = NULL; in init_svc_cred() 34 cred->cr_gss_mech = NULL; in init_svc_cred() 37 static inline void free_svc_cred(struct svc_cred *cred) in free_svc_cred() argument 39 if (cred->cr_group_info) in free_svc_cred() 40 put_group_info(cred->cr_group_info); in free_svc_cred() 41 kfree(cred->cr_principal); in free_svc_cred() 42 gss_mech_put(cred->cr_gss_mech); in free_svc_cred() 43 init_svc_cred(cred); in free_svc_cred()
|
D | auth.h | 191 struct rpc_cred * get_rpccred(struct rpc_cred *cred) in get_rpccred() argument 193 atomic_inc(&cred->cr_count); in get_rpccred() 194 return cred; in get_rpccred()
|
D | clnt.h | 169 struct rpc_task *rpc_call_null(struct rpc_clnt *clnt, struct rpc_cred *cred,
|
/linux-4.1.27/fs/cifs/ |
D | cifs_spnego.c | 33 static const struct cred *spnego_cred; 108 const struct cred *saved_cred; in cifs_get_spnego_key() 190 struct cred *cred; in init_cifs_spnego() local 202 cred = prepare_kernel_cred(NULL); in init_cifs_spnego() 203 if (!cred) in init_cifs_spnego() 207 GLOBAL_ROOT_UID, GLOBAL_ROOT_GID, cred, in init_cifs_spnego() 225 cred->thread_keyring = keyring; in init_cifs_spnego() 226 cred->jit_keyring = KEY_REQKEY_DEFL_THREAD_KEYRING; in init_cifs_spnego() 227 spnego_cred = cred; in init_cifs_spnego() 235 put_cred(cred); in init_cifs_spnego()
|
D | cifsacl.c | 45 static const struct cred *root_cred; 208 const struct cred *saved_cred; in id_to_sid() 266 const struct cred *saved_cred; in sid_to_id() 343 struct cred *cred; in init_cifs_idmap() local 356 cred = prepare_kernel_cred(NULL); in init_cifs_idmap() 357 if (!cred) in init_cifs_idmap() 361 GLOBAL_ROOT_UID, GLOBAL_ROOT_GID, cred, in init_cifs_idmap() 377 cred->thread_keyring = keyring; in init_cifs_idmap() 378 cred->jit_keyring = KEY_REQKEY_DEFL_THREAD_KEYRING; in init_cifs_idmap() 379 root_cred = cred; in init_cifs_idmap() [all …]
|
/linux-4.1.27/fs/nfs/ |
D | nfs4state.c | 71 int nfs4_init_clientid(struct nfs_client *clp, struct rpc_cred *cred) in nfs4_init_clientid() argument 87 status = nfs4_proc_setclientid(clp, NFS4_CALLBACK, port, cred, &clid); in nfs4_init_clientid() 94 status = nfs4_proc_setclientid_confirm(clp, &clid, cred); in nfs4_init_clientid() 118 struct rpc_cred *cred) in nfs40_discover_server_trunking() argument 132 status = nfs4_proc_setclientid(clp, NFS4_CALLBACK, port, cred, &clid); in nfs40_discover_server_trunking() 138 status = nfs40_walk_client_list(clp, result, cred); in nfs40_discover_server_trunking() 150 struct rpc_cred *cred = NULL; in nfs4_get_machine_cred_locked() local 153 cred = get_rpccred(clp->cl_machine_cred); in nfs4_get_machine_cred_locked() 154 return cred; in nfs4_get_machine_cred_locked() 159 struct rpc_cred *cred, *new; in nfs4_root_machine_cred() local [all …]
|
D | nfs4renewd.c | 60 struct rpc_cred *cred; in nfs4_renew_state() local 82 cred = ops->get_state_renewal_cred_locked(clp); in nfs4_renew_state() 84 if (cred == NULL) { in nfs4_renew_state() 94 ret = ops->sched_state_renewal(clp, cred, renew_flags); in nfs4_renew_state() 95 put_rpccred(cred); in nfs4_renew_state()
|
D | dir.c | 70 …c struct nfs_open_dir_context *alloc_nfs_open_dir_context(struct inode *dir, struct rpc_cred *cred) in alloc_nfs_open_dir_context() argument 80 ctx->cred = get_rpccred(cred); in alloc_nfs_open_dir_context() 94 put_rpccred(ctx->cred); in put_nfs_open_dir_context() 106 struct rpc_cred *cred; in nfs_opendir() local 112 cred = rpc_lookup_cred(); in nfs_opendir() 113 if (IS_ERR(cred)) in nfs_opendir() 114 return PTR_ERR(cred); in nfs_opendir() 115 ctx = alloc_nfs_open_dir_context(inode, cred); in nfs_opendir() 129 put_rpccred(cred); in nfs_opendir() 373 struct rpc_cred *cred = ctx->cred; in nfs_readdir_xdr_filler() local [all …]
|
D | delegation.h | 17 struct rpc_cred *cred; member 37 int nfs_inode_set_delegation(struct inode *inode, struct rpc_cred *cred, struct nfs_openres *res); 38 void nfs_inode_reclaim_delegation(struct inode *inode, struct rpc_cred *cred, struct nfs_openres *r… 56 int nfs4_proc_delegreturn(struct inode *inode, struct rpc_cred *cred, const nfs4_stateid *stateid, …
|
D | unlink.c | 34 put_rpccred(data->cred); in nfs_free_unlinkdata() 122 .rpc_cred = data->cred, in nfs_do_call_unlink() 262 data->cred = rpc_lookup_cred(); in nfs_async_unlink() 263 if (IS_ERR(data->cred)) { in nfs_async_unlink() 264 status = PTR_ERR(data->cred); in nfs_async_unlink() 286 put_rpccred(data->cred); in nfs_async_unlink() 378 put_rpccred(data->cred); in nfs_async_rename_release() 423 data->cred = rpc_lookup_cred(); in nfs_async_rename() 424 if (IS_ERR(data->cred)) { in nfs_async_rename() 425 struct rpc_task *task = ERR_CAST(data->cred); in nfs_async_rename() [all …]
|
D | nfs4proc.c | 85 static int nfs4_do_setattr(struct inode *inode, struct rpc_cred *cred, 2039 static int nfs4_opendata_access(struct rpc_cred *cred, in nfs4_opendata_access() argument 2063 cache.cred = cred; in nfs4_opendata_access() 2209 struct rpc_cred *cred; in nfs41_check_delegation_stateid() local 2221 cred = get_rpccred(delegation->cred); in nfs41_check_delegation_stateid() 2223 status = nfs41_test_stateid(server, &stateid, cred); in nfs41_check_delegation_stateid() 2230 nfs41_free_stateid(server, &stateid, cred); in nfs41_check_delegation_stateid() 2234 put_rpccred(cred); in nfs41_check_delegation_stateid() 2249 struct rpc_cred *cred = state->owner->so_cred; in nfs41_check_open_stateid() local 2258 status = nfs41_test_stateid(server, stateid, cred); in nfs41_check_open_stateid() [all …]
|
D | nfs4idmap.c | 56 static const struct cred *id_resolver_cache; 189 struct cred *cred; in nfs_idmap_init_keyring() local 196 cred = prepare_kernel_cred(NULL); in nfs_idmap_init_keyring() 197 if (!cred) in nfs_idmap_init_keyring() 201 GLOBAL_ROOT_UID, GLOBAL_ROOT_GID, cred, in nfs_idmap_init_keyring() 219 cred->thread_keyring = keyring; in nfs_idmap_init_keyring() 220 cred->jit_keyring = KEY_REQKEY_DEFL_THREAD_KEYRING; in nfs_idmap_init_keyring() 221 id_resolver_cache = cred; in nfs_idmap_init_keyring() 229 put_cred(cred); in nfs_idmap_init_keyring() 298 const struct cred *saved_cred; in nfs_idmap_get_key()
|
D | delegation.c | 27 if (delegation->cred) { in nfs_free_delegation() 28 put_rpccred(delegation->cred); in nfs_free_delegation() 29 delegation->cred = NULL; in nfs_free_delegation() 165 void nfs_inode_reclaim_delegation(struct inode *inode, struct rpc_cred *cred, in nfs_inode_reclaim_delegation() argument 179 oldcred = delegation->cred; in nfs_inode_reclaim_delegation() 180 delegation->cred = get_rpccred(cred); in nfs_inode_reclaim_delegation() 191 nfs_inode_set_delegation(inode, cred, res); in nfs_inode_reclaim_delegation() 204 delegation->cred, in nfs_do_return_delegation() 326 int nfs_inode_set_delegation(struct inode *inode, struct rpc_cred *cred, struct nfs_openres *res) in nfs_inode_set_delegation() argument 342 delegation->cred = get_rpccred(cred); in nfs_inode_set_delegation()
|
D | pnfs_dev.c | 98 struct rpc_cred *cred, gfp_t gfp_flags) in nfs4_get_device_info() argument 141 rc = nfs4_proc_getdeviceinfo(server, pdev, cred); in nfs4_get_device_info() 188 const struct nfs4_deviceid *id, struct rpc_cred *cred, in nfs4_find_get_deviceid() argument 198 new = nfs4_get_device_info(server, id, cred, gfp_mask); in nfs4_find_get_deviceid()
|
D | nfs4session.c | 491 struct rpc_cred *cred; in nfs4_destroy_session() local 493 cred = nfs4_get_clid_cred(session->clp); in nfs4_destroy_session() 494 nfs4_proc_destroy_session(session, cred); in nfs4_destroy_session() 495 if (cred) in nfs4_destroy_session() 496 put_rpccred(cred); in nfs4_destroy_session()
|
D | nfs4namespace.c | 174 struct rpc_cred *cred; in nfs_find_best_sec() local 185 cred = rpcauth_lookupcred(new->cl_auth, 0); in nfs_find_best_sec() 186 if (IS_ERR(cred)) { in nfs_find_best_sec() 190 put_rpccred(cred); in nfs_find_best_sec()
|
D | inode.c | 784 struct rpc_cred *cred = rpc_lookup_cred(); in alloc_nfs_open_context() local 785 if (IS_ERR(cred)) in alloc_nfs_open_context() 786 return ERR_CAST(cred); in alloc_nfs_open_context() 790 put_rpccred(cred); in alloc_nfs_open_context() 795 ctx->cred = cred; in alloc_nfs_open_context() 830 if (ctx->cred != NULL) in __put_nfs_open_context() 831 put_rpccred(ctx->cred); in __put_nfs_open_context() 870 struct nfs_open_context *nfs_find_open_context(struct inode *inode, struct rpc_cred *cred, fmode_t … in nfs_find_open_context() argument 877 if (cred != NULL && pos->cred != cred) in nfs_find_open_context()
|
D | pagelist.c | 63 hdr->cred = hdr->req->wb_context->cred; in nfs_pgheader_init() 617 struct rpc_cred *cred, const struct nfs_rpc_ops *rpc_ops, in nfs_initiate_pgio() argument 624 .rpc_cred = cred, in nfs_initiate_pgio() 857 hdr->cred, in nfs_generic_pg_pgios() 910 return ctx1->cred == ctx2->cred && ctx1->state == ctx2->state; in nfs_match_open_context()
|
D | internal.h | 253 struct rpc_cred *cred, const struct nfs_rpc_ops *rpc_ops, 512 struct rpc_cred *cred); 515 struct rpc_cred *cred);
|
D | nfs4_fs.h | 239 extern int nfs4_proc_bind_conn_to_session(struct nfs_client *, struct rpc_cred *cred); 240 extern int nfs4_proc_exchange_id(struct nfs_client *clp, struct rpc_cred *cred);
|
D | pnfs.h | 225 struct rpc_cred *cred); 316 const struct nfs4_deviceid *id, struct rpc_cred *cred,
|
D | client.c | 153 struct rpc_cred *cred; in nfs_alloc_client() local 184 cred = rpc_lookup_machine_cred("*"); in nfs_alloc_client() 185 if (!IS_ERR(cred)) in nfs_alloc_client() 186 clp->cl_machine_cred = cred; in nfs_alloc_client()
|
D | write.c | 1144 return rpcauth_key_timeout_notify(auth, ctx->cred); in nfs_key_timeout_notify() 1152 return rpcauth_cred_key_to_expire(ctx->cred); in nfs_ctx_key_to_expire() 1550 .rpc_cred = data->cred, in nfs_initiate_commit() 1609 data->cred = first->wb_context->cred; in nfs_init_commit()
|
D | nfs4client.c | 479 struct rpc_cred *cred) in nfs40_walk_client_list() argument 528 status = nfs4_proc_setclientid_confirm(pos, &clid, cred); in nfs40_walk_client_list() 615 struct rpc_cred *cred) in nfs41_walk_client_list() argument
|
D | nfs3proc.c | 196 .rpc_cred = entry->cred, in nfs3_proc_access() 623 nfs3_proc_readdir(struct dentry *dentry, struct rpc_cred *cred, in nfs3_proc_readdir() argument 644 .rpc_cred = cred in nfs3_proc_readdir()
|
D | proc.c | 487 nfs_proc_readdir(struct dentry *dentry, struct rpc_cred *cred, in nfs_proc_readdir() argument 500 .rpc_cred = cred, in nfs_proc_readdir()
|
D | pnfs.c | 883 lgp->cred = lo->plh_lc_cred; in send_layoutget() 956 lrp->cred = lo->plh_lc_cred; in pnfs_send_layoutreturn() 1255 lo->plh_lc_cred = get_rpccred(ctx->cred); in alloc_init_layout_hdr() 2199 data->cred = get_rpccred(nfsi->layout->plh_lc_cred); in pnfs_layoutcommit_inode() 2214 put_rpccred(data->cred); in pnfs_layoutcommit_inode()
|
/linux-4.1.27/net/sunrpc/auth_gss/ |
D | auth_gss.c | 137 gss_cred_set_ctx(struct rpc_cred *cred, struct gss_cl_ctx *ctx) in gss_cred_set_ctx() argument 139 struct gss_cred *gss_cred = container_of(cred, struct gss_cred, gc_base); in gss_cred_set_ctx() 141 if (!test_bit(RPCAUTH_CRED_NEW, &cred->cr_flags)) in gss_cred_set_ctx() 145 set_bit(RPCAUTH_CRED_UPTODATE, &cred->cr_flags); in gss_cred_set_ctx() 147 clear_bit(RPCAUTH_CRED_NEW, &cred->cr_flags); in gss_cred_set_ctx() 180 gss_cred_get_ctx(struct rpc_cred *cred) in gss_cred_get_ctx() argument 182 struct gss_cred *gss_cred = container_of(cred, struct gss_cred, gc_base); in gss_cred_get_ctx() 530 gss_setup_upcall(struct gss_auth *gss_auth, struct rpc_cred *cred) in gss_setup_upcall() argument 532 struct gss_cred *gss_cred = container_of(cred, in gss_setup_upcall() 535 kuid_t uid = cred->cr_uid; in gss_setup_upcall() [all …]
|
D | svcauth_gss.c | 330 struct svc_cred cred; member 343 free_svc_cred(&rsci->cred); in rsc_free() 380 init_svc_cred(&new->cred); in rsc_init() 393 new->cred = tmp->cred; in update_rsc() 394 init_svc_cred(&tmp->cred); in update_rsc() 456 rsci.cred.cr_uid = make_kuid(&init_user_ns, id); in rsc_parse() 461 rsci.cred.cr_gid = make_kgid(&init_user_ns, id); in rsc_parse() 469 rsci.cred.cr_group_info = groups_alloc(N); in rsc_parse() 470 if (rsci.cred.cr_group_info == NULL) in rsc_parse() 482 GROUP_AT(rsci.cred.cr_group_info, i) = kgid; in rsc_parse() [all …]
|
D | gss_rpc_xdr.c | 551 struct gssx_cred *cred) in gssx_enc_cred() argument 556 err = gssx_enc_name(xdr, &cred->desired_name); in gssx_enc_cred() 561 err = dummy_enc_credel_array(xdr, &cred->elements); in gssx_enc_cred() 566 err = gssx_enc_buffer(xdr, &cred->cred_handle_reference); in gssx_enc_cred() 571 err = gssx_enc_bool(xdr, cred->needs_release); in gssx_enc_cred()
|
/linux-4.1.27/security/selinux/ |
D | hooks.c | 177 struct cred *cred = (struct cred *) current->real_cred; in cred_init_security() local 185 cred->security = tsec; in cred_init_security() 191 static inline u32 cred_sid(const struct cred *cred) in cred_sid() argument 195 tsec = cred->security; in cred_sid() 368 const struct cred *cred) in may_context_mount_sb_relabel() argument 370 const struct task_security_struct *tsec = cred->security; in may_context_mount_sb_relabel() 385 const struct cred *cred) in may_context_mount_inode_relabel() argument 387 const struct task_security_struct *tsec = cred->security; in may_context_mount_inode_relabel() 608 const struct cred *cred = current_cred(); in selinux_set_mnt_opts() local 745 rc = may_context_mount_sb_relabel(fscontext_sid, sbsec, cred); in selinux_set_mnt_opts() [all …]
|
/linux-4.1.27/arch/s390/kernel/ |
D | compat_linux.c | 135 const struct cred *cred = current_cred(); in COMPAT_SYSCALL_DEFINE3() local 139 ruid = high2lowuid(from_kuid_munged(cred->user_ns, cred->uid)); in COMPAT_SYSCALL_DEFINE3() 140 euid = high2lowuid(from_kuid_munged(cred->user_ns, cred->euid)); in COMPAT_SYSCALL_DEFINE3() 141 suid = high2lowuid(from_kuid_munged(cred->user_ns, cred->suid)); in COMPAT_SYSCALL_DEFINE3() 159 const struct cred *cred = current_cred(); in COMPAT_SYSCALL_DEFINE3() local 163 rgid = high2lowgid(from_kgid_munged(cred->user_ns, cred->gid)); in COMPAT_SYSCALL_DEFINE3() 164 egid = high2lowgid(from_kgid_munged(cred->user_ns, cred->egid)); in COMPAT_SYSCALL_DEFINE3() 165 sgid = high2lowgid(from_kgid_munged(cred->user_ns, cred->sgid)); in COMPAT_SYSCALL_DEFINE3() 224 const struct cred *cred = current_cred(); in COMPAT_SYSCALL_DEFINE2() local 230 get_group_info(cred->group_info); in COMPAT_SYSCALL_DEFINE2() [all …]
|
/linux-4.1.27/net/dns_resolver/ |
D | dns_key.c | 44 const struct cred *dns_resolver_cache; 264 struct cred *cred; in init_dns_resolver() local 274 cred = prepare_kernel_cred(NULL); in init_dns_resolver() 275 if (!cred) in init_dns_resolver() 279 GLOBAL_ROOT_UID, GLOBAL_ROOT_GID, cred, in init_dns_resolver() 295 cred->thread_keyring = keyring; in init_dns_resolver() 296 cred->jit_keyring = KEY_REQKEY_DEFL_THREAD_KEYRING; in init_dns_resolver() 297 dns_resolver_cache = cred; in init_dns_resolver() 305 put_cred(cred); in init_dns_resolver()
|
D | internal.h | 28 extern const struct cred *dns_resolver_cache;
|
D | dns_query.c | 74 const struct cred *saved_cred; in dns_query()
|
/linux-4.1.27/arch/alpha/kernel/ |
D | asm-offsets.c | 22 DEFINE(TASK_CRED, offsetof(struct task_struct, cred)); in foo() 28 DEFINE(CRED_UID, offsetof(struct cred, uid)); in foo() 29 DEFINE(CRED_EUID, offsetof(struct cred, euid)); in foo() 30 DEFINE(CRED_GID, offsetof(struct cred, gid)); in foo() 31 DEFINE(CRED_EGID, offsetof(struct cred, egid)); in foo()
|
/linux-4.1.27/net/core/ |
D | scm.c | 49 const struct cred *cred = current_cred(); in scm_check_creds() local 50 kuid_t uid = make_kuid(cred->user_ns, creds->uid); in scm_check_creds() 51 kgid_t gid = make_kgid(cred->user_ns, creds->gid); in scm_check_creds() 58 ((uid_eq(uid, cred->uid) || uid_eq(uid, cred->euid) || in scm_check_creds() 59 uid_eq(uid, cred->suid)) || ns_capable(cred->user_ns, CAP_SETUID)) && in scm_check_creds() 60 ((gid_eq(gid, cred->gid) || gid_eq(gid, cred->egid) || in scm_check_creds() 61 gid_eq(gid, cred->sgid)) || ns_capable(cred->user_ns, CAP_SETGID))) { in scm_check_creds()
|
D | sock.c | 999 static void cred_to_ucred(struct pid *pid, const struct cred *cred, in cred_to_ucred() argument 1004 if (cred) { in cred_to_ucred() 1007 ucred->uid = from_kuid_munged(current_ns, cred->euid); in cred_to_ucred() 1008 ucred->gid = from_kgid_munged(current_ns, cred->egid); in cred_to_ucred()
|
/linux-4.1.27/fs/proc/ |
D | array.c | 141 const struct cred *cred; in task_state() local 155 cred = get_task_cred(p); in task_state() 175 from_kuid_munged(user_ns, cred->uid), in task_state() 176 from_kuid_munged(user_ns, cred->euid), in task_state() 177 from_kuid_munged(user_ns, cred->suid), in task_state() 178 from_kuid_munged(user_ns, cred->fsuid), in task_state() 179 from_kgid_munged(user_ns, cred->gid), in task_state() 180 from_kgid_munged(user_ns, cred->egid), in task_state() 181 from_kgid_munged(user_ns, cred->sgid), in task_state() 182 from_kgid_munged(user_ns, cred->fsgid), in task_state() [all …]
|
D | fd.c | 87 const struct cred *cred; in tid_fd_revalidate() local 113 cred = __task_cred(task); in tid_fd_revalidate() 114 inode->i_uid = cred->euid; in tid_fd_revalidate() 115 inode->i_gid = cred->egid; in tid_fd_revalidate()
|
D | base.c | 1458 const struct cred *cred; in proc_pid_make_inode() local 1481 cred = __task_cred(task); in proc_pid_make_inode() 1482 inode->i_uid = cred->euid; in proc_pid_make_inode() 1483 inode->i_gid = cred->egid; in proc_pid_make_inode() 1500 const struct cred *cred; in pid_getattr() local 1520 cred = __task_cred(task); in pid_getattr() 1521 stat->uid = cred->euid; in pid_getattr() 1522 stat->gid = cred->egid; in pid_getattr() 1550 const struct cred *cred; in pid_revalidate() local 1562 cred = __task_cred(task); in pid_revalidate() [all …]
|
/linux-4.1.27/fs/nfs/flexfilelayout/ |
D | flexfilelayoutdev.c | 311 if (ds->ds_clp && !mirror->cred && in ff_layout_update_mirror_cred() 314 struct rpc_cred *cred; in ff_layout_update_mirror_cred() local 321 cred = auth->au_ops->lookup_cred(auth, &acred, 0); in ff_layout_update_mirror_cred() 322 if (IS_ERR(cred)) { in ff_layout_update_mirror_cred() 324 __func__, PTR_ERR(cred)); in ff_layout_update_mirror_cred() 325 return PTR_ERR(cred); in ff_layout_update_mirror_cred() 327 if (cmpxchg(&mirror->cred, NULL, cred)) in ff_layout_update_mirror_cred() 328 put_rpccred(cred); in ff_layout_update_mirror_cred() 446 struct rpc_cred *cred = ERR_PTR(-EINVAL); in ff_layout_get_ds_cred() local 451 if (mirror && mirror->cred) in ff_layout_get_ds_cred() [all …]
|
D | flexfilelayout.c | 387 if (fls->mirror_array[i]->cred) { in ff_layout_free_lseg() 388 put_rpccred(fls->mirror_array[i]->cred); in ff_layout_free_lseg() 389 fls->mirror_array[i]->cred = NULL; in ff_layout_free_lseg() 1250 ds_cred = ff_layout_get_ds_cred(lseg, idx, hdr->cred); in ff_layout_read_pagelist() 1308 ds_cred = ff_layout_get_ds_cred(lseg, idx, hdr->cred); in ff_layout_write_pagelist() 1377 ds_cred = ff_layout_get_ds_cred(lseg, idx, data->cred); in ff_layout_initiate_commit() 1387 data->cred = ds_cred; in ff_layout_initiate_commit()
|
D | flexfilelayout.h | 55 struct rpc_cred *cred; member
|
/linux-4.1.27/fs/ |
D | coredump.c | 166 const struct cred *cred = current_cred(); in format_corename() local 216 err = cn_printf(cn, "%d", cred->uid); in format_corename() 220 err = cn_printf(cn, "%d", cred->gid); in format_corename() 487 static int umh_pipe_setup(struct subprocess_info *info, struct cred *new) in umh_pipe_setup() 511 const struct cred *old_cred; in do_coredump() 512 struct cred *cred; in do_coredump() local 540 cred = prepare_creds(); in do_coredump() 541 if (!cred) in do_coredump() 551 cred->fsuid = GLOBAL_ROOT_UID; /* Dump root private */ in do_coredump() 559 old_cred = override_creds(cred); in do_coredump() [all …]
|
D | fcntl.c | 93 const struct cred *cred = current_cred(); in f_modown() local 94 filp->f_owner.uid = cred->uid; in f_modown() 95 filp->f_owner.euid = cred->euid; in f_modown() 435 const struct cred *cred; in sigio_perm() local 439 cred = __task_cred(p); in sigio_perm() 441 uid_eq(fown->euid, cred->suid) || uid_eq(fown->euid, cred->uid) || in sigio_perm() 442 uid_eq(fown->uid, cred->suid) || uid_eq(fown->uid, cred->uid)) && in sigio_perm()
|
D | open.c | 337 const struct cred *old_cred; in SYSCALL_DEFINE3() 338 struct cred *override_cred; in SYSCALL_DEFINE3() 683 const struct cred *cred) in do_dentry_open() argument 723 error = security_file_open(f, cred); in do_dentry_open() 833 const struct cred *cred) in vfs_open() argument 845 return do_dentry_open(file, inode, NULL, cred); in vfs_open() 849 const struct cred *cred) in dentry_open() argument 854 validate_creds(cred); in dentry_open() 862 error = vfs_open(path, f, cred); in dentry_open()
|
D | binfmt_elf_fdpic.c | 472 const struct cred *cred = current_cred(); in create_elf_fdpic_tables() local 621 NEW_AUX_ENT(AT_UID, (elf_addr_t) from_kuid_munged(cred->user_ns, cred->uid)); in create_elf_fdpic_tables() 622 NEW_AUX_ENT(AT_EUID, (elf_addr_t) from_kuid_munged(cred->user_ns, cred->euid)); in create_elf_fdpic_tables() 623 NEW_AUX_ENT(AT_GID, (elf_addr_t) from_kgid_munged(cred->user_ns, cred->gid)); in create_elf_fdpic_tables() 624 NEW_AUX_ENT(AT_EGID, (elf_addr_t) from_kgid_munged(cred->user_ns, cred->egid)); in create_elf_fdpic_tables() 1365 const struct cred *cred; in fill_psinfo() local 1396 cred = __task_cred(p); in fill_psinfo() 1397 SET_UID(psinfo->pr_uid, from_kuid_munged(cred->user_ns, cred->uid)); in fill_psinfo() 1398 SET_GID(psinfo->pr_gid, from_kgid_munged(cred->user_ns, cred->gid)); in fill_psinfo()
|
D | exec.c | 1147 if (!uid_eq(bprm->cred->uid, current_euid()) || in setup_new_exec() 1148 !gid_eq(bprm->cred->gid, current_egid())) { in setup_new_exec() 1175 bprm->cred = prepare_exec_creds(); in prepare_bprm_creds() 1176 if (likely(bprm->cred)) in prepare_bprm_creds() 1186 if (bprm->cred) { in free_bprm() 1188 abort_creds(bprm->cred); in free_bprm() 1219 commit_creds(bprm->cred); in install_exec_creds() 1220 bprm->cred = NULL; in install_exec_creds() 1289 bprm->cred->euid = current_euid(); in bprm_fill_uid() 1290 bprm->cred->egid = current_egid(); in bprm_fill_uid() [all …]
|
D | file_table.c | 105 const struct cred *cred = current_cred(); in get_empty_filp() local 127 f->f_cred = get_cred(cred); in get_empty_filp()
|
D | binfmt_elf.c | 168 const struct cred *cred = current_cred(); in create_elf_tables() local 243 NEW_AUX_ENT(AT_UID, from_kuid_munged(cred->user_ns, cred->uid)); in create_elf_tables() 244 NEW_AUX_ENT(AT_EUID, from_kuid_munged(cred->user_ns, cred->euid)); in create_elf_tables() 245 NEW_AUX_ENT(AT_GID, from_kgid_munged(cred->user_ns, cred->gid)); in create_elf_tables() 246 NEW_AUX_ENT(AT_EGID, from_kgid_munged(cred->user_ns, cred->egid)); in create_elf_tables() 1429 const struct cred *cred; in fill_psinfo() local 1460 cred = __task_cred(p); in fill_psinfo() 1461 SET_UID(psinfo->pr_uid, from_kuid_munged(cred->user_ns, cred->uid)); in fill_psinfo() 1462 SET_GID(psinfo->pr_gid, from_kgid_munged(cred->user_ns, cred->gid)); in fill_psinfo()
|
D | internal.h | 110 extern int vfs_open(const struct path *, struct file *, const struct cred *);
|
D | binfmt_flat.c | 827 bprm.cred = prepare_exec_creds(); in load_flat_shared_library() 829 if (!bprm.cred) in load_flat_shared_library() 843 abort_creds(bprm.cred); in load_flat_shared_library()
|
D | namei.c | 850 const struct cred *cred; in may_linkat() local 856 cred = current_cred(); in may_linkat() 862 if (uid_eq(cred->fsuid, inode->i_uid) || safe_hardlink_source(inode) || in may_linkat()
|
/linux-4.1.27/fs/cachefiles/ |
D | security.c | 22 struct cred *new; in cachefiles_get_security_ID() 81 const struct cred **_saved_cred) in cachefiles_determine_cache_security() 83 struct cred *new; in cachefiles_determine_cache_security()
|
D | interface.c | 122 const struct cred *saved_cred; in cachefiles_lookup_object() 204 const struct cred *saved_cred; in cachefiles_update_object() 255 const struct cred *saved_cred; in cachefiles_drop_object() 364 const struct cred *saved_cred; in cachefiles_sync_cache() 394 const struct cred *saved_cred; in cachefiles_check_consistency() 419 const struct cred *saved_cred; in cachefiles_attr_changed() 488 const struct cred *saved_cred; in cachefiles_invalidate_object()
|
D | internal.h | 64 const struct cred *cache_cred; /* security override for accessing cache */ 223 const struct cred **_saved_cred); 226 const struct cred **_saved_cred) in cachefiles_begin_secure() 232 const struct cred *saved_cred) in cachefiles_end_secure()
|
D | daemon.c | 556 const struct cred *saved_cred; in cachefiles_daemon_cull() 628 const struct cred *saved_cred; in cachefiles_daemon_inuse()
|
D | bind.c | 90 const struct cred *saved_cred; in cachefiles_daemon_add_cache()
|
/linux-4.1.27/drivers/misc/vmw_vmci/ |
D | vmci_context.h | 88 const struct cred *cred; member 136 const struct cred *cred);
|
D | vmci_context.c | 87 const struct cred *cred) in vmci_ctx_create() argument 149 if (cred) in vmci_ctx_create() 150 context->cred = get_cred(cred); in vmci_ctx_create() 482 if (context->cred) in ctx_free_ctx() 483 put_cred(context->cred); in ctx_free_ctx() 1206 if (context->cred) in vmci_is_context_owner() 1207 is_owner = uid_eq(context->cred->uid, uid); in vmci_is_context_owner()
|
D | vmci_host.c | 299 const struct cred *cred; in vmci_host_do_init_context() local 321 cred = get_current_cred(); in vmci_host_do_init_context() 325 cred); in vmci_host_do_init_context() 326 put_cred(cred); in vmci_host_do_init_context()
|
/linux-4.1.27/arch/mips/kernel/ |
D | mips-mt-fpaff.c | 48 const struct cred *cred = current_cred(), *pcred; in check_same_owner() local 53 match = (uid_eq(cred->euid, pcred->euid) || in check_same_owner() 54 uid_eq(cred->euid, pcred->uid)); in check_same_owner()
|
/linux-4.1.27/security/apparmor/include/ |
D | context.h | 97 static inline struct aa_profile *aa_cred_profile(const struct cred *cred) in aa_cred_profile() argument 99 struct aa_task_cxt *cxt = cred_cxt(cred); in aa_cred_profile()
|
/linux-4.1.27/security/integrity/ |
D | digsig.c | 68 const struct cred *cred = current_cred(); in integrity_init_keyring() local 72 KGIDT_INIT(0), cred, in integrity_init_keyring()
|
/linux-4.1.27/net/netfilter/ |
D | nf_log_common.c | 142 const struct cred *cred = sk->sk_socket->file->f_cred; in nf_log_dump_sk_uid_gid() local 144 from_kuid_munged(&init_user_ns, cred->fsuid), in nf_log_dump_sk_uid_gid() 145 from_kgid_munged(&init_user_ns, cred->fsgid)); in nf_log_dump_sk_uid_gid()
|
D | nfnetlink_queue_core.c | 258 const struct cred *cred; in nfqnl_put_sk_uidgid() local 265 cred = sk->sk_socket->file->f_cred; in nfqnl_put_sk_uidgid() 267 htonl(from_kuid_munged(&init_user_ns, cred->fsuid)))) in nfqnl_put_sk_uidgid() 270 htonl(from_kgid_munged(&init_user_ns, cred->fsgid)))) in nfqnl_put_sk_uidgid()
|
D | nfnetlink_log.c | 555 const struct cred *cred = file->f_cred; in __build_packet_message() local 557 __be32 uid = htonl(from_kuid_munged(user_ns, cred->fsuid)); in __build_packet_message() 558 __be32 gid = htonl(from_kgid_munged(user_ns, cred->fsgid)); in __build_packet_message()
|
/linux-4.1.27/block/ |
D | ioprio.c | 36 const struct cred *cred = current_cred(), *tcred; in set_task_ioprio() local 40 if (!uid_eq(tcred->uid, cred->euid) && in set_task_ioprio() 41 !uid_eq(tcred->uid, cred->uid) && !capable(CAP_SYS_NICE)) { in set_task_ioprio()
|
/linux-4.1.27/Documentation/security/ |
D | credentials.txt | 278 (groups, keys, LSM security) a refcounted structure of type 'struct cred'. 279 Each task points to its credentials by a pointer called 'cred' in its 300 To alter anything in the cred struct, the copy-and-replace principle must be 338 const struct cred *current_cred() 370 const struct cred *get_current_cred(void); 373 actually live in struct cred: 394 const struct cred *__task_cred(struct task_struct *task); 400 const struct cred *tcred; 415 const struct cred *get_task_cred(struct task_struct *task); 445 where 'member' is a non-pointer member of the cred struct. For instance: [all …]
|
D | keys.txt | 1000 const struct cred *cred,
|
/linux-4.1.27/drivers/connector/ |
D | cn_proc.c | 129 const struct cred *cred; in proc_id_connector() local 141 cred = __task_cred(task); in proc_id_connector() 143 ev->event_data.id.r.ruid = from_kuid_munged(&init_user_ns, cred->uid); in proc_id_connector() 144 ev->event_data.id.e.euid = from_kuid_munged(&init_user_ns, cred->euid); in proc_id_connector() 146 ev->event_data.id.r.rgid = from_kgid_munged(&init_user_ns, cred->gid); in proc_id_connector() 147 ev->event_data.id.e.egid = from_kgid_munged(&init_user_ns, cred->egid); in proc_id_connector()
|
/linux-4.1.27/fs/ecryptfs/ |
D | kthread.c | 134 const struct cred *cred) in ecryptfs_privileged_open() argument 149 (*lower_file) = dentry_open(&req.path, flags, cred); in ecryptfs_privileged_open()
|
D | main.c | 122 const struct cred *cred = current_cred(); in ecryptfs_init_lower_file() local 127 cred); in ecryptfs_init_lower_file()
|
D | ecryptfs_kernel.h | 703 const struct cred *cred);
|
/linux-4.1.27/security/smack/ |
D | smack_lsm.c | 213 static int smk_bu_credfile(const struct cred *cred, struct file *file, in smk_bu_credfile() argument 216 struct task_smack *tsp = cred->security; in smk_bu_credfile() 239 #define smk_bu_credfile(cred, file, mode, RC) (RC) argument 718 struct task_smack *bsp = bprm->cred->security; in smack_bprm_set_creds() 765 struct task_smack *bsp = bprm->cred->security; in smack_bprm_committing_creds() 1638 struct smack_known *tkp = smk_of_task(tsk->cred->security); in smack_file_send_sigiotask() 1701 static int smack_file_open(struct file *file, const struct cred *cred) in smack_file_open() argument 1703 struct task_smack *tsp = cred->security; in smack_file_open() 1714 rc = smk_bu_credfile(cred, file, MAY_READ, rc); in smack_file_open() 1732 static int smack_cred_alloc_blank(struct cred *cred, gfp_t gfp) in smack_cred_alloc_blank() argument [all …]
|
D | smackfs.c | 1689 struct smack_known *skp = smk_of_task(current->cred->security); in smk_write_onlycap()
|
/linux-4.1.27/fs/lockd/ |
D | clntproc.c | 249 nlmclnt_call(struct rpc_cred *cred, struct nlm_rqst *req, u32 proc) in nlmclnt_call() argument 258 .rpc_cred = cred, in nlmclnt_call() 394 static int nlmclnt_async_call(struct rpc_cred *cred, struct nlm_rqst *req, u32 proc, const struct r… in nlmclnt_async_call() argument 399 .rpc_cred = cred, in nlmclnt_async_call() 514 struct rpc_cred *cred = nfs_file_cred(fl->fl_file); in nlmclnt_lock() local 542 status = nlmclnt_call(cred, req, NLMPROC_LOCK); in nlmclnt_lock() 611 nlmclnt_async_call(cred, req, NLMPROC_UNLOCK, &nlmclnt_unlock_ops); in nlmclnt_lock()
|
/linux-4.1.27/security/integrity/ima/ |
D | ima_policy.c | 215 const struct cred *cred = current_cred(); in ima_match_rules() local 233 if ((rule->flags & IMA_UID) && !uid_eq(rule->uid, cred->uid)) in ima_match_rules() 237 if (!uid_eq(rule->uid, cred->euid) in ima_match_rules() 238 && !uid_eq(rule->uid, cred->suid) in ima_match_rules() 239 && !uid_eq(rule->uid, cred->uid)) in ima_match_rules() 241 } else if (!uid_eq(rule->uid, cred->euid)) in ima_match_rules()
|
/linux-4.1.27/fs/exofs/ |
D | super.c | 225 static int exofs_read_kern(struct osd_dev *od, u8 *cred, struct osd_obj_id *obj, in exofs_read_kern() argument 242 ret = osd_finalize_request(or, 0, cred, NULL); in exofs_read_kern() 596 exofs_make_credential(comp.cred, &comp.obj); in exofs_read_lookup_dev_table() 598 ret = exofs_read_kern(fscb_od, comp.cred, &comp.obj, 0, dt, in exofs_read_lookup_dev_table() 676 ret = exofs_read_kern(od, comp.cred, &comp.obj, 0, &fscb, in exofs_read_lookup_dev_table() 747 exofs_make_credential(sbi->one_comp.cred, &sbi->one_comp.obj); in exofs_fill_super() 764 exofs_make_credential(comp.cred, &comp.obj); in exofs_fill_super() 766 ret = exofs_read_kern(od, comp.cred, &comp.obj, 0, &fscb, sizeof(fscb)); in exofs_fill_super()
|
D | exofs.h | 232 exofs_make_credential(one_comp->cred, &one_comp->obj); in exofs_init_comps()
|
D | ore.c | 126 return ios->oc->comps[index & ios->oc->single_comp].cred; in _ios_cred()
|
/linux-4.1.27/fs/hppfs/ |
D | hppfs.c | 422 const struct cred *cred = file->f_cred; in hppfs_open() local 440 data->proc_file = dentry_open(&path, file_mode(file->f_mode), cred); in hppfs_open() 483 const struct cred *cred = file->f_cred; in hppfs_dir_open() local 495 data->proc_file = dentry_open(&path, file_mode(file->f_mode), cred); in hppfs_dir_open()
|
/linux-4.1.27/drivers/usb/core/ |
D | devio.c | 75 const struct cred *cred; member 86 const struct cred *cred; member 294 if (as->cred) in free_async() 295 put_cred(as->cred); in free_async() 496 const struct cred *cred = NULL; in async_completed() local 510 cred = get_cred(as->cred); in async_completed() 525 kill_pid_info_as_cred(sinfo.si_signo, &sinfo, pid, cred, secid); in async_completed() 527 put_cred(cred); in async_completed() 916 ps->cred = get_current_cred(); in usbdev_open() 958 put_cred(ps->cred); in usbdev_release() [all …]
|
/linux-4.1.27/fs/overlayfs/ |
D | dir.c | 407 const struct cred *old_cred; in ovl_create_or_link() 408 struct cred *override_cred; in ovl_create_or_link() 660 const struct cred *old_cred; in ovl_do_remove() 661 struct cred *override_cred; in ovl_do_remove() 723 const struct cred *old_cred = NULL; in ovl_rename2() 724 struct cred *override_cred = NULL; in ovl_rename2()
|
D | copy_up.c | 309 const struct cred *old_cred; in ovl_copy_up_one() 310 struct cred *override_cred; in ovl_copy_up_one()
|
D | readdir.c | 207 const struct cred *old_cred; in ovl_check_whiteouts() 208 struct cred *override_cred; in ovl_check_whiteouts()
|
/linux-4.1.27/fs/exportfs/ |
D | expfs.c | 272 const struct cred *cred = current_cred(); in get_name() local 305 file = dentry_open(path, O_RDONLY, cred); in get_name()
|
/linux-4.1.27/fs/nfs/objlayout/ |
D | objio_osd.c | 166 WARN_ON(src_comp->oc_cap.cred_len > sizeof(ocomp->cred)); in copy_single_comp() 171 memcpy(ocomp->cred, src_comp->oc_cap.cred, sizeof(ocomp->cred)); in copy_single_comp()
|
D | pnfs_osd_xdr_cli.c | 87 opaque_cred->cred = p; in _osd_xdr_decode_opaque_cred() 311 opaque_cred->cred = p; in __read_opaque_cred()
|
/linux-4.1.27/fs/nfsd/ |
D | nfs4recover.c | 68 nfs4_save_creds(const struct cred **original_creds) in nfs4_save_creds() 70 struct cred *new; in nfs4_save_creds() 84 nfs4_reset_creds(const struct cred *original) in nfs4_reset_creds() 169 const struct cred *original_cred; in nfsd4_create_clid_dir() 269 const struct cred *original_cred; in nfsd4_list_rec_dir() 339 const struct cred *original_cred; in nfsd4_remove_clid_dir() 454 const struct cred *original_cred; in nfsd4_init_recdir()
|
D | nfs4callback.c | 748 struct rpc_cred *cred; in setup_callback_client() local 777 cred = get_backchannel_cred(clp, client, ses); in setup_callback_client() 778 if (IS_ERR(cred)) { in setup_callback_client() 780 return PTR_ERR(cred); in setup_callback_client() 783 clp->cl_cb_cred = cred; in setup_callback_client()
|
D | auth.c | 24 struct cred *new; in nfsd_setuser()
|
D | nfsfh.c | 211 struct cred *new = prepare_creds(); in nfsd_set_fh_dentry()
|
/linux-4.1.27/init/ |
D | do_mounts_initrd.c | 36 static int init_linuxrc(struct subprocess_info *info, struct cred *new) in init_linuxrc()
|
/linux-4.1.27/mm/ |
D | migrate.c | 1463 const struct cred *cred = current_cred(), *tcred; in SYSCALL_DEFINE6() local 1492 if (!uid_eq(cred->euid, tcred->suid) && !uid_eq(cred->euid, tcred->uid) && in SYSCALL_DEFINE6() 1493 !uid_eq(cred->uid, tcred->suid) && !uid_eq(cred->uid, tcred->uid) && in SYSCALL_DEFINE6()
|
D | mempolicy.c | 1346 const struct cred *cred = current_cred(), *tcred; in SYSCALL_DEFINE4() local 1388 if (!uid_eq(cred->euid, tcred->suid) && !uid_eq(cred->euid, tcred->uid) && in SYSCALL_DEFINE4() 1389 !uid_eq(cred->uid, tcred->suid) && !uid_eq(cred->uid, tcred->uid) && in SYSCALL_DEFINE4()
|
/linux-4.1.27/net/rxrpc/ |
D | ar-key.c | 967 const struct cred *cred = current_cred(); in rxrpc_get_server_data_key() local 979 GLOBAL_ROOT_UID, GLOBAL_ROOT_GID, cred, 0, in rxrpc_get_server_data_key() 1021 const struct cred *cred = current_cred(); in rxrpc_get_null_key() local 1026 GLOBAL_ROOT_UID, GLOBAL_ROOT_GID, cred, in rxrpc_get_null_key()
|
/linux-4.1.27/fs/fuse/ |
D | dir.c | 1015 const struct cred *cred; in fuse_allow_current_process() local 1020 cred = current_cred(); in fuse_allow_current_process() 1021 if (uid_eq(cred->euid, fc->user_id) && in fuse_allow_current_process() 1022 uid_eq(cred->suid, fc->user_id) && in fuse_allow_current_process() 1023 uid_eq(cred->uid, fc->user_id) && in fuse_allow_current_process() 1024 gid_eq(cred->egid, fc->group_id) && in fuse_allow_current_process() 1025 gid_eq(cred->sgid, fc->group_id) && in fuse_allow_current_process() 1026 gid_eq(cred->gid, fc->group_id)) in fuse_allow_current_process()
|
/linux-4.1.27/include/scsi/ |
D | osd_ore.h | 33 u8 cred[OSD_CAP_LEN]; member
|
/linux-4.1.27/include/net/ |
D | af_vsock.h | 46 const struct cred *owner;
|
D | sock.h | 415 const struct cred *sk_peer_cred;
|
/linux-4.1.27/drivers/block/ |
D | osdblk.c | 165 void *caller_context, u8 *cred) in osd_async_op() argument 169 ret = osd_finalize_request(or, 0, cred, NULL); in osd_async_op()
|
/linux-4.1.27/lib/ |
D | vsprintf.c | 1568 const struct cred *cred = current_cred(); in pointer() local 1571 !uid_eq(cred->euid, cred->uid) || in pointer() 1572 !gid_eq(cred->egid, cred->gid)) in pointer()
|
D | Kconfig.debug | 1184 pointers from task_structs to any given cred struct, and checks to 1185 see that this number never exceeds the usage count of the cred 1189 security pointer in the cred struct is never seen to be invalid.
|
/linux-4.1.27/drivers/net/ethernet/chelsio/cxgb4vf/ |
D | sge.c | 612 unsigned int cred = fl->avail; in refill_fl() local 711 cred = fl->avail - cred; in refill_fl() 712 fl->pend_cred += cred; in refill_fl() 720 return cred; in refill_fl()
|
/linux-4.1.27/ipc/ |
D | mqueue.c | 732 const struct cred *cred = current_cred(); in do_create() local 758 return dentry_open(path, oflag, cred); in do_create()
|
/linux-4.1.27/fs/xfs/ |
D | xfs_ioctl.c | 197 const struct cred *cred = current_cred(); in xfs_open_by_handle() local 252 filp = dentry_open(&path, hreq->oflags, cred); in xfs_open_by_handle()
|
/linux-4.1.27/drivers/net/ethernet/chelsio/cxgb4/ |
D | sge.c | 592 unsigned int cred = q->avail; in refill_fl() local 662 out: cred = q->avail - cred; in refill_fl() 663 q->pend_cred += cred; in refill_fl() 672 return cred; in refill_fl()
|
/linux-4.1.27/fs/nfs/filelayout/ |
D | filelayout.c | 505 nfs_initiate_pgio(ds_clnt, hdr, hdr->cred, in filelayout_read_pagelist() 547 nfs_initiate_pgio(ds_clnt, hdr, hdr->cred, in filelayout_write_pagelist()
|
/linux-4.1.27/drivers/net/ |
D | tun.c | 418 const struct cred *cred = current_cred(); in tun_not_capable() local 421 return ((uid_valid(tun->owner) && !uid_eq(cred->euid, tun->owner)) || in tun_not_capable()
|
/linux-4.1.27/Documentation/filesystems/caching/ |
D | cachefiles.txt | 410 its own task_security structure, and redirects current->cred to point to it 432 objective security (task->real_cred) and the subjective security (task->cred).
|
/linux-4.1.27/Documentation/filesystems/ |
D | coda.txt | 391 struct CodaCred cred; /* Common to all */ 1492 struct CodaCred cred; 1545 struct CodaCred cred; 1551 DDeessccrriippttiioonn Remove all entries in the cache carrying the cred and VFid
|
D | Locking | 70 int (*dentry_open)(struct dentry *, struct file *, const struct cred *);
|
D | vfs.txt | 367 int (*dentry_open)(struct dentry *, struct file *, const struct cred *);
|
/linux-4.1.27/kernel/sched/ |
D | core.c | 3389 const struct cred *cred = current_cred(), *pcred; in check_same_owner() local 3394 match = (uid_eq(cred->euid, pcred->euid) || in check_same_owner() 3395 uid_eq(cred->euid, pcred->uid)); in check_same_owner()
|
/linux-4.1.27/arch/ia64/kernel/ |
D | perfmon.c | 2361 const struct cred *tcred; in pfm_bad_permissions()
|