bpf: Add more dentry kfuncs for BPF LSM programs
Get series with b4
b4 am [email protected]Versions newest first
- v1 Latest2 patches 7 repliesIn review
Patches in v1 No applies recorded yet
| # | Subject and files | Size | Replies | Applied |
|---|---|---|---|---|
| 1/2 | bpf: Add dentry kfuncs for BPF LSM programsfs/ | +104 | 7 replies | |
| 2/2 | selftests/bpf: Add tests for dentry kfuncstools/ tools/ | +99 | 0 replies |
Reviews trailers per patch
None of the 2 patches has a Reviewed-by or Acked-by.
| Patch | Al Viro |
|---|---|
| 1/2 | NAKed-by |
| 2/2 |
Trailers given in replies are filled; those carried in the patches from earlier versions are outlined with dashes.
Cover letter [PATCH bpf-next 0/2] bpf: Add more dentry kfuncs for BPF LSM programs
BPF LSM programs often need to perform path-based access control and security monitoring that requires walking filesystem structures. Currently, BPF programs can access basic file information but lack the ability to safely navigate dentry relationships or perform reference-counted operations on filesystem objects.
This series extends the existing collection of filesystem kfuncs by adding dentry-specific operations that enable BPF LSM programs to:
1. Safely acquire and release dentry references (bpf_dget/bpf_dput)
2. Navigate parent-child relationships (bpf_dget_parent)
3. Find dentry aliases for inodes (bpf_d_find_alias)
4. Access trusted dentry/vfsmount pointers from files (bpf_file_dentry/bpf_file_vfsmount)
David Windsor (2):
bpf: Add dentry kfuncs for BPF LSM programs
selftests/bpf: Add tests for dentry kfuncs
fs/bpf_fs_kfuncs.c | 104 ++++++++++++++++++ .../selftests/bpf/prog_tests/dentry_lsm.c | 48 ++++++++ .../testing/selftests/bpf/progs/dentry_lsm.c | 51 +++++++++ 3 files changed, 203 insertions(+) create mode 100644 tools/testing/selftests/bpf/prog_tests/dentry_lsm.c create mode 100644 tools/testing/selftests/bpf/progs/dentry_lsm.c
Signature · 1 line
2.43.0