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] [thread-next>] [day] [month] [year] [list]
Message-ID: <48441C82.1070609@hp.com>
Date:	Mon, 02 Jun 2008 12:14:58 -0400
From:	Brian Haley <brian.haley@...com>
To:	Shan Wei <shanwei@...fujitsu.com>
Cc:	YOSHIFUJI Hideaki / 吉藤英明 
	<yoshfuji@...ux-ipv6.org>, davem@...emloft.net,
	netdev@...r.kernel.org
Subject: Re: [PATCH v2] IPv6: fix bug when specifying the non-exist outgoing
 interface

Shan Wei wrote:
>   When specifying the outgoing interface with sendmsg, if the ipi6_addr is 
> the unspecified address and the ipi6_ifindex is the not-exist interface, 
> it should be fail and the errno should be set ENODEV.
>   Actually, it does well(sendmsg returns on success ), because the kernel 
> don't check the interface。

This patch changes this code path to be different than most others that 
completely ignore the device for the unspecified address - for example 
inet6_bind() and rawv6_bind().  Those paths only care about the device 
for a link-local address, so I don't think this patch is correct.

In the current git tree, this :: address is going to turn-into ::1, so 
the ifindex is irrelevant, the packet will be looped-back.  Older 
kernels could transmit the packet on the wire using the default route. 
Can you elaborate on the problem you were seeing?

I did notice a slight problem where if fl->oif is set in the caller (for 
example via SO_BINDTODEVICE), it's ignored in datagram_send_ctl() if 
src_info->ipi6_ifindex is zero, attached patch fixes that.

-Brian

Signed-off-by: Brian Haley <brian.haley@...com>
---

View attachment "datagram_send_ctl.floif.patch" of type "text/x-diff" (427 bytes)

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ