Home
last modified time | relevance | path

Searched refs:user_namespace (Results 1 – 64 of 64) sorted by relevance

/linux-4.1.27/include/linux/
Duidgid.h17 struct user_namespace;
18 extern struct user_namespace init_user_ns;
122 extern kuid_t make_kuid(struct user_namespace *from, uid_t uid);
123 extern kgid_t make_kgid(struct user_namespace *from, gid_t gid);
125 extern uid_t from_kuid(struct user_namespace *to, kuid_t uid);
126 extern gid_t from_kgid(struct user_namespace *to, kgid_t gid);
127 extern uid_t from_kuid_munged(struct user_namespace *to, kuid_t uid);
128 extern gid_t from_kgid_munged(struct user_namespace *to, kgid_t gid);
130 static inline bool kuid_has_mapping(struct user_namespace *ns, kuid_t uid) in kuid_has_mapping()
135 static inline bool kgid_has_mapping(struct user_namespace *ns, kgid_t gid) in kgid_has_mapping()
[all …]
Duser_namespace.h25 struct user_namespace { struct
30 struct user_namespace *parent; argument
44 extern struct user_namespace init_user_ns; argument
48 static inline struct user_namespace *get_user_ns(struct user_namespace *ns) in get_user_ns()
57 extern void free_user_ns(struct user_namespace *ns);
59 static inline void put_user_ns(struct user_namespace *ns) in put_user_ns()
74 extern bool userns_may_setgroups(const struct user_namespace *ns);
77 static inline struct user_namespace *get_user_ns(struct user_namespace *ns) in get_user_ns()
95 static inline void put_user_ns(struct user_namespace *ns) in put_user_ns()
99 static inline bool userns_may_setgroups(const struct user_namespace *ns) in userns_may_setgroups()
Dprojid.h16 struct user_namespace;
17 extern struct user_namespace init_user_ns;
52 extern kprojid_t make_kprojid(struct user_namespace *from, projid_t projid);
54 extern projid_t from_kprojid(struct user_namespace *to, kprojid_t projid);
55 extern projid_t from_kprojid_munged(struct user_namespace *to, kprojid_t projid);
57 static inline bool kprojid_has_mapping(struct user_namespace *ns, kprojid_t projid) in kprojid_has_mapping()
64 static inline kprojid_t make_kprojid(struct user_namespace *from, projid_t projid) in make_kprojid()
69 static inline projid_t from_kprojid(struct user_namespace *to, kprojid_t kprojid) in from_kprojid()
74 static inline projid_t from_kprojid_munged(struct user_namespace *to, kprojid_t kprojid) in from_kprojid_munged()
82 static inline bool kprojid_has_mapping(struct user_namespace *ns, kprojid_t projid) in kprojid_has_mapping()
Dutsname.h20 struct user_namespace;
21 extern struct user_namespace init_user_ns;
26 struct user_namespace *user_ns;
38 struct user_namespace *user_ns, struct uts_namespace *old_ns);
55 struct user_namespace *user_ns, struct uts_namespace *old_ns) in copy_utsname()
Dcapability.h41 struct user_namespace;
43 struct user_namespace *current_user_ns(void);
211 struct user_namespace *ns, int cap);
214 struct user_namespace *ns, int cap);
216 extern bool ns_capable(struct user_namespace *ns, int cap);
223 struct user_namespace *ns, int cap) in has_ns_capability()
232 struct user_namespace *ns, int cap) in has_ns_capability_noaudit()
240 static inline bool ns_capable(struct user_namespace *ns, int cap) in ns_capable()
246 extern bool file_ns_capable(const struct file *file, struct user_namespace *ns, int cap);
Dipc_namespace.h11 struct user_namespace;
60 struct user_namespace *user_ns;
117 struct user_namespace *user_ns, struct ipc_namespace *ns);
129 struct user_namespace *user_ns, struct ipc_namespace *ns) in copy_ipcs()
Dpid_namespace.h42 struct user_namespace *user_ns;
63 struct user_namespace *user_ns, struct pid_namespace *ns);
77 struct user_namespace *user_ns, struct pid_namespace *ns) in copy_pid_ns()
Dmnt_namespace.h7 struct user_namespace;
10 struct user_namespace *, struct fs_struct *);
Dtsacct_kern.h13 extern void bacct_add_tsk(struct user_namespace *user_ns,
17 static inline void bacct_add_tsk(struct user_namespace *user_ns, in bacct_add_tsk()
Dseq_file.h16 struct user_namespace;
31 struct user_namespace *user_ns;
141 static inline struct user_namespace *seq_user_ns(struct seq_file *seq) in seq_user_ns()
146 extern struct user_namespace init_user_ns; in seq_user_ns()
Dposix_acl_xattr.h67 struct posix_acl *posix_acl_from_xattr(struct user_namespace *user_ns,
69 int posix_acl_to_xattr(struct user_namespace *user_ns,
Dquota.h79 extern qid_t from_kqid(struct user_namespace *to, struct kqid qid);
80 extern qid_t from_kqid_munged(struct user_namespace *to, struct kqid qid);
97 static inline struct kqid make_kqid(struct user_namespace *from, in make_kqid()
Dnetlink.h175 struct user_namespace *ns, int cap);
177 struct user_namespace *ns, int cap);
Dinet_diag.h32 struct user_namespace *user_ns,
Dcred.h152 struct user_namespace *user_ns; /* user_ns the caps and keyrings are relative to. */
368 extern struct user_namespace init_user_ns;
Dsecurity.h69 struct user_namespace;
76 extern int cap_capable(const struct cred *cred, struct user_namespace *ns,
1481 int (*capable) (const struct cred *cred, struct user_namespace *ns,
1785 int security_capable(const struct cred *cred, struct user_namespace *ns,
1787 int security_capable_noaudit(const struct cred *cred, struct user_namespace *ns,
2016 struct user_namespace *ns, int cap) in security_capable()
2022 struct user_namespace *ns, int cap) { in security_capable_noaudit()
Dsched.h431 struct user_namespace;
/linux-4.1.27/kernel/
Duser_namespace.c30 struct user_namespace *ns, int cap_setid,
33 static void set_cred_user_ns(struct cred *cred, struct user_namespace *user_ns) in set_cred_user_ns()
61 struct user_namespace *ns, *parent_ns = new->user_ns; in create_user_ns()
137 void free_user_ns(struct user_namespace *ns) in free_user_ns()
139 struct user_namespace *parent; in free_user_ns()
238 kuid_t make_kuid(struct user_namespace *ns, uid_t uid) in make_kuid()
257 uid_t from_kuid(struct user_namespace *targ, kuid_t kuid) in from_kuid()
282 uid_t from_kuid_munged(struct user_namespace *targ, kuid_t kuid) in from_kuid_munged()
306 kgid_t make_kgid(struct user_namespace *ns, gid_t gid) in make_kgid()
325 gid_t from_kgid(struct user_namespace *targ, kgid_t kgid) in from_kgid()
[all …]
Dcapability.c296 struct user_namespace *ns, int cap) in has_ns_capability()
336 struct user_namespace *ns, int cap) in has_ns_capability_noaudit()
375 bool ns_capable(struct user_namespace *ns, int cap) in ns_capable()
420 bool file_ns_capable(const struct file *file, struct user_namespace *ns, in file_ns_capable()
444 struct user_namespace *ns = current_user_ns(); in capable_wrt_inode_uidgid()
Dutsname.c35 static struct uts_namespace *clone_uts_ns(struct user_namespace *user_ns, in clone_uts_ns()
67 struct user_namespace *user_ns, struct uts_namespace *old_ns) in copy_utsname()
Dgroups.c67 struct user_namespace *user_ns = current_user_ns(); in groups_to_user()
84 struct user_namespace *user_ns = current_user_ns(); in groups_from_user()
216 struct user_namespace *user_ns = current_user_ns(); in may_setgroups()
Dnsproxy.c60 struct task_struct *tsk, struct user_namespace *user_ns, in create_new_namespaces()
127 struct user_namespace *user_ns = task_cred_xxx(tsk, user_ns); in copy_namespaces()
179 struct user_namespace *user_ns; in unshare_nsproxy_namespaces()
Duid16.c114 struct user_namespace *user_ns = current_user_ns(); in groups16_to_user()
132 struct user_namespace *user_ns = current_user_ns(); in groups16_from_user()
Dpid_namespace.c82 static struct pid_namespace *create_pid_namespace(struct user_namespace *user_ns, in create_pid_namespace()
154 struct user_namespace *user_ns, struct pid_namespace *old_ns) in copy_pid_ns()
Duser.c25 struct user_namespace init_user_ns = {
Dtsacct.c29 void bacct_add_tsk(struct user_namespace *user_ns, in bacct_add_tsk()
Dsys.c331 struct user_namespace *ns = current_user_ns(); in SYSCALL_DEFINE2()
388 struct user_namespace *ns = current_user_ns(); in SYSCALL_DEFINE1()
464 struct user_namespace *ns = current_user_ns(); in SYSCALL_DEFINE2()
535 struct user_namespace *ns = current_user_ns(); in SYSCALL_DEFINE1()
582 struct user_namespace *ns = current_user_ns(); in SYSCALL_DEFINE3()
669 struct user_namespace *ns = current_user_ns(); in SYSCALL_DEFINE3()
1808 struct user_namespace *ns = current_user_ns(); in validate_prctl_map()
Dcred.c380 const struct user_namespace *set_ns = set->user_ns; in cred_cap_issubset()
381 const struct user_namespace *subset_ns = subset->user_ns; in cred_cap_issubset()
DMakefile60 obj-$(CONFIG_USER_NS) += user_namespace.o
Dtaskstats.c169 static void fill_stats(struct user_namespace *user_ns, in fill_stats()
Dptrace.c210 static int ptrace_has_cap(struct user_namespace *ns, unsigned int mode) in ptrace_has_cap()
/linux-4.1.27/security/keys/
Dpersistent.c22 static int key_create_persistent_register(struct user_namespace *ns) in key_create_persistent_register()
42 static key_ref_t key_create_persistent(struct user_namespace *ns, kuid_t uid, in key_create_persistent()
75 static long key_get_persistent(struct user_namespace *ns, kuid_t uid, in key_get_persistent()
131 struct user_namespace *ns = current_user_ns(); in keyctl_get_persistent()
Dproc.c87 struct user_namespace *user_ns = seq_user_ns(p); in key_serial_next()
106 struct user_namespace *user_ns = seq_user_ns(p); in find_ge_key()
272 static struct rb_node *__key_user_next(struct user_namespace *user_ns, struct rb_node *n) in __key_user_next()
283 static struct rb_node *key_user_next(struct user_namespace *user_ns, struct rb_node *n) in key_user_next()
288 static struct rb_node *key_user_first(struct user_namespace *user_ns, struct rb_root *r) in key_user_first()
/linux-4.1.27/include/net/
Dnet_namespace.h32 struct user_namespace;
60 struct user_namespace *user_ns; /* Owning user namespace */
144 struct net *copy_net_ns(unsigned long flags, struct user_namespace *user_ns,
151 struct user_namespace *user_ns, struct net *old_net) in copy_net_ns()
Dscm.h121 struct user_namespace *current_ns = current_user_ns(); in scm_recv()
Dsock.h686 static inline struct user_namespace *sk_user_ns(struct sock *sk) in sk_user_ns()
2249 struct user_namespace *user_ns, int cap);
/linux-4.1.27/fs/quota/
Dkqid.c67 qid_t from_kqid(struct user_namespace *targ, struct kqid kqid) in from_kqid()
100 qid_t from_kqid_munged(struct user_namespace *targ, struct kqid kqid) in from_kqid_munged()
/linux-4.1.27/ipc/
Dnamespace.c19 static struct ipc_namespace *create_ipc_ns(struct user_namespace *user_ns, in create_ipc_ns()
55 struct user_namespace *user_ns, struct ipc_namespace *ns) in copy_ipcs()
Dmsg.c1015 struct user_namespace *user_ns = seq_user_ns(s); in sysvipc_msg_proc_show()
Dshm.c1367 struct user_namespace *user_ns = seq_user_ns(s); in sysvipc_shm_proc_show()
Dmqueue.c77 struct user_namespace *notify_user_ns;
Dsem.c2180 struct user_namespace *user_ns = seq_user_ns(s); in sysvipc_sem_proc_show()
/linux-4.1.27/fs/
Dposix_acl.c605 struct user_namespace *to, struct user_namespace *from, in posix_acl_fix_xattr_userns()
645 struct user_namespace *user_ns = current_user_ns(); in posix_acl_fix_xattr_from_user()
653 struct user_namespace *user_ns = current_user_ns(); in posix_acl_fix_xattr_to_user()
663 posix_acl_from_xattr(struct user_namespace *user_ns, in posix_acl_from_xattr()
732 posix_acl_to_xattr(struct user_namespace *user_ns, const struct posix_acl *acl, in posix_acl_to_xattr()
Dmount.h12 struct user_namespace *user_ns;
Dpnode.c200 static struct user_namespace *user_ns;
Dfcntl.c221 struct user_namespace *user_ns = current_user_ns(); in f_getowner_uids()
Dnamespace.c2369 struct user_namespace *user_ns = current->nsproxy->mnt_ns->user_ns; in do_new_mount()
2739 static struct mnt_namespace *alloc_mnt_ns(struct user_namespace *user_ns) in alloc_mnt_ns()
2764 struct user_namespace *user_ns, struct fs_struct *new_fs) in copy_mnt_ns()
Dinode.c1903 struct user_namespace *ns; in inode_owner_or_capable()
/linux-4.1.27/arch/s390/kernel/
Dcompat_linux.c186 struct user_namespace *user_ns = current_user_ns(); in groups16_to_user()
203 struct user_namespace *user_ns = current_user_ns(); in groups16_from_user()
/linux-4.1.27/security/
Dcommoncap.c76 int cap_capable(const struct cred *cred, struct user_namespace *targ_ns, in cap_capable()
79 struct user_namespace *ns = targ_ns; in cap_capable()
Dsecurity.c200 int security_capable(const struct cred *cred, struct user_namespace *ns, in security_capable()
206 int security_capable_noaudit(const struct cred *cred, struct user_namespace *ns, in security_capable_noaudit()
/linux-4.1.27/net/netfilter/
Dnfnetlink_log.c65 struct user_namespace *peer_user_ns; /* User namespace of the peer process */
155 u32 portid, struct user_namespace *user_ns) in instance_create()
556 struct user_namespace *user_ns = inst->peer_user_ns; in __build_packet_message()
/linux-4.1.27/net/packet/
Ddiag.c132 struct user_namespace *user_ns, in sk_diag_fill()
/linux-4.1.27/net/ipv4/
Dinet_diag.c109 struct user_namespace *user_ns, in inet_sk_diag_fill()
253 struct user_namespace *user_ns, in inet_csk_diag_fill()
333 struct user_namespace *user_ns, in sk_diag_fill()
Dsysctl_net_ipv4.c117 struct user_namespace *user_ns = current_user_ns(); in ipv4_ping_group_range()
/linux-4.1.27/net/core/
Dnet_namespace.c233 static __net_init int setup_net(struct net *net, struct user_namespace *user_ns) in setup_net()
312 struct user_namespace *user_ns, struct net *old_net) in copy_net_ns()
Dsock.c159 struct user_namespace *user_ns, int cap) in sk_ns_capable()
1005 struct user_namespace *current_ns = current_user_ns(); in cred_to_ucred()
/linux-4.1.27/fs/autofs4/
Dwaitq.c149 struct user_namespace *user_ns = sbi->pipe->f_cred->user_ns; in autofs4_notify_daemon()
/linux-4.1.27/fs/proc/
Dbase.c2402 struct user_namespace *ns = NULL; in proc_id_map_open()
2434 struct user_namespace *ns = seq->private; in proc_id_map_release()
2480 struct user_namespace *ns = NULL; in proc_setgroups_open()
2515 struct user_namespace *ns = seq->private; in proc_setgroups_release()
Darray.c137 struct user_namespace *user_ns = seq_user_ns(m); in task_state()
/linux-4.1.27/security/apparmor/
Dlsm.c139 static int apparmor_capable(const struct cred *cred, struct user_namespace *ns, in apparmor_capable()
/linux-4.1.27/net/sunrpc/
Dsvcauth_unix.c549 struct user_namespace *user_ns = &init_user_ns; in unix_gid_show()
/linux-4.1.27/net/netlink/
Daf_netlink.c1377 struct user_namespace *user_ns, int cap) in __netlink_ns_capable()
1396 struct user_namespace *user_ns, int cap) in netlink_ns_capable()
/linux-4.1.27/security/selinux/
Dhooks.c2057 static int selinux_capable(const struct cred *cred, struct user_namespace *ns, in selinux_capable()