Skip to contentSkip to conversation

DNATing back to the same network

DISCUSSION Don Hughes 3 participants 3 messages Jan 13, 2005 1 message not in the archive

lore
Share & tools
lore

Don Hughes

author
#1 lore raw
In reply to a message not in the archive
Quoted 19 lines

Message: 1
Date: Thu, 13 Jan 2005 15:42:33 +0100 (CET)
From: [email protected]
Subject: DNATing back to the same network
To: [email protected]
Message-ID: <[email protected]>
Content-Type: TEXT/PLAIN; charset=US-ASCII

Hi!

I have a firewall with a number of DNAT rules for various ports/hosts. It would be good if local users could use the same DNAT's. However, as it seems this doesn't work.

My firewall has a public IP. Some ports on this IP are DNATed to different hosts on the local network. DNAT works for users that connect from the internet.

Quoted 8 lines

However, when a local users tries to connect to the public IP and DNATed port, the connection fails. Which is basically logical as the server receives a packet with the source IP of the actual user and it answeres directly to that IP.

Is it possible to change netfilter behaviour? Any other work-around for that?

I have a POSTROUTING rule for any internal traffic to SNAT it so that it returns back to the router instead of directly to the user.

Signature · 4 lines
..don

[email protected]
White Plains, NY
#2 lore raw
Quoted 3 lines · Don Hughes

I have a POSTROUTING rule for any internal traffic to SNAT it so that it returns back to the router instead of directly to the user.

That's exactly what I did a few minutes ago! :)

Are there any other implications this SNAT rule could add?

Thanks, Danilo

#3 lore raw
Quoted 9 lines · On Thu, 13 Jan 2005 [email protected] wrote:
Quoted 3 lines · Don Hughes

I have a POSTROUTING rule for any internal traffic to SNAT it so that it returns back to the router instead of directly to the user.

That's exactly what I did a few minutes ago! :)

Are there any other implications this SNAT rule could add?

Yes, your router will be blamed for any attacks on the server which originate inside the LAN. You likely won't have any logs to refute such claims.

---
Charlie