Home
Sign Up
Sign In
• 请不要在回答技术问题时复制粘贴 AI 生成的内容
V2EX
›
程序员
端口转发
259145
·
Dec 7, 2017
· 2649 views
This topic created in 3254 days ago, the information mentioned may be changed or developed.
如何将服务器不使用的端口全部转发到 80 端口,外网 IP+任意端口就可以访问网站
端口
外网
服务器
任意
2 replies
shiji
Dec 8, 2017
1
x
shiji
Dec 8, 2017
2
(刚刚输入法犯病了)
大概是这个样子(没试过,不负责):
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
·
Privacy
·
Solana
·
5052 Online
Highest 6679
·
Select Language
创意工作者们的社区
World is powered by solitude
VERSION: 3.9.8.5 · 31ms ·
UTC 06:04
·
PVG 14:04
·
LAX 22:04
·
JFK 01:04
♥ Do have faith in what you're doing.
❯