Help with firewall rule for DDNS on Synology nas

Started by virtualdimension, January 10, 2025, 02:18:06 AM

Previous topic - Next topic
Hi all.
I have an OPNsense DEC850 configured like this:

- On port 1 (WAN1), TIM Business modem (192.168.9.1)
- On port 2 (WAN2), Vodafone Business modem (192.168.10.1)
- On port x0 (LAN), connect an Ubiquiti UDM-PRO
The Ubiquiti UDM-PRO have 192.168.1.1 ip.
The DEC850 have the 192.168.3.1 ip.

The DEC850 is configured to handle the two wan connections in load balancing.
In both modems I created a DMZ for the IP address that is assigned to the DEC850. The modems are only used to provide the internet connection to the firewall.
Then, through the x0 port of the firewall, I connected it to the WAN port of the Ubiquiti UDM-PRO (with static IP).
All the various network devices (access points, computers, NAS, smartphones, printers, etc. etc.) are connected to the UDM-PRO.

I need your help to configure rules to access a Synology NAS through DDNS for mobile app's (Synology Drive, Synology Photos, Synology Note, etc etc).

On the Synology NAS everything is already configured with its own DDNS service "myname.synology.me" with the relative Let's Encrypt certificate.
On the UDM-PRO to which the NAS is connected, I created a port-forwarding:
Source: Any - Protocol: TCP - Forwarded IP: 192.168.1.49 (nas IP) - Port: 5001 (the port for Synology Drive)

At this point my problem is to create the necessary rules on the DEC850 firewall so that when I have to access remotely through the link myname.synology.me, this points towards the NAS and allows me to connect to the various services.

Thanks in advance for your help