linux:iptables
差别
这里会显示出您选择的修订版和当前版本之间的差别。
两侧同时换到之前的修订记录前一修订版后一修订版 | 前一修订版 | ||
linux:iptables [2017/08/20 10:18] – memory | linux:iptables [2023/12/03 10:24] (当前版本) – 外部编辑 127.0.0.1 | ||
---|---|---|---|
行 57: | 行 57: | ||
iptables -A INPUT -j DROP | iptables -A INPUT -j DROP | ||
+ | ===== Router ===== | ||
+ | |||
+ | Redirect all dns query to specified ip: | ||
+ | |||
+ | iptables -t nat -A PREROUTING -p udp -s 192.168.1.0/ | ||
+ | |||
+ | Redirect all dns query to specified ip except some ip: | ||
+ | |||
+ | iptables -t nat -A PREROUTING -p udp -s 192.168.1.24 -j ACCEPT | ||
+ | iptables -t nat -A PREROUTING -p udp -s 192.168.1.0/ | ||
+ | |||
+ | |||
+ | ===== Reference ===== | ||
+ | |||
+ | * [[https:// |
linux/iptables.1503195488.txt.gz · 最后更改: 2023/12/03 10:24 (外部编辑)