/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() 160 struct rpc_cred *cred = NULL; in nfs4_get_renew_cred_server_locked() 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() 92 ops->sched_state_renewal(clp, cred, renew_flags); in nfs4_renew_state() 93 put_rpccred(cred); in nfs4_renew_state()
|
D | dir.c | 67 …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 76 ctx->cred = get_rpccred(cred); in alloc_nfs_open_dir_context() 84 put_rpccred(ctx->cred); in put_nfs_open_dir_context() 96 struct rpc_cred *cred; in nfs_opendir() local 104 cred = rpc_lookup_cred(); in nfs_opendir() 105 if (IS_ERR(cred)) in nfs_opendir() 106 return PTR_ERR(cred); in nfs_opendir() 107 ctx = alloc_nfs_open_dir_context(inode, cred); in nfs_opendir() 121 put_rpccred(cred); in nfs_opendir() 357 struct rpc_cred *cred = ctx->cred; in nfs_readdir_xdr_filler() local [all …]
|
D | unlink.c | 31 put_rpccred(data->cred); in nfs_free_unlinkdata() 118 .rpc_cred = data->cred, in nfs_do_call_unlink() 251 data->cred = rpc_lookup_cred(); in nfs_async_unlink() 252 if (IS_ERR(data->cred)) { in nfs_async_unlink() 253 status = PTR_ERR(data->cred); in nfs_async_unlink() 275 put_rpccred(data->cred); in nfs_async_unlink() 365 put_rpccred(data->cred); in nfs_async_rename_release() 409 data->cred = rpc_lookup_cred(); in nfs_async_rename() 410 if (IS_ERR(data->cred)) { in nfs_async_rename() 411 struct rpc_task *task = ERR_CAST(data->cred); in nfs_async_rename() [all …]
|
D | delegation.h | 17 struct rpc_cred *cred; member 36 int nfs_inode_set_delegation(struct inode *inode, struct rpc_cred *cred, struct nfs_openres *res); 37 void nfs_inode_reclaim_delegation(struct inode *inode, struct rpc_cred *cred, struct nfs_openres *r… 55 int nfs4_proc_delegreturn(struct inode *inode, struct rpc_cred *cred, const nfs4_stateid *stateid, …
|
D | delegation.c | 26 if (delegation->cred) { in nfs_free_delegation() 27 put_rpccred(delegation->cred); in nfs_free_delegation() 28 delegation->cred = NULL; in nfs_free_delegation() 141 void nfs_inode_reclaim_delegation(struct inode *inode, struct rpc_cred *cred, in nfs_inode_reclaim_delegation() argument 155 oldcred = delegation->cred; in nfs_inode_reclaim_delegation() 156 delegation->cred = get_rpccred(cred); in nfs_inode_reclaim_delegation() 167 nfs_inode_set_delegation(inode, cred, res); in nfs_inode_reclaim_delegation() 178 res = nfs4_proc_delegreturn(inode, delegation->cred, &delegation->stateid, issync); in nfs_do_return_delegation() 288 int nfs_inode_set_delegation(struct inode *inode, struct rpc_cred *cred, struct nfs_openres *res) in nfs_inode_set_delegation() argument 304 delegation->cred = get_rpccred(cred); in nfs_inode_set_delegation()
|
D | idmap.c | 55 static const struct cred *id_resolver_cache; 185 struct cred *cred; in nfs_idmap_init_keyring() local 192 cred = prepare_kernel_cred(NULL); in nfs_idmap_init_keyring() 193 if (!cred) in nfs_idmap_init_keyring() 197 GLOBAL_ROOT_UID, GLOBAL_ROOT_GID, cred, in nfs_idmap_init_keyring() 215 cred->thread_keyring = keyring; in nfs_idmap_init_keyring() 216 cred->jit_keyring = KEY_REQKEY_DEFL_THREAD_KEYRING; in nfs_idmap_init_keyring() 217 id_resolver_cache = cred; in nfs_idmap_init_keyring() 225 put_cred(cred); in nfs_idmap_init_keyring() 270 const struct cred *saved_cred; in nfs_idmap_request_key()
|
D | nfs4proc.c | 82 static int nfs4_do_setattr(struct inode *inode, struct rpc_cred *cred, 1717 static int nfs4_opendata_access(struct rpc_cred *cred, in nfs4_opendata_access() argument 1741 cache.cred = cred; in nfs4_opendata_access() 1985 struct rpc_cred *cred, in _nfs4_do_open() argument 1998 sp = nfs4_get_state_owner(server, cred, GFP_KERNEL); in _nfs4_do_open() 2034 status = nfs4_do_setattr(state->inode, cred, in _nfs4_do_open() 2068 struct rpc_cred *cred, in nfs4_do_open() argument 2078 status = _nfs4_do_open(dir, dentry, fmode, flags, sattr, cred, in nfs4_do_open() 2123 static int _nfs4_do_setattr(struct inode *inode, struct rpc_cred *cred, in _nfs4_do_setattr() argument 2142 .rpc_cred = cred, in _nfs4_do_setattr() [all …]
|
D | nfs4session.c | 442 struct rpc_cred *cred; in nfs4_destroy_session() local 444 cred = nfs4_get_exchange_id_cred(session->clp); in nfs4_destroy_session() 445 nfs4_proc_destroy_session(session, cred); in nfs4_destroy_session() 446 if (cred) in nfs4_destroy_session() 447 put_rpccred(cred); in nfs4_destroy_session()
|
/fs/proc/ |
D | array.c | 170 const struct cred *cred; in task_state() local 182 cred = get_task_cred(p); in task_state() 195 from_kuid_munged(user_ns, cred->uid), in task_state() 196 from_kuid_munged(user_ns, cred->euid), in task_state() 197 from_kuid_munged(user_ns, cred->suid), in task_state() 198 from_kuid_munged(user_ns, cred->fsuid), in task_state() 199 from_kgid_munged(user_ns, cred->gid), in task_state() 200 from_kgid_munged(user_ns, cred->egid), in task_state() 201 from_kgid_munged(user_ns, cred->sgid), in task_state() 202 from_kgid_munged(user_ns, cred->fsgid)); in task_state() [all …]
|
D | fd.c | 77 const struct cred *cred; in tid_fd_revalidate() local 103 cred = __task_cred(task); in tid_fd_revalidate() 104 inode->i_uid = cred->euid; in tid_fd_revalidate() 105 inode->i_gid = cred->egid; in tid_fd_revalidate()
|
/fs/ |
D | coredump.c | 154 const struct cred *cred = current_cred(); in format_corename() local 191 err = cn_printf(cn, "%d", cred->uid); in format_corename() 195 err = cn_printf(cn, "%d", cred->gid); in format_corename() 467 static int umh_pipe_setup(struct subprocess_info *info, struct cred *new) in umh_pipe_setup() 491 const struct cred *old_cred; in do_coredump() 492 struct cred *cred; in do_coredump() local 520 cred = prepare_creds(); in do_coredump() 521 if (!cred) in do_coredump() 532 cred->fsuid = GLOBAL_ROOT_UID; /* Dump root private */ in do_coredump() 540 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() 425 const struct cred *cred; in sigio_perm() local 429 cred = __task_cred(p); in sigio_perm() 431 uid_eq(fown->euid, cred->suid) || uid_eq(fown->euid, cred->uid) || in sigio_perm() 432 uid_eq(fown->uid, cred->suid) || uid_eq(fown->uid, cred->uid)) && in sigio_perm()
|
D | exec.c | 1129 if (!uid_eq(bprm->cred->uid, current_euid()) || in setup_new_exec() 1130 !gid_eq(bprm->cred->gid, current_egid())) { in setup_new_exec() 1159 bprm->cred = prepare_exec_creds(); in prepare_bprm_creds() 1160 if (likely(bprm->cred)) in prepare_bprm_creds() 1170 if (bprm->cred) { in free_bprm() 1172 abort_creds(bprm->cred); in free_bprm() 1199 commit_creds(bprm->cred); in install_exec_creds() 1200 bprm->cred = NULL; in install_exec_creds() 1285 bprm->cred->euid = current_euid(); in prepare_binprm() 1286 bprm->cred->egid = current_egid(); in prepare_binprm() [all …]
|
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()
|
D | binfmt_elf_fdpic.c | 480 const struct cred *cred = current_cred(); in create_elf_fdpic_tables() local 629 NEW_AUX_ENT(AT_UID, (elf_addr_t) from_kuid_munged(cred->user_ns, cred->uid)); in create_elf_fdpic_tables() 630 NEW_AUX_ENT(AT_EUID, (elf_addr_t) from_kuid_munged(cred->user_ns, cred->euid)); in create_elf_fdpic_tables() 631 NEW_AUX_ENT(AT_GID, (elf_addr_t) from_kgid_munged(cred->user_ns, cred->gid)); in create_elf_fdpic_tables() 632 NEW_AUX_ENT(AT_EGID, (elf_addr_t) from_kgid_munged(cred->user_ns, cred->egid)); in create_elf_fdpic_tables() 1391 const struct cred *cred; in fill_psinfo() local 1422 cred = __task_cred(p); in fill_psinfo() 1423 SET_UID(psinfo->pr_uid, from_kuid_munged(cred->user_ns, cred->uid)); in fill_psinfo() 1424 SET_GID(psinfo->pr_gid, from_kgid_munged(cred->user_ns, cred->gid)); in fill_psinfo()
|
D | open.c | 310 const struct cred *old_cred; in SYSCALL_DEFINE3() 311 struct cred *override_cred; in SYSCALL_DEFINE3() 679 const struct cred *cred) in do_dentry_open() argument 711 error = security_file_open(f, cred); in do_dentry_open() 803 const struct cred *cred) in dentry_open() argument 808 validate_creds(cred); in dentry_open() 817 error = do_dentry_open(f, NULL, cred); in dentry_open()
|
/fs/sdcardfs/ |
D | inode.c | 26 const struct cred *override_fsids(struct sdcardfs_sb_info *sbi, in override_fsids() 29 struct cred *cred; in override_fsids() local 30 const struct cred *old_cred; in override_fsids() 33 cred = prepare_creds(); in override_fsids() 34 if (!cred) in override_fsids() 45 cred->fsuid = uid; in override_fsids() 46 cred->fsgid = sbi->options.fs_low_gid; in override_fsids() 48 old_cred = override_creds(cred); in override_fsids() 54 void revert_fsids(const struct cred *old_cred) in revert_fsids() 56 const struct cred *cur_cred; in revert_fsids() [all …]
|
D | lookup.c | 285 const struct cred *cred = current_cred(); in __sdcardfs_lookup() local 298 file = dentry_open(lower_parent_path, O_RDONLY, cred); in __sdcardfs_lookup() 421 const struct cred *saved_cred = NULL; in sdcardfs_lookup()
|
/fs/cachefiles/ |
D | security.c | 22 struct cred *new; in cachefiles_get_security_ID() 85 const struct cred **_saved_cred) in cachefiles_determine_cache_security() 87 struct cred *new; in cachefiles_determine_cache_security()
|
D | internal.h | 57 const struct cred *cache_cred; /* security override for accessing cache */ 216 const struct cred **_saved_cred); 219 const struct cred **_saved_cred) in cachefiles_begin_secure() 225 const struct cred *saved_cred) in cachefiles_end_secure()
|
D | interface.c | 124 const struct cred *saved_cred; in cachefiles_lookup_object() 207 const struct cred *saved_cred; in cachefiles_update_object() 249 const struct cred *saved_cred; in cachefiles_drop_object() 351 const struct cred *saved_cred; in cachefiles_sync_cache() 381 const struct cred *saved_cred; in cachefiles_attr_changed() 450 const struct cred *saved_cred; in cachefiles_invalidate_object()
|
/fs/cifs/ |
D | cifsacl.c | 45 static const struct cred *root_cred; 209 const struct cred *saved_cred; in id_to_sid() 267 const struct cred *saved_cred; in sid_to_id() 344 struct cred *cred; in init_cifs_idmap() local 357 cred = prepare_kernel_cred(NULL); in init_cifs_idmap() 358 if (!cred) in init_cifs_idmap() 362 GLOBAL_ROOT_UID, GLOBAL_ROOT_GID, cred, in init_cifs_idmap() 378 cred->thread_keyring = keyring; in init_cifs_idmap() 379 cred->jit_keyring = KEY_REQKEY_DEFL_THREAD_KEYRING; in init_cifs_idmap() 380 root_cred = cred; in init_cifs_idmap() [all …]
|
/fs/ecryptfs/ |
D | kthread.c | 133 const struct cred *cred) in ecryptfs_privileged_open() argument 148 (*lower_file) = dentry_open(&req.path, flags, cred); in ecryptfs_privileged_open()
|
/fs/lockd/ |
D | clntproc.c | 248 nlmclnt_call(struct rpc_cred *cred, struct nlm_rqst *req, u32 proc) in nlmclnt_call() argument 257 .rpc_cred = cred, in nlmclnt_call() 393 static int nlmclnt_async_call(struct rpc_cred *cred, struct nlm_rqst *req, u32 proc, const struct r… in nlmclnt_async_call() argument 398 .rpc_cred = cred, in nlmclnt_async_call() 513 struct rpc_cred *cred = nfs_file_cred(fl->fl_file); in nlmclnt_lock() local 541 status = nlmclnt_call(cred, req, NLMPROC_LOCK); in nlmclnt_lock() 610 nlmclnt_async_call(cred, req, NLMPROC_UNLOCK, &nlmclnt_unlock_ops); in nlmclnt_lock()
|