mirror of
https://github.com/varun-r-mallya/Python-BPF.git
synced 2026-12-06 09:58:34 +00:00
It generates IR, compiles, and now passes the kernel verifier, so it is no longer a failing test. It sat in failing_tests/ with no test_config.toml entry, which meant the framework already required it to pass at every level -- the directory was merely misleading. Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
20 lines
323 B
Python
20 lines
323 B
Python
from pythonbpf import compile, bpf, section, bpfglobal
|
|
from ctypes import c_void_p, c_int64
|
|
|
|
|
|
@bpf
|
|
@section("tracepoint/syscalls/sys_enter_execve")
|
|
def sometag(ctx: c_void_p) -> c_int64:
|
|
if 3 + 2 == 5:
|
|
return c_int64(5)
|
|
return c_int64(0)
|
|
|
|
|
|
@bpf
|
|
@bpfglobal
|
|
def LICENSE() -> str:
|
|
return "GPL"
|
|
|
|
|
|
compile()
|