port forwarding in windows

前端 未结 3 718
太阳男子
太阳男子 2020-11-28 16:52

I have two network board in my pc:

The main one has the local ip -> 192.168.1.111 The secondary ones has the local ip -> 192.168.0.200

The main one has inter

相关标签:
3条回答
  • 2020-11-28 17:28

    nginx is useful for forwarding HTTP on many platforms including Windows. It's easy to setup and extend with more advanced configuration. A basic configuration could look something like this:

    events {}
    
    http {
         server {
    
            listen 192.168.1.111:4422;
    
            location / {
                proxy_pass http://192.168.2.33:80/;
            }
         }
    }
    
    0 讨论(0)
  • 2020-11-28 17:30

    I've used this little utility whenever the need arises: http://www.analogx.com/contents/download/network/pmapper/freeware.htm

    The last time this utility was updated was in 2009. I noticed on my Win10 machine, it hangs for a few seconds when opening new windows sometimes. Other then that UI glitch, it still does its job fine.

    0 讨论(0)
  • 2020-11-28 17:46

    I've solved it, it can be done executing:

    netsh interface portproxy add v4tov4 listenport=4422 listenaddress=192.168.1.111 connectport=80 connectaddress=192.168.0.33
    

    To remove forwarding:

    netsh interface portproxy delete v4tov4 listenport=4422 listenaddress=192.168.1.111
    

    Official docs

    0 讨论(0)
提交回复
热议问题