All of lore.kernel.org
 help / color / mirror / Atom feed
* Local Routing without IP Aliasing
@ 2006-07-17 18:12 Jim Doble
  0 siblings, 0 replies; 3+ messages in thread
From: Jim Doble @ 2006-07-17 18:12 UTC (permalink / raw)
  To: netfilter

I am trying to configure a Linux host to treat a potentially large range 
of IP addresses as "local", without having to define these addresses as 
aliases. When packets (UDP or TCP) arrive addressed to any of these 
addresses, I need these packets to be delivered locally (that is, 
treated as if they were addressed to the IP address of my Linux host, 
even though they were not), without losing knowledge of the original 
destination address and port.  

I am defining static routes in any other hosts that need to communicate 
with these addresses, in order to ensure that packets addressed to these 
addresses will be sent to my Linux host. The problem I am having is that 
these packets are being discarded in my Linux host, unless I redirect 
them to the address associated with my Linux host, in which case the 
original destination address is lost (except in the case of TCP, where 
there is a mechanism to recover it via getsockopt).

I would prefer to find a way to do this using iptables or routing 
configuration, or via a netfilter extension, if that is possible. Any 
advice would be appreciated.

Jim Doble
Tavve Software Company




^ permalink raw reply	[flat|nested] 3+ messages in thread

* Local Routing without IP Aliasing
@ 2006-07-17 20:48 Jim Doble
  2006-07-17 23:31 ` Pascal Hambourg
  0 siblings, 1 reply; 3+ messages in thread
From: Jim Doble @ 2006-07-17 20:48 UTC (permalink / raw)
  To: netfilter

I am trying to configure a Linux host to treat a potentially large range 
of IP addresses as "local", without having to define these addresses as 
aliases. When packets (UDP or TCP) arrive addressed to any of these 
addresses, I need these packets to be delivered locally (that is, 
treated as if they were addressed to the IP address of my Linux host, 
even though they were not), without losing knowledge of the original 
destination address and port. 
I am defining static routes in any other hosts that need to communicate 
with these addresses, in order to ensure that packets addressed to these 
addresses will be sent to my Linux host. The problem I am having is that 
these packets are being discarded in my Linux host, unless I redirect 
them to the address associated with my Linux host, in which case the 
original destination address is lost (except in the case of TCP, where 
there is a mechanism to recover it via getsockopt).

I would prefer to find a way to do this using iptables or routing 
configuration, or via a netfilter extension, if that is possible. Any 
advice would be appreciated.

Jim Doble
Tavve Software Company





^ permalink raw reply	[flat|nested] 3+ messages in thread

* Re: Local Routing without IP Aliasing
  2006-07-17 20:48 Local Routing without IP Aliasing Jim Doble
@ 2006-07-17 23:31 ` Pascal Hambourg
  0 siblings, 0 replies; 3+ messages in thread
From: Pascal Hambourg @ 2006-07-17 23:31 UTC (permalink / raw)
  To: netfilter

Hello,

Jim Doble a écrit :
> I am trying to configure a Linux host to treat a potentially large range 
> of IP addresses as "local", without having to define these addresses as 
> aliases.

ip route add local <prefix>/<length> dev lo


^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2006-07-17 23:31 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2006-07-17 20:48 Local Routing without IP Aliasing Jim Doble
2006-07-17 23:31 ` Pascal Hambourg
  -- strict thread matches above, loose matches on Subject: below --
2006-07-17 18:12 Jim Doble

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.