bpf: Introduce union trusted
Get series with b4
b4 am [email protected]Versions newest first
- v1 Latest3 patches 6 repliesIn review
Changes from the cover letter
- bpf: Fix errors in verifying a union
https://lore.kernel.org/bpf/[email protected]/
Patches in v1 No applies recorded yet
| # | Subject and files | Size | Replies | Applied |
|---|---|---|---|---|
| 1/3 | bpf: Introduce BTF_TYPE_SAFE_TRUSTED_UNIONkernel/ kernel/ | +30 | 4 replies | |
| 2/3 | selftests/bpf: Add selftests for BTF_TYPE_SAFE_TRUSTED_UNIONtools/ tools/ | +31 | 0 replies | |
| 3/3 | bpf: Fix an error in verifying a field in a unionkernel/ | +1 | 2 replies |
Reviews trailers per patch
No Reviewed-by, Acked-by or Tested-by trailers for v1 yet.
Cover letter [PATCH bpf-next 0/3] bpf: Introduce union trusted
When we are verifying a field in a union, we may verify another field which has the same offset. So we should annotate that field as untrusted. In some cases we have already known that some fields are safe and then we can add them into the union trusted allow list.
Patch #3 fixes an issue found in our dev server.
Changes:
- bpf: Fix errors in verifying a union
https://lore.kernel.org/bpf/[email protected]/
Yafang Shao (3):
bpf: Introduce BTF_TYPE_SAFE_TRUSTED_UNION selftests/bpf: Add selftests for BTF_TYPE_SAFE_TRUSTED_UNION
bpf: Fix an error in verifying a field in a union
kernel/bpf/btf.c | 22 +++++++++---------- kernel/bpf/verifier.c | 21 ++++++++++++++++++ .../bpf/progs/nested_trust_failure.c | 16 ++++++++++++++ .../bpf/progs/nested_trust_success.c | 15 +++++++++++++ 4 files changed, 62 insertions(+), 12 deletions(-)
Signature · 1 line
2.30.1 (Apple Git-130)