Home
Sign Up
Sign In
V2EX
›
问与答
iptables 源端口和目的端口怎么放到同一规则上?
JohnLou
·
Dec 8, 2017
· 2282 views
This topic created in 3252 days ago, the information mentioned may be changed or developed.
rt
iptables -A FORWARD --sport 443 --dport 443 -j ACCEPT
该怎么写。
iptables
端口
dport
Accept
3 replies
•
2017-12-08 15:06:26 +08:00
shiji
Dec 8, 2017 via Android
1
你好像缺了 -m tcp 这个了。 否则不是所有数据包都有端口。。 你这个配置会报错的
JohnLou
OP
Dec 8, 2017
2
@
shiji
我只是假如,实际想请问大家。
shiji
Dec 8, 2017
3
iptables -A FORWARD -p tcp -m tcp --sport 443 --dport 443 -j ACCEPT
补上不就好了吗?别的也没什么问题啊。需要 udp 就再增加一行
About
·
Help
·
Advertise
·
Blog
·
API
·
FAQ
·
Privacy
·
Solana
·
1904 Online
Highest 6679
·
Select Language
创意工作者们的社区
World is powered by solitude
VERSION: 3.9.8.5 · 22ms ·
UTC 16:36
·
PVG 00:36
·
LAX 08:36
·
JFK 11:36
♥ Do have faith in what you're doing.
❯