These instructions teach you how to open ports on a Ubiquiti UniFi® Security Gateway (USG)
Prerequisites are that you have the following equipment set up:
- USG
- Cloudkey
- Network Access to the devices
Here’s some Amazon affiliate links to the devices if you need them
- Unifi Security Gateway (USG) or the beefier UniFi Security Gateway Pro 4 USG-PRO-4 Enterprise Router
- UniFi Cloud Key Gen2 or UniFi Cloud Key Gen2 Plus (this gives you GUI access)
Steps:
- Log into your Cloud Key
- On the left side, hit the Settings icon
- In the search box, simply type “port forward” and select the first result which says “Add New Port Forwarding”
- Fill in the following fields:
- Name is something descriptive for your port forward
- Enable Forward Rule should be set to True if you want to activate it upon Applying Changes
- Interface is likely your WAN. If you want WAN2 you’ll need to do some manual configurations with a full tutorial available from the Ubiquiti website
- From is simply Any (if you put Limited you can set an IP that will be the only IP that can hit this port. You can do a simple IP or an an entire octet like x.x.x.0/24)
- Forward IP is the IP of the computer you’re wanting access to
- Forward Port is the Port of the computer you’re wanting access to (e.g. 22 for SSH)
- Protocol is the protocol type you want going through
- Logging is optional but you can log traffic to this port which the USG does by forwarding it to the syslog
- Click Apply Changes when complete
- It may take a couple minutes to be available
A more comprehensive guide is available here: https://help.ui.com/hc/en-us/articles/235723207-UniFi-USG-UDM-Port-Forwarding-Configuration-and-Troubleshooting