Date: Sun, 24 Jul 2022 22:12:12 +0000 From: bugzilla-noreply@freebsd.org To: net@FreeBSD.org Subject: [Bug 265064] connect(2): unexpected EADDRINUSE when connecting from IPv6 wildcard to IPv4 address Message-ID: <bug-265064-7501-EA64JgQF2a@https.bugs.freebsd.org/bugzilla/> In-Reply-To: <bug-265064-7501@https.bugs.freebsd.org/bugzilla/> References: <bug-265064-7501@https.bugs.freebsd.org/bugzilla/>
next in thread | previous in thread | raw e-mail | index | archive | help
https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=3D265064 Mike Karels <karels@freebsd.org> changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |karels@freebsd.org --- Comment #2 from Mike Karels <karels@freebsd.org> --- The problem is that the bind() for the failing socket should not have succeeded, and the problem isn't discovered until the connect(). The root problem is that bind on an IPv6 socket is allowed to choose a port that is already bound by a previous socket, but which has been connected and hence turned into an IPv4 socket. The connect cannot succeed then, because it wo= uld create a fully duplicate session (4-tuple). I am looking at a fix for the bind, but it is somewhat messy. --=20 You are receiving this mail because: You are the assignee for the bug.=
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?bug-265064-7501-EA64JgQF2a>