1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
|
# tail /proc/kallsyms
ffffffffc02e90c8 t bpf_prog_195beb253db03fbe_k_icsk_complete_hashdance [bpf]
ffffffffc02e920c t bpf_prog_0456a7fc6de84cc2_stub_handler [bpf]
ffffffffc02e90c8 t bpf_prog_dca023555bb1a6fc_k_icsk_complete_hashdance [bpf]
ffffffffc02e9258 t bpf_prog_77b652bc40a8cde7_k_tcp_connect [bpf]
ffffffffc02e9398 t bpf_prog_0456a7fc6de84cc2_stub_handler [bpf]
ffffffffc02e9258 t bpf_prog_b1872b28057f711b_k_tcp_connect [bpf]
ffffffffc02e93c8 t bpf_prog_c293f5345a8a5f0e_freplace_handler [bpf]
ffffffffc02e9414 t bpf_prog_eef12c319a7cffba_fentry_freplace_handler [bpf]
ffffffffc02e9554 t bpf_prog_304017504bb64be8_fexit_freplace_handler [bpf]
ffffffffc05b0000 t bpf_trampoline_618475290625_1 [bpf]
# gdb -q -c /proc/kcore -ex 'x/150i 0xffffffffc02e9258' -ex 'quit'
0xffffffffc02e9258:d nopl 0x0(%rax,%rax,1)
0xffffffffc02e925d:d xchg %ax,%ax
0xffffffffc02e925f:d push %rbp
0xffffffffc02e9260:d mov %rsp,%rbp
0xffffffffc02e9263:d sub $0x28,%rsp
0xffffffffc02e926a:d push %rbx
0xffffffffc02e926b:d push %r13
0xffffffffc02e926d:d push %r14
0xffffffffc02e926f:d push %r15
0xffffffffc02e9271:d mov %rdi,%rbx
//...
0xffffffffc02e9359:d call 0xffffffff9068f450
0xffffffffc02e935e:d call 0xffffffffc02e9398 // call stub_handler()
0xffffffffc02e9363:d xor %eax,%eax
0xffffffffc02e9365:d pop %r15
0xffffffffc02e9367:d pop %r14
0xffffffffc02e9369:d pop %r13
0xffffffffc02e936b:d pop %rbx
0xffffffffc02e936c:d leave
0xffffffffc02e936d:d ret
# gdb -q -c /proc/kcore -ex 'x/150i 0xffffffffc02e9398' -ex 'quit'
0xffffffffc02e9398: jmp 0xffffffffc02e93c8 // jump to freplace_handler()
0xffffffffc02e939d: xchg %ax,%ax
0xffffffffc02e939f: push %rbp
0xffffffffc02e93a0: mov %rsp,%rbp
0xffffffffc02e93a3: movabs $0xffff9f7f17c08710,%rdi
0xffffffffc02e93ad: mov $0x18,%esi
0xffffffffc02e93b2: call 0xffffffff906917d0
0xffffffffc02e93b7: xor %eax,%eax
0xffffffffc02e93b9: leave
0xffffffffc02e93ba: ret
# gdb -q -c /proc/kcore -ex 'x/150i 0xffffffffc02e93c8' -ex 'quit'
0xffffffffc02e93c8: call 0xffffffffc05b0000 // call bpf_trampoline_618475290625_1
0xffffffffc02e93cd: xchg %ax,%ax
0xffffffffc02e93cf: push %rbp
0xffffffffc02e93d0: mov %rsp,%rbp
0xffffffffc02e93d3: movabs $0xffff9f7f173abb10,%rdi
0xffffffffc02e93dd: mov $0x1c,%esi
0xffffffffc02e93e2: call 0xffffffff906917d0
0xffffffffc02e93e7: xor %eax,%eax
0xffffffffc02e93e9: leave
0xffffffffc02e93ea: ret
# gdb -q -c /proc/kcore -ex 'x/150i 0xffffffffc05b0000' -ex 'quit'
0xffffffffc05b0000: push %rbp
0xffffffffc05b0001: mov %rsp,%rbp
0xffffffffc05b0004: sub $0x20,%rsp
0xffffffffc05b0008: push %rbx
0xffffffffc05b0009: xor %eax,%eax
0xffffffffc05b000b: mov %rax,-0x10(%rbp)
// ...
0xffffffffc05b0043: call 0xffffffffc02e9414 // call fentry_freplace_handler()
0xffffffffc05b0048: movabs $0xffffad5780126000,%rdi
// ...
0xffffffffc05b0091: call 0xffffffffc02e9554 // call fexit_freplace_handler()
0xffffffffc05b0096: movabs $0xffffad578017f000,%rdi
// ...
0xffffffffc05b00bb: mov -0x8(%rbp),%rax
0xffffffffc05b00bf: pop %rbx
0xffffffffc05b00c0: leave
0xffffffffc05b00c1: add $0x8,%rsp
0xffffffffc05b00c5: ret
|