1. Netfilter组件图
https://en.wikipedia.org/wiki/Netfilter

其中:
etables作用于数据链路层,arptables针对ARP, iptables/ip6tables针对IP层。
nftables 是新的包过滤组件. nft是相对应的新的用户态组件,用于替换etables,arptables,iptables,ip6tables.
2. Netfilter包过滤流程图

展示了链路层与网络层的包过滤点。
以常用的网络层为例:

3.对应的内核处理函数

参考:
https://en.wikipedia.org/wiki/Netfilter
https://zhuanlan.zhihu.com/p/545050331
Linux Netfilter框架实现及函数调用处理过程_netfilter使用-CSDN博客