eBPF-based security platform
upatch: report the runs the kernel skipped of fentry and fexit links
Jiri Olsa334471cdcd6f
diff --git a/util/upatch_resolve.c b/util/upatch_resolve.cindex fbbf6180..fe29dd30 100644--- a/util/upatch_resolve.c+++ b/util/upatch_resolve.c@@ -359,6 +359,11 @@ bool upatch_link_counts_misses(const struct bpf_link_info *info)return true;case BPF_LINK_TYPE_PERF_EVENT:return link_is_kprobe(info);+ case BPF_LINK_TYPE_TRACING:+ /* The kernel runs an lsm program without its recursion check. */+ return info->tracing.attach_type == BPF_TRACE_FENTRY ||+ info->tracing.attach_type == BPF_TRACE_FEXIT ||+ info->tracing.attach_type == BPF_MODIFY_RETURN;default:return false;}diff --git a/util/upatch_resolve.h b/util/upatch_resolve.hindex 93ad211a..004b06b7 100644--- a/util/upatch_resolve.h+++ b/util/upatch_resolve.h@@ -52,9 +52,9 @@ struct upatch_link_misses {/** Whether the runs the kernel skips of the program behind this link are- * reported: kprobe, kretprobe and their multi forms. The kernel skips no- * lsm, xdp, cgroup_skb or netfilter run, and counts none it skips of the- * uprobe kinds.+ * reported: kprobe, kretprobe, their multi forms, fentry, fexit and+ * fmod_ret. The kernel skips no lsm, xdp, cgroup_skb or netfilter run,+ * and counts none it skips of the uprobe kinds.*/bool upatch_link_counts_misses(const struct bpf_link_info *info);