diff options
author | Jakub Sitnicki <[email protected]> | 2024-05-27 13:20:07 +0200 |
---|---|---|
committer | Daniel Borkmann <[email protected]> | 2024-05-27 19:33:40 +0200 |
commit | 98e948fb60d41447fd8d2d0c3b8637fc6b6dc26d (patch) | |
tree | a96449f76eff9a59365db5570758d363176cea30 /scripts/generate_rust_analyzer.py | |
parent | 95348e463eabc803341c67d562f9e0a5f0a48fe6 (diff) |
bpf: Allow delete from sockmap/sockhash only if update is allowed
We have seen an influx of syzkaller reports where a BPF program attached to
a tracepoint triggers a locking rule violation by performing a map_delete
on a sockmap/sockhash.
We don't intend to support this artificial use scenario. Extend the
existing verifier allowed-program-type check for updating sockmap/sockhash
to also cover deleting from a map.
From now on only BPF programs which were previously allowed to update
sockmap/sockhash can delete from these map types.
Fixes: ff9105993240 ("bpf, sockmap: Prevent lock inversion deadlock in map delete elem")
Reported-by: Tetsuo Handa <[email protected]>
Reported-by: [email protected]
Signed-off-by: Jakub Sitnicki <[email protected]>
Signed-off-by: Daniel Borkmann <[email protected]>
Tested-by: [email protected]
Acked-by: John Fastabend <[email protected]>
Closes: https://syzkaller.appspot.com/bug?extid=ec941d6e24f633a59172
Link: https://lore.kernel.org/bpf/[email protected]
Diffstat (limited to 'scripts/generate_rust_analyzer.py')
0 files changed, 0 insertions, 0 deletions