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: <CAFsF8vL4CGFzWMb38_XviiEgxoKX0GYup=JiUFXUOmagdk9CRg@mail.gmail.com>
Date:   Wed, 11 Jan 2023 16:52:21 +0100
From:   Paul Holzinger <pholzing@...hat.com>
To:     stable@...r.kernel.org
Cc:     regressions@...ts.linux.dev, netdev@...r.kernel.org
Subject: [Regression] 6.0.16-6.0.18 kernel no longer return EADDRINUSE from bind

Hi all,

Since updating to 6.0.16 the bind() system call no longer fails with
EADDRINUSE when the address is already in use.
Instead bind() returns 1 in such a case, which is not a valid return
value for this system call.

It works with the 6.0.15 kernel and earlier, 6.1.4 and 6.2-rc3 also
seem to work.

Fedora bugzilla: https://bugzilla.redhat.com/show_bug.cgi?id=2159066

To reproduce you can just run `ncat -l 5000` two times, the second one
should fail. However it just uses a random port instead.

As far as I can tell this problem is caused by
https://lore.kernel.org/stable/20221228144337.512799851@linuxfoundation.org/
which did not backport commit 7a7160edf1bf properly.
The line `int ret = -EADDRINUSE, port = snum, l3mdev;` is missing in
net/ipv4/inet_connection_sock.c.
This is the working 6.1 patch:
https://lore.kernel.org/all/20221228144339.969733443@linuxfoundation.org/

Best regards,
Paul

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ