sk_filter — run a packet through a socket filter
int sk_filter ( | struct sock * sk, |
struct sk_buff * skb) ; |
Run the filter code and then cut skb->data to correct size returned by SK_RUN_FILTER. If pkt_len is 0 we toss packet. If skb->len is smaller than pkt_len we keep whole skb->data. This is the socket level wrapper to SK_RUN_FILTER. It returns 0 if the packet should be accepted or -EPERM if the packet should be tossed.