Bug 1802018 - glibc: Implement /proc-based fchmodat, lchmod emulation
Summary: glibc: Implement /proc-based fchmodat, lchmod emulation
Keywords:
Status: CLOSED CURRENTRELEASE
Alias: None
Product: Fedora
Classification: Fedora
Component: glibc
Version: 33
Hardware: Unspecified
OS: Linux
unspecified
unspecified
Target Milestone: ---
Assignee: Florian Weimer
QA Contact: Fedora Extras Quality Assurance
URL:
Whiteboard:
Depends On:
Blocks: 1810141
TreeView+ depends on / blocked
 
Reported: 2020-02-12 07:50 UTC by Florian Weimer
Modified: 2021-05-18 13:16 UTC (History)
11 users (show)

Fixed In Version: glibc-2.31.9000-1.fc33
Clone Of:
: 1810141 (view as bug list)
Environment:
Last Closed: 2021-05-18 13:16:26 UTC
Type: Bug
Embargoed:


Attachments (Terms of Use)


Links
System ID Private Priority Status Summary Last Updated
Sourceware 14578 0 P2 RESOLVED /proc-based emulation for lchmod, fchmodat 2021-01-05 14:51:36 UTC

Description Florian Weimer 2020-02-12 07:50:15 UTC
gnulib has added emulation of lchmod, fchmodat based on /proc, and glibc upstream will do so as well. We need to integrate the glibc changes into Fedora so that GNU applications can be built properly.

Comment 1 Florian Weimer 2020-02-12 11:53:04 UTC
We're hitting an XFS bug in this area: https://www.sourceware.org/ml/libc-alpha/2020-02/msg00467.html

Comment 3 Florian Weimer 2020-03-04 15:30:40 UTC
The kernel bug is worked around with this glibc commit:

commit a492b1e5ef7ab50c6fdd4e4e9879ea5569ab0a6c
Author: Florian Weimer <fweimer>
Date:   Tue Feb 18 17:52:27 2020 +0100

    Linux: Work around kernel bugs in chmod on /proc/self/fd paths [BZ #14578]
    
    It appears that the ability to change symbolic link modes through such
    paths is unintended.  On several file systems, the operation fails with
    EOPNOTSUPP, even though the symbolic link permissions are updated.
    The expected behavior is a failure to update the permissions, without
    file system changes.
    
    Reviewed-by: Matheus Castanho <msc.com>

Comment 4 Florian Weimer 2020-06-09 13:55:58 UTC
I'd really like to wait with the backports until the kernel system call has landed. I've pinged the most recent submission.

Comment 5 Ben Cotton 2020-08-11 13:07:57 UTC
This bug appears to have been reported against 'rawhide' during the Fedora 33 development cycle.
Changing version to 33.

Comment 6 Florian Weimer 2020-09-15 13:45:22 UTC
Rick Felker posted an implementation of the required system call: https://lore.kernel.org/linux-api/20200910142335.GG3265@brightrain.aerifal.cx/

Comment 7 Florian Weimer 2020-10-13 13:40:03 UTC
Rich Felker's patch was rejected because it did not come with a test case.

We probably need to contribute that test case so that the kernel change can move forward.

Comment 8 Florian Weimer 2021-05-18 13:16:26 UTC
Fixed by:

* Wed Feb 26 2020 Patsy Franklin <patsy> - 2.31.9000-1
- Auto-sync with upstream branch master,
  commit 758599bc9dcc5764e862bd9e1613c5d1e6efc5d3.


Note You need to log in before you can comment on or make changes to this bug.