Home
last modified time | relevance | path

Searched refs:ipcp (Results 1 – 11 of 11) sorted by relevance

/Linux-v5.15/ipc/
Dutil.c174 struct kern_ipc_perm *ipcp; in ipc_findkey() local
176 ipcp = rhashtable_lookup_fast(&ids->key_ht, &key, in ipc_findkey()
178 if (!ipcp) in ipc_findkey()
182 ipc_lock_object(ipcp); in ipc_findkey()
183 return ipcp; in ipc_findkey()
366 struct kern_ipc_perm *ipcp, in ipc_check_perms() argument
372 if (ipcperms(ns, ipcp, params->flg)) in ipc_check_perms()
375 err = ops->associate(ipcp, params->flg); in ipc_check_perms()
377 err = ipcp->id; in ipc_check_perms()
400 struct kern_ipc_perm *ipcp; in ipcget_public() local
[all …]
Dshm.c113 static void do_shm_rmid(struct ipc_namespace *ns, struct kern_ipc_perm *ipcp) in do_shm_rmid() argument
117 shp = container_of(ipcp, struct shmid_kernel, shm_perm); in do_shm_rmid()
158 struct kern_ipc_perm *ipcp = ipc_obtain_object_idr(&shm_ids(ns), id); in shm_obtain_object() local
160 if (IS_ERR(ipcp)) in shm_obtain_object()
161 return ERR_CAST(ipcp); in shm_obtain_object()
163 return container_of(ipcp, struct shmid_kernel, shm_perm); in shm_obtain_object()
168 struct kern_ipc_perm *ipcp = ipc_obtain_object_check(&shm_ids(ns), id); in shm_obtain_object_check() local
170 if (IS_ERR(ipcp)) in shm_obtain_object_check()
171 return ERR_CAST(ipcp); in shm_obtain_object_check()
173 return container_of(ipcp, struct shmid_kernel, shm_perm); in shm_obtain_object_check()
[all …]
Dmsg.c103 struct kern_ipc_perm *ipcp = ipc_obtain_object_idr(&msg_ids(ns), id); in msq_obtain_object() local
105 if (IS_ERR(ipcp)) in msq_obtain_object()
106 return ERR_CAST(ipcp); in msq_obtain_object()
108 return container_of(ipcp, struct msg_queue, q_perm); in msq_obtain_object()
114 struct kern_ipc_perm *ipcp = ipc_obtain_object_check(&msg_ids(ns), id); in msq_obtain_object_check() local
116 if (IS_ERR(ipcp)) in msq_obtain_object_check()
117 return ERR_CAST(ipcp); in msq_obtain_object_check()
119 return container_of(ipcp, struct msg_queue, q_perm); in msq_obtain_object_check()
272 static void freeque(struct ipc_namespace *ns, struct kern_ipc_perm *ipcp) in freeque() argument
277 struct msg_queue *msq = container_of(ipcp, struct msg_queue, q_perm); in freeque()
[all …]
Dsem.c480 struct kern_ipc_perm *ipcp = ipc_obtain_object_idr(&sem_ids(ns), id); in sem_obtain_object() local
482 if (IS_ERR(ipcp)) in sem_obtain_object()
483 return ERR_CAST(ipcp); in sem_obtain_object()
485 return container_of(ipcp, struct sem_array, sem_perm); in sem_obtain_object()
491 struct kern_ipc_perm *ipcp = ipc_obtain_object_check(&sem_ids(ns), id); in sem_obtain_object_check() local
493 if (IS_ERR(ipcp)) in sem_obtain_object_check()
494 return ERR_CAST(ipcp); in sem_obtain_object_check()
496 return container_of(ipcp, struct sem_array, sem_perm); in sem_obtain_object_check()
591 static int sem_more_checks(struct kern_ipc_perm *ipcp, struct ipc_params *params) in sem_more_checks() argument
595 sma = container_of(ipcp, struct sem_array, sem_perm); in sem_more_checks()
[all …]
Dutil.h142 int ipcperms(struct ipc_namespace *ns, struct kern_ipc_perm *ipcp, short flg);
204 static inline int ipc_checkid(struct kern_ipc_perm *ipcp, int id) in ipc_checkid() argument
206 return ipcid_to_seqx(id) != ipcp->seq; in ipc_checkid()
/Linux-v5.15/include/linux/
Daudit.h386 extern void __audit_ipc_obj(struct kern_ipc_perm *ipcp);
408 static inline void audit_ipc_obj(struct kern_ipc_perm *ipcp) in audit_ipc_obj() argument
411 __audit_ipc_obj(ipcp); in audit_ipc_obj()
602 static inline void audit_ipc_obj(struct kern_ipc_perm *ipcp) in audit_ipc_obj() argument
Dsecurity.h437 int security_ipc_permission(struct kern_ipc_perm *ipcp, short flag);
438 void security_ipc_getsecid(struct kern_ipc_perm *ipcp, u32 *secid);
1187 static inline int security_ipc_permission(struct kern_ipc_perm *ipcp, in security_ipc_permission() argument
1193 static inline void security_ipc_getsecid(struct kern_ipc_perm *ipcp, u32 *secid) in security_ipc_getsecid() argument
Dlsm_hook_defs.h228 LSM_HOOK(int, 0, ipc_permission, struct kern_ipc_perm *ipcp, short flag)
229 LSM_HOOK(void, LSM_RET_VOID, ipc_getsecid, struct kern_ipc_perm *ipcp,
/Linux-v5.15/kernel/
Dauditsc.c2313 void __audit_ipc_obj(struct kern_ipc_perm *ipcp) in __audit_ipc_obj() argument
2317 context->ipc.uid = ipcp->uid; in __audit_ipc_obj()
2318 context->ipc.gid = ipcp->gid; in __audit_ipc_obj()
2319 context->ipc.mode = ipcp->mode; in __audit_ipc_obj()
2321 security_ipc_getsecid(ipcp, &context->ipc.osid); in __audit_ipc_obj()
/Linux-v5.15/security/
Dsecurity.c1895 int security_ipc_permission(struct kern_ipc_perm *ipcp, short flag) in security_ipc_permission() argument
1897 return call_int_hook(ipc_permission, 0, ipcp, flag); in security_ipc_permission()
1900 void security_ipc_getsecid(struct kern_ipc_perm *ipcp, u32 *secid) in security_ipc_getsecid() argument
1903 call_void_hook(ipc_getsecid, ipcp, secid); in security_ipc_getsecid()
/Linux-v5.15/security/selinux/
Dhooks.c6423 static int selinux_ipc_permission(struct kern_ipc_perm *ipcp, short flag) in selinux_ipc_permission() argument
6436 return ipc_has_perm(ipcp, av); in selinux_ipc_permission()
6439 static void selinux_ipc_getsecid(struct kern_ipc_perm *ipcp, u32 *secid) in selinux_ipc_getsecid() argument
6441 struct ipc_security_struct *isec = selinux_ipc(ipcp); in selinux_ipc_getsecid()