lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-ID: <ZwKmKDUXfSdqIhM_@shredder.mtl.com>
Date: Sun, 6 Oct 2024 18:00:56 +0300
From: Ido Schimmel <idosch@...sch.org>
To: Ryan Raymond <ryanray@...ch.edu>
Cc: netdev@...r.kernel.org
Subject: Re: IP Forward src address cannot match network interface address
 Inbox

On Fri, Oct 04, 2024 at 11:57:00AM -0400, Ryan Raymond wrote:
> Hello, all
> 
> I am working on a Linux networking project. I have two interfaces:
> 
> tun0: Address 10.1.0.1
> eth0: Address 141.14.41.4
> 
> I want to write to tun0 (from userspace) so that packets are
> transmitted through my virtual network and out eth0 onto the internet.
> I can do that easily if I say that the source address is something
> random, like 1.2.3.4, but if the source address matches any interface
> (e.g. 10.1.0.1, 141.14.41.4) the packets are not transmitted.
> I think this is a routing issue with RTNETLINK, since you can also
> test this with route:
> 
> $ ip route get 1.1.1.1
> 1.1.1.1 via 141.14.41.4 dev eth0 src 141.14.41.4 uid 1000
>    cache
> $ ip route get 1.1.1.1 from 1.2.3.4 iif eth0
> 1.1.1.1 from 1.2.3.4 via 141.14.41.4 dev eth0
>    cache iif eth0
> $ ip route get 1.1.1.1 from 10.1.0.1 iif eth0
> RTNETLINK answers: Invalid argument
> $
> Does anyone know what to do about this?

Try checking accept_local and rp_filter in
Documentation/networking/ip-sysctl.rst

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ