Re: First stage of glibc recvmsg/sendmsg ABI revert landed in rawhide

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On 06/13/2016 03:52 PM, Daniel P. Berrange wrote:
On Mon, Jun 13, 2016 at 07:09:33AM +0200, Florian Weimer wrote:
glibc upstream, during development of the 2.24 release, introduced new
symbol versions recvmsg@GLIBC_2.24, sendmsg@GLIBC_2.24 (and
recvmmsg@GLIBC_2.24, sendmmsg@GLIBC_2.24 on 64-bit architectures), in order
to fix some minor POSIX compliance issue.  (POSIX and the Linux kernel
disagree about the width of some fields in struct msghdr.)  These changes
landed in rawhide as part of glibc-2.23.90-19.fc25.

This change caused quite a few issues (chrony stopped building, Address
Sanitizer interception of these functions was affected, probably more).
Considering that the deviation from POSIX was really minor, this was
considered a poor trade-off, and the patch and ABI change was eventually
reverted upstream.

Do you have a pointer to the glibc change, or specific details about
what exactly changed. It looks like the change broke libvirt usage
of SCM_RIGHTS, and despite fact that you're reverting it in glibc,
I'm wondering if there is non-standards compliant usage in libvirt
that we should be fixing regardless.

The upstream commit with the revert is here:


https://sourceware.org/git/?p=glibc.git;a=commit;h=78880cc185dc521855a58001a28e3059722d8e85

I assume the error comes from this code at gnulib/lib/passfd.c:

      /* fake errno: at end the file is not available */
      errno = len ? EACCES : ENOTCONN;

So the ENOTCONN isn't real.

It looks the most likely explanation is that glibc temporarily had the struct cmsghdr change in the header file, but no compensating rewriting code in the library. The padding field could be random garbage and passed to the kernel, which observes an impossible length value as a result.

Florian
--
devel mailing list
devel@xxxxxxxxxxxxxxxxxxxxxxx
https://lists.fedoraproject.org/admin/lists/devel@xxxxxxxxxxxxxxxxxxxxxxx




[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Index of Archives]     [Fedora Announce]     [Fedora Kernel]     [Fedora Testing]     [Fedora Formulas]     [Fedora PHP Devel]     [Kernel Development]     [Fedora Legacy]     [Fedora Maintainers]     [Fedora Desktop]     [PAM]     [Red Hat Development]     [Gimp]     [Yosemite News]
  Powered by Linux