]> git.baikalelectronics.ru Git - kernel.git/commit
Sample program using SO_COOKIE
authorChenbo Feng <fengc@google.com>
Thu, 6 Apr 2017 02:00:56 +0000 (19:00 -0700)
committerDavid S. Miller <davem@davemloft.net>
Sat, 8 Apr 2017 15:07:01 +0000 (08:07 -0700)
commit819f6ab6635f3bca408eefc13fded6aaf176829c
tree566ff6609ee3fc6ff216b9c18d3118dc50b3bf30
parent4c1bdfb8346fcbc0743c703957e634a8f3a62dd9
Sample program using SO_COOKIE

Added a per socket traffic monitoring option to illustrate the usage
of new getsockopt SO_COOKIE. The program is based on the socket traffic
monitoring program using xt_eBPF and in the new option the data entry
can be directly accessed using socket cookie. The cookie retrieved
allow us to lookup an element in the eBPF for a specific socket.

Signed-off-by: Chenbo Feng <fengc@google.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
samples/bpf/cookie_uid_helper_example.c
samples/bpf/run_cookie_uid_helper_example.sh [changed mode: 0644->0755]