Home
Sign Up
Sign In
• 请不要在回答技术问题时复制粘贴 AI 生成的内容
V2EX
›
程序员
端口转发
259145
·
Dec 7, 2017
· 2392 views
This topic created in 3099 days ago, the information mentioned may be changed or developed.
如何将服务器不使用的端口全部转发到 80 端口,外网 IP+任意端口就可以访问网站
端口
外网
服务器
任意
2 replies
1
shiji
Dec 8, 2017
x
2
shiji
Dec 8, 2017
(刚刚输入法犯病了)
大概是这个样子(没试过,不负责):
sudo iptables -t nat -A INPUT -i [interface 名,eth0 eth1 之类的] -p tcp -j REDIRECT --to-port 80
如果你需要远程连 SSH FTP 什么的,就要注意了,肯定会导致那些连不上。
About
·
Help
·
Advertise
·
Blog
·
API
·
FAQ
·
Solana
·
5565 Online
Highest 6679
·
Select Language
创意工作者们的社区
World is powered by solitude
VERSION: 93c8b4a0 · 39ms ·
UTC 08:32
·
PVG 16:32
·
LAX 01:32
·
JFK 04:32
♥ Do have faith in what you're doing.
❯