OPNsense Forum

English Forums => General Discussion => Topic started by: vamp on March 12, 2020, 11:32:08 AM

Title: How to forward port wan to wan?
Post by: vamp on March 12, 2020, 11:32:08 AM
Hello there,

I would like to use Wireguard on 123 UDP port (NTP, it is open lot of places where the high port is blocked) My wireguard port is a high port (55334)

I come from VyOS and on this firewall i use this rule:

set nat destination rule 12 description 'Port Forward: WireGuard to 192.168.31.1'
set nat destination rule 12 destination port '123'
set nat destination rule 12 inbound-interface 'pppoe1'
set nat destination rule 12 protocol 'udp'
set nat destination rule 12 translation address '192.168.31.1' # My firewall LAN Ip address
set nat destination rule 12 translation port '55334'


I try to make a same with Opnsense but if i set the LAN ip on " Redirect target IP" field, it not working... The only way that make it work, that i set my WAN ip address to  Redirect target IP field. My problem is that is a dinamic IP and of course it change.... try my dynamic DNS but opnsense not accept it.

My question that possible to make similar thing that i do this in VyOS?
Title: Re: How to forward port wan to wan?
Post by: vamp on March 12, 2020, 02:31:21 PM
i found the solution.

Create a alias with my DDNS address and add it to the Redirect target IP field. Now it working like a charm.
Title: Re: How to forward port wan to wan?
Post by: ligand on March 13, 2020, 09:13:16 PM
Hi!  I'm trying to do the exact same thing but on port 53.  Can you share with me your port forward configuration?