Skip to content
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

pwru fails to parse helper symbols when --filter-track-bpf-helpers #462

Open
jschwinger233 opened this issue Dec 4, 2024 · 2 comments
Open
Labels
bug Something isn't working

Comments

@jschwinger233
Copy link
Member

$ s pwru --filter-mark 0x78540a00  --filter-track-bpf-helpers        'dst host 10.244.1.136 and dst port 8080 and tcp[tcpflags]=tcp-syn' 
2024/12/05 02:12:02 Attaching kprobes (via kprobe-multi)...
1641 / 1641 [-----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------] 100.00% ? p/s
2024/12/05 02:12:02 Attached (ignored 0)
2024/12/05 02:12:02 Listening for events..
SKB                CPU PROCESS          NETNS      MARK/x        IFACE       PROTO  MTU   LEN   TUPLE FUNC
0xffff9296e13e3ce8 5   ~um-envoy:491632 4026533895 78540a00        0         0x0000 1500  60    10.244.1.95:42104->10.244.1.136:8080(tcp) ip_local_out
0xffff9296e13e3ce8 5   ~um-envoy:491632 4026533895 78540a00        0         0x0000 1500  60    10.244.1.95:42104->10.244.1.136:8080(tcp) __ip_local_out
0xffff9296e13e3ce8 5   ~um-envoy:491632 4026533895 78540a00        0         0x0800 1500  60    10.244.1.95:42104->10.244.1.136:8080(tcp) nf_hook_slow
0xffff9296e13e3ce8 5   ~um-envoy:491632 4026533895 78540a00        0         0x0800 1500  60    10.244.1.95:42104->10.244.1.136:8080(tcp) ip_output
0xffff9296e13e3ce8 5   ~um-envoy:491632 4026533895 78540a00  cilium_host:3   0x0800 1500  60    10.244.1.95:42104->10.244.1.136:8080(tcp) nf_hook_slow
0xffff9296e13e3ce8 5   ~um-envoy:491632 4026533895 78540a00  cilium_host:3   0x0800 1500  60    10.244.1.95:42104->10.244.1.136:8080(tcp) apparmor_ip_postroute
0xffff9296e13e3ce8 5   ~um-envoy:491632 4026533895 78540a00  cilium_host:3   0x0800 1500  60    10.244.1.95:42104->10.244.1.136:8080(tcp) ip_finish_output
0xffff9296e13e3ce8 5   ~um-envoy:491632 4026533895 78540a00  cilium_host:3   0x0800 1500  60    10.244.1.95:42104->10.244.1.136:8080(tcp) __ip_finish_output
0xffff9296e13e3ce8 5   ~um-envoy:491632 4026533895 78540a00  cilium_host:3   0x0800 1500  60    10.244.1.95:42104->10.244.1.136:8080(tcp) ip_finish_output2
0xffff9296e13e3ce8 5   ~um-envoy:491632 4026533895 78540a00  cilium_host:3   0x0800 1500  74    10.244.1.95:42104->10.244.1.136:8080(tcp) __dev_queue_xmit
0xffff9296e13e3ce8 5   ~um-envoy:491632 4026533895 0         cilium_host:3   0x0800 1500  74    10.244.1.95:42104->10.244.1.136:8080(tcp) 0xffffffff8c504061
0xffff9296e13e3ce8 5   ~um-envoy:491632 4026533895 0         cilium_host:3   0x0800 1500  74    10.244.1.95:42104->10.244.1.136:8080(tcp) 0xffffffff8c50b871
0xffff9296e13e3ce8 5   ~um-envoy:491632 4026533895 0         cilium_host:3   0x0800 1500  74    10.244.1.95:42104->10.244.1.136:8080(tcp) skb_ensure_writable
0xffff9296e13e3ce8 5   ~um-envoy:491632 4026533895 0         cilium_host:3   0x0800 1500  74    10.244.1.95:42104->10.244.1.136:8080(tcp) 0xffffffff8c50b871
0xffff9296e13e3ce8 5   ~um-envoy:491632 4026533895 0         cilium_host:3   0x0800 1500  74    10.244.1.95:42104->10.244.1.136:8080(tcp) skb_ensure_writable
0xffff9296e13e3ce8 5   ~um-envoy:491632 4026533895 0         cilium_host:3   0x0800 1500  74    10.244.1.95:42104->10.244.1.136:8080(tcp) 0xffffffff8c50f791
0xffff9296e13e3ce8 5   ~um-envoy:491632 4026533895 0         cilium_host:3   0x0800 1500  74    10.244.1.95:42104->10.244.1.136:8080(tcp) skb_ensure_writable
0xffff9296e13e3ce8 5   ~um-envoy:491632 4026533895 0         cilium_host:3   0x0800 1500  74    10.244.1.95:42104->10.244.1.136:8080(tcp) 0xffffffff8b949921
0xffff9296e13e3ce8 5   ~um-envoy:491632 4026533895 0         cilium_host:3   0x0800 1500  74    10.244.1.95:42104->10.244.1.136:8080(tcp) 0xffffffff8c50e041
0xffff9296e13e3ce8 5   ~um-envoy:491632 4026533895 0         cilium_host:3   0x0800 1500  74    10.244.1.95:42104->10.244.1.136:8080(tcp) skb_ensure_writable
0xffff9296e13e3ce8 5   ~um-envoy:491632 4026533895 0         cilium_host:3   0x0800 1500  74    10.244.1.95:42104->10.244.1.136:8080(tcp) 0xffffffff8c50f791
0xffff9296e13e3ce8 5   ~um-envoy:491632 4026533895 0         cilium_host:3   0x0800 1500  74    10.244.1.95:42104->10.244.1.136:8080(tcp) skb_ensure_writable
0xffff9296e13e3ce8 5   ~um-envoy:491632 4026533895 0         cilium_host:3   0x0800 1500  74    10.244.1.95:42104->10.244.1.136:8080(tcp) 0xffffffff8c50f791
0xffff9296e13e3ce8 5   ~um-envoy:491632 4026533895 0         cilium_host:3   0x0800 1500  74    10.244.1.95:42104->10.244.1.136:8080(tcp) skb_ensure_writable
0xffff9296e13e3ce8 5   ~um-envoy:491632 4026533895 0         cilium_host:3   0x0800 1500  74    10.244.1.95:42104->10.244.1.136:8080(tcp) 0xffffffff8b94b981
0xffff9296e13e3ce8 5   ~um-envoy:491632 4026533895 78540a00  cilium_host:3   0x0800 1500  74    10.244.1.95:42104->10.244.1.136:8080(tcp) 0xffffffff8c502c21

The raw addresses are not expected.

git-bisect points to #455

It’s neither contributor’s nor reviewer's mistake; I’ll blame the missing CI test for not covering all scenarios.

@jschwinger233 jschwinger233 added the bug Something isn't working label Dec 4, 2024
@brb
Copy link
Member

brb commented Dec 5, 2024

missing CI test for not covering all scenarios.

Yeah, it's been in my head for quite a while 😬 Basically creating a netns, attaching some dummy BPF progs to one end, and then running pwru.

@jschwinger233
Copy link
Member Author

Or we can run a cilium 1.17 in lvh, pick several scenarios that most pwru features can be tested, such as l7-ipsec-pod-to-pod, bpf-nodeport, ...

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

2 participants