Author Topic: Auto Port Forwarding: Part Deux  (Read 191 times)

0 Members and 1 Guest are viewing this topic.

Offline taylor

  • Super SCP/Linux Guru
  • Moderator
  • 212
Auto Port Forwarding: Part Deux
(Updated 11/30: All new rewritten code using a different library!)

This is a test build of the new automatic port forwarding feature. This is really just to test out router compatibility and how easy or difficult it is for all of you to enable support.

Win64 only, since it's hopefully a quick test. Linux binaries will be provided if needed, or you can build from source yourself.

Windows 64-bit (updated 11/29)
Github pull request

This uses PCP/NAT-PMP to automatically manage port forwarding. As such, PCP/NAT-PMP must be enabled on your router. If you don't see an option for PCP/NAT-PMP you may have to enable UPnP first. Depending on your internet provider it's possible that this will also get through carrier-grade NAT.  The auto port forwarding feature is enabled only as needed: when you create/host a game, or run a standalone server. And it's disabled as soon as it's no longer required.

A new command line option has been added for support purposes: -gateway_ip <ip_address>. Your router/gateway should be detected automatically but if not then you can specify the IP address to use (e.g., -gateway_ip If everything works well your multi.log file will contain your public facing IP address as well as the port mapping that was enabled. All messages, including errors, will be prefixed with "Port forward =>". Debug builds will also send more diagnostic data to multi.log, so if you have problems please give that a try and send the multi.log to me.
« Last Edit: November 29, 2019, 11:34:03 pm by taylor »