Support Forum
The Forums are a place to find answers on a range of Fortinet products from peers and product experts.
moelharrak
New Contributor

NAT same port to Different internal IP addresses

Hi,

Is it possible on Fortigate to use the same port and NAT it to two different internal Devices depend to the which source public IP is requesting the connection?

Example :

     Src-IP-1 + DST-Port-222 --> 192.168.1.100:222

     Src-IP-2 + DST-Port-222 --> 192.168.1.101:222

 

Thank you

1 REPLY 1
Toshi_Esumi
Esteemed Contributor III

Yes, there is an option in VIP config to specify traffic by source IP(s). At least my 50E took the config below although I haven't test it.

 

config firewall vip     edit "VIPtest1"         set src-filter "1.1.1.1"         set service "SMTP"         set extip x.x.x.x         set extintf "WAN_INTERFACE"         set portforward enable         set mappedip "172.16.2.200"         set mappedport 25     next     edit "VIPtest2"         set src-filter "2.2.2.2"         set service "SMTP"         set extip x.x.x.x         set extintf "WAN_INTERFACE"         set portforward enable         set mappedip "172.16.2.201"         set mappedport 25     next end

Labels
Top Kudoed Authors