/kernel/linux/common_modules/container_escape_detection/core/ |
H A D | ced_detection.c | 36 ced_log_error("tgid is %d, %s container escape is detected!!!!", current->tgid, gEventContent[type - 1]); in print_container_escape_detection() 72 static struct point_info *point_search(pid_t tgid) in point_search() argument 77 pid_t result = point->tgid; in point_search() 78 if (result > tgid) in point_search() 80 else if (result < tgid) in point_search() 89 static bool point_insert(pid_t tgid, struct process_info *info) in point_insert() argument 98 result = point->tgid; in point_insert() 100 if (result > tgid) in point_insert() 102 else if (result < tgid) in point_insert() 197 check_tree_and_attribute(pid_t tgid, struct process_info *current_info, struct point_info **point) check_tree_and_attribute() argument 210 check_cred_atrribute(pid_t tgid, const struct cred *new) check_cred_atrribute() argument 222 check_nsproxy_atrribute(pid_t tgid, const struct nsproxy *new) check_nsproxy_atrribute() argument [all...] |
/kernel/linux/linux-5.10/kernel/bpf/preload/ |
H A D | bpf_preload_kern.c | 54 struct pid *tgid; in finish() local 64 tgid = umd_ops.info.tgid; in finish() 65 if (tgid) { in finish() 66 wait_event(tgid->wait_pidfd, thread_group_exited(tgid)); in finish() 86 struct pid *tgid; in fini_umd() local 91 tgid = umd_ops.info.tgid; in fini_umd() 92 if (tgid) { in fini_umd() [all...] |
/kernel/linux/linux-5.10/tools/testing/selftests/bpf/progs/ |
H A D | test_core_reloc_kernel.c | 28 int tgid; member 42 int pid, tgid; in test_core_kernel() local 48 CORE_READ(&tgid, &task->tgid)) in test_core_kernel() 51 /* validate pid + tgid matches */ in test_core_kernel() 52 out->valid[0] = (((uint64_t)pid << 32) | tgid) == pid_tgid; in test_core_kernel() 56 tgid) == real_tgid; in test_core_kernel() 59 tgid) == real_tgid; in test_core_kernel() 62 tgid) == real_tgid; in test_core_kernel() 65 tgid) in test_core_kernel() [all...] |
H A D | bpf_iter_test_kern3.c | 13 int tgid; in dump_task() local 15 tgid = task->tgid; in dump_task() 16 bpf_seq_write(seq, &tgid, sizeof(tgid)); in dump_task()
|
H A D | bpf_iter_task_file.c | 10 int tgid = 0; variable 25 BPF_SEQ_PRINTF(seq, " tgid gid fd file\n"); in dump_task_file() 28 if (tgid == task->tgid && task->tgid != task->pid) in dump_task_file() 31 BPF_SEQ_PRINTF(seq, "%8d %8d %8d %lx\n", task->tgid, task->pid, fd, in dump_task_file()
|
H A D | test_core_retro.c | 8 int tgid; member 29 int tgid = BPF_CORE_READ(task, tgid); in handle_sys_enter() local 38 bpf_map_update_elem(&results, &zero, &tgid, 0); in handle_sys_enter()
|
/kernel/linux/linux-6.6/tools/testing/selftests/bpf/progs/ |
H A D | test_core_reloc_kernel.c | 29 int tgid; member 57 int pid, tgid; in test_core_kernel() local 63 CORE_READ(&tgid, &task->tgid)) in test_core_kernel() 66 /* validate pid + tgid matches */ in test_core_kernel() 67 out->valid[0] = (((uint64_t)pid << 32) | tgid) == pid_tgid; in test_core_kernel() 71 tgid) == real_tgid; in test_core_kernel() 74 tgid) == real_tgid; in test_core_kernel() 77 tgid) == real_tgid; in test_core_kernel() 80 tgid) in test_core_kernel() [all...] |
H A D | bpf_iter_task_file.c | 9 int tgid = 0; variable 26 BPF_SEQ_PRINTF(seq, " tgid gid fd file\n"); in dump_task_file() 29 if (tgid == task->tgid && task->tgid != task->pid) in dump_task_file() 32 if (last_tgid != task->tgid) { in dump_task_file() 33 last_tgid = task->tgid; in dump_task_file() 37 BPF_SEQ_PRINTF(seq, "%8d %8d %8d %lx\n", task->tgid, task->pid, fd, in dump_task_file()
|
H A D | bpf_iter_test_kern3.c | 13 int tgid; in dump_task() local 15 tgid = task->tgid; in dump_task() 16 bpf_seq_write(seq, &tgid, sizeof(tgid)); in dump_task()
|
H A D | test_core_retro.c | 8 int tgid; member 29 int tgid = BPF_CORE_READ(task, tgid); in handle_sys_enter() local 38 bpf_map_update_elem(&results, &zero, &tgid, 0); in handle_sys_enter()
|
/kernel/linux/common_modules/qos_auth/auth_ctl/ |
H A D | auth_ctrl.c | 204 unsigned int tgid = data->pid; in auth_enable() local 209 auth_to_enable = idr_find(ua_idr, tgid); in auth_enable() 248 ret = idr_alloc(ua_idr, auth_to_enable, tgid, tgid + 1, GFP_ATOMIC); in auth_enable() 263 unsigned int tgid = data->pid; in auth_delete() local 266 auth_to_delete = (struct auth_struct *)idr_remove(ua_idr, tgid); in auth_delete() 269 pr_err("[AUTH_CTRL] no auth data for this pid=%d, delete failed\n", tgid); in auth_delete() 289 unsigned int tgid = data->pid; in auth_get() local 292 auth_to_get = idr_find(ua_idr, tgid); in auth_get() 295 pr_err("[AUTH_CTRL] no auth data for this pid=%d to get\n", tgid); in auth_get() 324 unsigned int tgid = data->pid; auth_switch() local 530 unsigned int tgid = task_tgid_nr(current); check_authorized() local 585 unsigned int tgid; get_authority() local [all...] |
/kernel/linux/linux-5.10/net/bpfilter/ |
H A D | bpfilter_kern.c | 19 struct pid *tgid = info->tgid; in shutdown_umh() local 21 if (tgid) { in shutdown_umh() 22 kill_pid(tgid, SIGKILL, 1); in shutdown_umh() 23 wait_event(tgid->wait_pidfd, thread_group_exited(tgid)); in shutdown_umh() 40 if (!bpfilter_ops.info.tgid) in bpfilter_send_req() 89 pr_info("Loaded bpfilter_umh pid %d\n", pid_nr(bpfilter_ops.info.tgid)); in start_umh()
|
/kernel/linux/linux-6.6/net/bpfilter/ |
H A D | bpfilter_kern.c | 19 struct pid *tgid = info->tgid; in shutdown_umh() local 21 if (tgid) { in shutdown_umh() 22 kill_pid(tgid, SIGKILL, 1); in shutdown_umh() 23 wait_event(tgid->wait_pidfd, thread_group_exited(tgid)); in shutdown_umh() 40 if (!bpfilter_ops.info.tgid) in bpfilter_send_req() 89 pr_info("Loaded bpfilter_umh pid %d\n", pid_nr(bpfilter_ops.info.tgid)); in start_umh()
|
/kernel/linux/linux-5.10/net/ipv4/bpfilter/ |
H A D | sockopt.c | 19 put_pid(info->tgid); in bpfilter_umh_cleanup() 20 info->tgid = NULL; in bpfilter_umh_cleanup() 39 if (bpfilter_ops.info.tgid && in bpfilter_mbox_request() 40 thread_group_exited(bpfilter_ops.info.tgid)) in bpfilter_mbox_request() 43 if (!bpfilter_ops.info.tgid) { in bpfilter_mbox_request() 75 bpfilter_ops.info.tgid = NULL; in bpfilter_sockopt_init()
|
/kernel/linux/linux-5.10/drivers/staging/hungtask/ |
H A D | hungtask_base.c | 52 bool hashlist_find(struct hlist_head *head, int count, pid_t tgid) in hashlist_find() argument 58 if (hlist_empty(&head[tgid % count])) in hashlist_find() 60 hlist_for_each_entry(hnode, &head[tgid % count], list) { in hashlist_find() 61 if (hnode->pid == tgid) in hashlist_find() 84 bool hashlist_insert(struct hlist_head *head, int count, pid_t tgid) in hashlist_insert() argument 88 if (hashlist_find(head, count, tgid)) in hashlist_insert() 94 hnode->pid = tgid; in hashlist_insert() 95 hlist_add_head(&hnode->list, &head[tgid % count]); in hashlist_insert() 141 pid = t->tgid; in get_pid_by_name() 151 static unsigned int get_task_type(pid_t pid, pid_t tgid, struc argument [all...] |
/kernel/linux/linux-6.6/drivers/staging/hungtask/ |
H A D | hungtask_base.c | 52 bool hashlist_find(struct hlist_head *head, int count, pid_t tgid) in hashlist_find() argument 58 if (hlist_empty(&head[tgid % count])) in hashlist_find() 60 hlist_for_each_entry(hnode, &head[tgid % count], list) { in hashlist_find() 61 if (hnode->pid == tgid) in hashlist_find() 84 bool hashlist_insert(struct hlist_head *head, int count, pid_t tgid) in hashlist_insert() argument 88 if (hashlist_find(head, count, tgid)) in hashlist_insert() 94 hnode->pid = tgid; in hashlist_insert() 95 hlist_add_head(&hnode->list, &head[tgid % count]); in hashlist_insert() 141 pid = t->tgid; in get_pid_by_name() 151 static unsigned int get_task_type(pid_t pid, pid_t tgid, struc argument [all...] |
/kernel/linux/linux-5.10/arch/powerpc/kvm/ |
H A D | trace_hv.h | 395 __field(pid_t, tgid) 402 __entry->tgid = current->tgid; 405 TP_printk("%s runner_vcpu==%d runnable=%d tgid=%d", 407 __entry->runner_vcpu, __entry->n_runnable, __entry->tgid) 419 __field(pid_t, tgid) 426 __entry->tgid = current->tgid; 429 TP_printk("%s runner_vcpu=%d runnable=%d tgid=%d", 431 __entry->runner_vcpu, __entry->n_runnable, __entry->tgid) [all...] |
/kernel/linux/linux-6.6/arch/powerpc/kvm/ |
H A D | trace_hv.h | 415 __field(pid_t, tgid) 422 __entry->tgid = current->tgid; 425 TP_printk("%s runner_vcpu==%d runnable=%d tgid=%d", 427 __entry->runner_vcpu, __entry->n_runnable, __entry->tgid) 439 __field(pid_t, tgid) 446 __entry->tgid = current->tgid; 449 TP_printk("%s runner_vcpu=%d runnable=%d tgid=%d", 451 __entry->runner_vcpu, __entry->n_runnable, __entry->tgid) [all...] |
/kernel/linux/linux-6.6/tools/perf/util/ |
H A D | namespaces.c | 63 static int nsinfo__get_nspid(pid_t *tgid, pid_t *nstgid, bool *in_pidns, const char *path) in nsinfo__get_nspid() argument 75 /* Use tgid if CONFIG_PID_NS is not defined. */ in nsinfo__get_nspid() 77 *tgid = (pid_t)strtol(strrchr(statln, '\t'), NULL, 10); in nsinfo__get_nspid() 78 *nstgid = *tgid; in nsinfo__get_nspid() 85 * If innermost tgid is not the first, process is in a different in nsinfo__get_nspid() 129 * attempt to work out the innermost tgid for the process. in nsinfo__init() 134 rv = nsinfo__get_nspid(&RC_CHK_ACCESS(nsi)->tgid, &RC_CHK_ACCESS(nsi)->nstgid, in nsinfo__init() 166 RC_CHK_ACCESS(nsi)->tgid = pid; in nsinfo__new() 197 RC_CHK_ACCESS(nnsi)->tgid = nsinfo__tgid(nsi); in nsinfo__copy() 256 return RC_CHK_ACCESS(nsi)->tgid; in nsinfo__tgid() 371 pid_t tgid = 0, nstgid = 0; nsinfo__is_in_root_namespace() local [all...] |
/kernel/linux/linux-5.10/tools/bpf/runqslower/ |
H A D | runqslower.bpf.c | 28 static int trace_enqueue(u32 tgid, u32 pid) in trace_enqueue() argument 46 return trace_enqueue(p->tgid, p->pid); in handle__sched_wakeup() 55 return trace_enqueue(p->tgid, p->pid); in handle__sched_wakeup_new() 73 trace_enqueue(prev->tgid, prev->pid); in handle__sched_switch()
|
/kernel/linux/linux-5.10/include/dfx/ |
H A D | hungtask_base.h | 66 pid_t tgid; member 90 pid_t tgid; member 107 bool hashlist_find(struct hlist_head *head, int count, pid_t tgid); 109 bool hashlist_insert(struct hlist_head *head, int count, pid_t tgid);
|
/kernel/linux/linux-6.6/include/dfx/ |
H A D | hungtask_base.h | 66 pid_t tgid; member 90 pid_t tgid; member 107 bool hashlist_find(struct hlist_head *head, int count, pid_t tgid); 109 bool hashlist_insert(struct hlist_head *head, int count, pid_t tgid);
|
/kernel/linux/linux-6.6/net/ipv4/bpfilter/ |
H A D | sockopt.c | 30 if (bpfilter_ops.info.tgid && in bpfilter_mbox_request() 31 thread_group_exited(bpfilter_ops.info.tgid)) in bpfilter_mbox_request() 34 if (!bpfilter_ops.info.tgid) { in bpfilter_mbox_request() 66 bpfilter_ops.info.tgid = NULL; in bpfilter_sockopt_init()
|
/kernel/linux/linux-5.10/drivers/connector/ |
H A D | cn_proc.c | 87 ev->event_data.fork.parent_tgid = parent->tgid; in proc_fork_connector() 90 ev->event_data.fork.child_tgid = task->tgid; in proc_fork_connector() 114 ev->event_data.exec.process_tgid = task->tgid; in proc_exec_connector() 138 ev->event_data.id.process_tgid = task->tgid; in proc_id_connector() 176 ev->event_data.sid.process_tgid = task->tgid; in proc_sid_connector() 200 ev->event_data.ptrace.process_tgid = task->tgid; in proc_ptrace_connector() 203 ev->event_data.ptrace.tracer_tgid = current->tgid; in proc_ptrace_connector() 232 ev->event_data.comm.process_tgid = task->tgid; in proc_comm_connector() 258 ev->event_data.coredump.process_tgid = task->tgid; in proc_coredump_connector() 264 ev->event_data.coredump.parent_tgid = parent->tgid; in proc_coredump_connector() [all...] |
/kernel/linux/linux-6.6/drivers/connector/ |
H A D | cn_proc.c | 135 ev->event_data.fork.parent_tgid = parent->tgid; in proc_fork_connector() 138 ev->event_data.fork.child_tgid = task->tgid; in proc_fork_connector() 162 ev->event_data.exec.process_tgid = task->tgid; in proc_exec_connector() 186 ev->event_data.id.process_tgid = task->tgid; in proc_id_connector() 224 ev->event_data.sid.process_tgid = task->tgid; in proc_sid_connector() 248 ev->event_data.ptrace.process_tgid = task->tgid; in proc_ptrace_connector() 251 ev->event_data.ptrace.tracer_tgid = current->tgid; in proc_ptrace_connector() 280 ev->event_data.comm.process_tgid = task->tgid; in proc_comm_connector() 306 ev->event_data.coredump.process_tgid = task->tgid; in proc_coredump_connector() 312 ev->event_data.coredump.parent_tgid = parent->tgid; in proc_coredump_connector() [all...] |