This discussion has been locked.
You can no longer post new replies to this discussion. If you have a question you can start a new discussion

Secret of SNAT?

So what's the secret to get SNAT to work?  I'm trying to associate an external IP with a specific server and so far no luck.  When browsing from the source server, no matter what I do, the server is showing up on the primary WAN address (testing done via an online IP check site).

I've no issues with DNAT.  

Configuration:

Group: :: Please select ::
Position: 1  
Rule Type: SNAT (Source)


 
Matching Condition 
 

For traffic from: "Host Object"
Using service: Any
Going to: Internet IPv4



Action 
 

Change the source to: "Address defined under additional address tab""
And the service to: "Blank"



Automatic Firewall rule: Checked



Thanks in advance.

Steve


This thread was automatically locked due to age.
  • i am not quite sure about that, but i guess the masquerading rule is performed before your snat rule.
    i implemented such a configuration by adding a separate masquerade rule for that single host at the top position.

    hth, chris
  • Hi,

    Chris, in my experience, SNAT comes before MASQ.

    Steve, are you using the http proxy? Traffic passing through the proxy won't get NAT'd.

    Barry
  • Hi,

    Chris, in my experience, SNAT comes before MASQ.

    Steve, are you using the http proxy? Traffic passing through the proxy won't get NAT'd.

    Barry


    By http proxy, are you referring to webserver protection?  Is so, then no.

    Not sure why this is all so difficult.  The server in question is on a DMZ port.  I've disabled masquerading for the DMZ with no effect.  Setup a masquerade for the server with no effect.  Setup a masquerade for the DMZ with no effect.  Updated firmware and rebooted with no effect.  A Google search shows that getting SNAT to work is not an uncommon problem with Sophos UTM.  Why is this such a kludge with this product?  On the Checkpoints and Sonicwall's I've worked with in the past, doing a 1:1 NAT has never been problem.
  • Hi, 

    The HTTP Proxy is the WEB protection system, not webserver protection.

    Barry
  • Hi, 

    The HTTP Proxy is the WEB protection system, not webserver protection.

    Barry


    That was it.  Web Filtering was prempting the SNAT rules.  As soon as I turned it off the rule went into effect.  Turning filtering back on and adding the host to "Skip transparent mode source hosts/nets" under Web Filtering\Advanced works also.

    If Sophos documentation authors could add this little tidbit under the NAT section, it would be helpful for others in the future.

    Thanks for the help.
  • If Sophos documentation authors could add this little tidbit under the NAT section, it would be helpful for others in the future.


    Hi, I've now mentioned this at
    https://community.sophos.com/products/unified-threat-management/astaroorg/f/65/t/57768

    Barry
  • Hi, Steve, and welcome to the User BB!

    See #2 in https://community.sophos.com/products/unified-threat-management/astaroorg/f/51/t/22065

    Cheers - Bob

    Sorry for any short responses.  Posted from my iPhone.
  • That was it.  Web Filtering was prempting the SNAT rules.  As soon as I turned it off the rule went into effect.  Turning filtering back on and adding the host to "Skip transparent mode source hosts/nets" under Web Filtering\Advanced works also.

    If Sophos documentation authors could add this little tidbit under the NAT section, it would be helpful for others in the future.

    Thanks for the help.


    Will be added in the online docu for UTM version 9.304

    Cheers
    Max
  • That was it.  Web Filtering was prempting the SNAT rules.  As soon as I turned it off the rule went into effect.  Turning filtering back on and adding the host to "Skip transparent mode source hosts/nets" under Web Filtering\Advanced works also.


    Yes - but when you do so, you will have no Web Protection enabled (or logging (WEB) for that host...
  • The order is DNAT (incoming) - Masquerading (outgoing) - SNAT (outgoing)

    Technically you should be able to use alias IPs for your webservers outgoing, proxied or unproxied (firewall only).

    However - as far as I know there´s a bug in recent 9.2 and 9.3 Versions, where masquerading proxied services  to alias IP´s doesn´t work anymore (proxy awareness broken I guess ?) - from my knowledge this worked at least in 9.1...don´t know exactly when this got broken.