1SK_ATTACH_FILTER(9) Linux Networking SK_ATTACH_FILTER(9)
2
3
4
6 sk_attach_filter - attach a socket filter
7
9 int sk_attach_filter(struct sock_fprog * fprog, struct sock * sk);
10
12 fprog
13 the filter program
14
15 sk
16 the socket to use
17
19 Attach the user's filter code. We first run some sanity checks on it to
20 make sure it does not explode on us later. If an error occurs or there
21 is insufficient memory for the filter a negative errno code is
22 returned. On success the return is zero.
23
25Kernel Hackers Manual 3.10 June 2019 SK_ATTACH_FILTER(9)