OPNsense Forum

Archive => 20.7 Legacy Series => Topic started by: zimbawe998@mail.com on December 04, 2020, 12:47:28 pm

Title: Firewall Rule with destination Public IP Address
Post by: zimbawe998@mail.com on December 04, 2020, 12:47:28 pm
Hi all,
We are trying to play with NAT in order to achive the Firewall rule on WAN interface with Public IP Address Alias like destination.

We tryied all this 4 scenario.
This scenario it seems to be impossible to realize.
1 Forwarding rule to NONE -> Firewall rule Matched but no nat applied
2 Forwarding rule to Unassociated -> It works but with Private IP on Firewall rule table (Auto addedd)
3 Forwarding rule to associated -> It work with private IP address but not a dynamic solution: only onle rule
4 Forwarding rule to pass -> It work but without control by firewall rule

What is the best one in order to have more than one rule per destination ip and if it is possible a Pubblic IP like destination on Firewall rule?

Many Many Many thanks
Title: Re: Firewall Rule with destination Public IP Address
Post by: Fright on December 04, 2020, 04:18:12 pm
sorry. hard to understand. what exactly do you want to achieve?
Title: Re: Firewall Rule with destination Public IP Address
Post by: zimbawe998@mail.com on December 05, 2020, 09:28:22 pm
Sorry.
When i do NAT, on the Firewall rule menu i need to specify internal ip address as destination object?
is it corret or there is a way to configure a Public ip address?
Title: Re: Firewall Rule with destination Public IP Address
Post by: Fright on December 06, 2020, 07:34:26 am
sorry, still can't figure out the end goal.
outbound rules are created automatically by default.
if you create port forward rule, the destination contains the address at which the client is connect (that is, the public address). "Redirect target IP" is for intenal server address
Title: Re: Firewall Rule with destination Public IP Address
Post by: Gauss23 on December 06, 2020, 08:54:51 am
Ok, what are we talking about?
Firewall: NAT: Port Forward (destination NAT, DNAT)
or
Firewall: NAT: Outbound (source NAT, SNAT)

Please provide screenshots and mark the sections which you are having troubles with or questions for.