New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Add support for kprobe at custom offsets #42
Comments
mmisono
added a commit
to mmisono/bpftrace
that referenced
this issue
Jan 12, 2020
Example: `bpftrace -e 'kprobe:do_sys_open+9 { ... }'`. This is based on the support of attaching uprobe to offset (bpftrace#803). The offset is checked whether it is an instruction boundary using vmlinux (with debug symbols). The environment variable `BPFTRACE_VMLINUX` can be used to specify vmlinux file. ALLOW_UNSAFE_UPROBE option is renamed to ALLOW_UNSASFE_PROBE so that it supports both uprobe and kprobe. If bpftrace is compoiled with ALLOW_UNSASFE_PROBE option and vmlinux file is not found, and --unsafe option is given, the userspace check is skipped. Note that linux kernel checks the address alignment, but it does not check whether it is within the function. Closes bpftrace#42
mmisono
added a commit
to mmisono/bpftrace
that referenced
this issue
Jan 18, 2020
Example: `bpftrace -e 'kprobe:do_sys_open+9 { ... }'`. This is based on the support of attaching uprobe to offset (bpftrace#803). The offset is checked whether it is an instruction boundary using vmlinux (with debug symbols). The environment variable `BPFTRACE_VMLINUX` can be used to specify vmlinux file. ALLOW_UNSAFE_UPROBE option is renamed to ALLOW_UNSASFE_PROBE so that it supports both uprobe and kprobe. If bpftrace is compoiled with ALLOW_UNSASFE_PROBE option and vmlinux file is not found, and --unsafe option is given, the userspace check is skipped. Note that linux kernel checks the address alignment, but it does not check whether it is within the function. Closes bpftrace#42
danobi
pushed a commit
that referenced
this issue
Jan 22, 2020
Example: `bpftrace -e 'kprobe:do_sys_open+9 { ... }'`. This is based on the support of attaching uprobe to offset (#803). The offset is checked whether it is an instruction boundary using vmlinux (with debug symbols). The environment variable `BPFTRACE_VMLINUX` can be used to specify vmlinux file. ALLOW_UNSAFE_UPROBE option is renamed to ALLOW_UNSASFE_PROBE so that it supports both uprobe and kprobe. If bpftrace is compoiled with ALLOW_UNSASFE_PROBE option and vmlinux file is not found, and --unsafe option is given, the userspace check is skipped. Note that linux kernel checks the address alignment, but it does not check whether it is within the function. Closes #42
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
(from ajor/bpftrace#44)
New option added to libbcc
Possibly something like:
kprobe:sys_open+8 { ... }
The text was updated successfully, but these errors were encountered: