diff options
author | Jakub Sitnicki <[email protected]> | 2022-03-17 12:39:18 +0100 |
---|---|---|
committer | Daniel Borkmann <[email protected]> | 2022-03-18 15:46:59 +0100 |
commit | 2d2202ba858c112b03f84d546e260c61425831a1 (patch) | |
tree | 90855f72230890d68ba76e6c2f6813c19d50418c /net/lapb/lapb_subr.c | |
parent | a4c9fe0ed4a13e25e43fcd44d9f89bc19ba8fbb7 (diff) |
selftests/bpf: Check dst_port only on the client socket
cgroup_skb/egress programs which sock_fields test installs process packets
flying in both directions, from the client to the server, and in reverse
direction.
Recently added dst_port check relies on the fact that destination
port (remote peer port) of the socket which sends the packet is known ahead
of time. This holds true only for the client socket, which connects to the
known server port.
Filter out any traffic that is not egressing from the client socket in the
BPF program that tests reading the dst_port.
Fixes: 8f50f16ff39d ("selftests/bpf: Extend verifier and bpf_sock tests for dst_port loads")
Signed-off-by: Jakub Sitnicki <[email protected]>
Signed-off-by: Daniel Borkmann <[email protected]>
Acked-by: Martin KaFai Lau <[email protected]>
Link: https://lore.kernel.org/bpf/[email protected]
Diffstat (limited to 'net/lapb/lapb_subr.c')
0 files changed, 0 insertions, 0 deletions