- iptables 是基于 netfilter 实现的,是对 netfilter 暴露的 hook 的使用
- iptables 的 chain(PREROUTING/INPUT/FORWARD/OUTPUT/POSTROUTING) 对应 netfilter 的五个钩子
- iptables 的 table 对应不同的功能,比如 nat 是改写目的地/来源地,filter 是用来过滤的
- 从结构上来看 table 由 chain 组成,chain 由 rule 组成,rule 由 match 和 target 组成
Link: https://arthurchiao.art/blog/deep-dive-into-iptables-and-netfilter-arch-zh/#3-iptables-%E8%A1%A8%E5%92%8C%E9%93%BEtables-and-chains
Link:
https://github.com/j2gg0s/j2gg0s/blob/main/_posts/wips-k8s%20network%3A%20kube-proxy%20%E5%92%8C%20flannel.md#iptables-%E5%9B%9E%E9%A1%BE当然我觉得这事还是需要 google 来结果,基础好的,直接看 wiki 和 manpage ,
基础薄的看别人的 blog
LLM 大部分都是回答一些看上去对或者不对的内容。