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-next>] [day] [month] [year] [list]
Message-ID: <538CE2CA.9060806@us.thalesgroup.com>
Date:	Mon, 2 Jun 2014 13:47:06 -0700
From:	CLOSE Dave <Dave.Close@...thalesgroup.com>
To:	"netdev@...r.kernel.org" <netdev@...r.kernel.org>
Subject: Trying to ping from a subinterface.

On Fedora 20 x86_64.

According to "man ping", ping should work from a subinterface specifying
either the interface name or its address:

> -I interface
>    interface is either an address, or an interface name.  If inter‐
>    face is an address, it sets source address to  specified  inter‐
>    face address.  If interface in an interface name, it sets source
>    interface to specified interface.

I've got a subinterface and I'm trying to ping from it.

> # ifconfig eth3:sub1
> eth3:sub1: flags=4163<UP,BROADCAST,RUNNING,MULTICAST>  mtu 1500
>        inet 172.17.30.143  netmask 255.255.254.0  broadcast 172.17.31.255
>        ether 90:e2:ba:34:46:41  txqueuelen 1000  (Ethernet)
>        device memory 0xdc7e0000-dc800000

If I ping from the address, it works as specified. If I specify the
interface name instead, I see:

> # ping -I eth3:sub1 172.17.30.1
> ping: SO_BINDTODEVICE: Invalid argument

Investigating a little deeper:

> # strace ping -I eth3:sub1 172.17.30.1
> execve("/usr/bin/ping", ["ping", "-I", "eth3:sub1", "172.17.30.1"], [/* 38 vars */]) = 0
> ...
> setsockopt(4, SOL_SOCKET, SO_BINDTODEVICE, "eth3:sub1\0", 13) = -1 ENODEV (No such device)
> ...
> +++ exited with 2 +++

Any thoughts?
-- 
Dave Close

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ