Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 759550 - sys-libs/libcap-ng-0.8.2: caused errors in gnome-base/gnome-keyring's gnome-keyring-daemon: error dropping process capabilities, aborting
Summary: sys-libs/libcap-ng-0.8.2: caused errors in gnome-base/gnome-keyring's gnome-k...
Status: RESOLVED FIXED
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: Current packages (show other bugs)
Hardware: All Linux
: Normal normal (vote)
Assignee: Gentoo's Team for Core System packages
URL:
Whiteboard:
Keywords:
Depends on:
Blocks: 759565
  Show dependency tree
 
Reported: 2020-12-12 04:08 UTC by vowstar
Modified: 2023-12-24 02:02 UTC (History)
4 users (show)

See Also:
Package list:
Runtime testing required: ---


Attachments
Patch to fix this issue (0002_fix_apply_disable.patch,785 bytes, patch)
2020-12-12 04:08 UTC, vowstar
Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description vowstar 2020-12-12 04:08:13 UTC
Created attachment 678052 [details, diff]
Patch to fix this issue

When updated to sys-libs/libcap-ng-0.8.2, it caused gnome-keyring-daemon: error dropping process capabilities, aborting when starting gnome-keyring.

In libcap-ng-0.8.2/src/cap-ng.c, it have error codes that nobody handles and crashes everything that should be removed.


Put attachment 0002 [details]_fix_apply_disable.patch into /etc/portage/patches/sys-libs/libcap-ng-0.8.2 fixed this issue.

This patch will remove error codes that nobody handles and crashes everything.
Comment 1 vowstar 2020-12-12 04:11:28 UTC
Fix: Put attachment attachment 678052 [details, diff] 0002_fix_apply_disable.patch into /etc/portage/patches/sys-libs/libcap-ng-0.8.2 fixed this issue.
Comment 2 Robin Johnson archtester Gentoo Infrastructure gentoo-dev Security 2020-12-12 21:33:10 UTC
vowstar: the comment you have in the patch is "Upstream: Fedora patch".

Can you please link it directly?
Comment 3 Sam James archtester Gentoo Infrastructure gentoo-dev Security 2020-12-12 21:51:09 UTC
I should have made this clear last night before adding the PATCH tag: the patch is not an obvious solution and may not be safe. Needs more research.
Comment 4 vowstar 2020-12-12 23:13:36 UTC
(In reply to Robin Johnson from comment #2)
> vowstar: the comment you have in the patch is "Upstream: Fedora patch".
> 
> Can you please link it directly?

This patch originally from alpine linux

Issue: https://github.com/stevegrubb/libcap-ng/issues/21
Patch: https://github.com/alpinelinux/aports/blob/fd99f143e50e6412f8bdd889c89813f12f0f0ec5/main/libcap-ng/apply-disable.patch
Comment 5 Larry the Git Cow gentoo-dev 2020-12-13 01:12:59 UTC
The bug has been referenced in the following commit(s):

https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=4ca4382ca9ff930c32be7bad930eb0c415bae4d2

commit 4ca4382ca9ff930c32be7bad930eb0c415bae4d2
Author:     Sam James <sam@gentoo.org>
AuthorDate: 2020-12-13 01:11:45 +0000
Commit:     Sam James <sam@gentoo.org>
CommitDate: 2020-12-13 01:11:45 +0000

    profiles/package.mask: mask =sys-libs/libcap-ng-0.8.2
    
    Seems to still break consumers. Unsure about applying
    the patch used in Fedora given that upstream have
    cut a new release since and not included both
    of the fixes previously being applied there.
    
    Masking for now while we decide on a way forward.
    
    Bug: https://bugs.gentoo.org/759565
    Bug: https://bugs.gentoo.org/759550
    Bug: https://bugs.gentoo.org/759688
    Signed-off-by: Sam James <sam@gentoo.org>

 profiles/package.mask | 6 ++++++
 1 file changed, 6 insertions(+)
Comment 6 Larry the Git Cow gentoo-dev 2020-12-14 23:21:11 UTC
The bug has been closed via the following commit(s):

https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=87a9246ba1a1091db7dc7f677f20916546afe408

commit 87a9246ba1a1091db7dc7f677f20916546afe408
Author:     Robin H. Johnson <robbat2@gentoo.org>
AuthorDate: 2020-12-14 22:54:40 +0000
Commit:     Robin H. Johnson <robbat2@gentoo.org>
CommitDate: 2020-12-14 23:21:07 +0000

    sys-libs/libcap-ng: add patches for gnome-keyring-daemon breakage
    
    The upstream author of libcap-ng is ALSO the Fedora packager, and ships
    a critical behavior fix regarding new error codes for the recent
    versions, both of which are available in different Fedora releases.
    After careful review, include BOTH of those releases in our tree, to
    allow testing for regressions.
    
    Closes: https://bugs.gentoo.org/759550
    Signed-off-by: Robin H. Johnson <robbat2@gentoo.org>

 sys-libs/libcap-ng/Manifest                  |  3 +
 sys-libs/libcap-ng/libcap-ng-0.8.1-r1.ebuild | 98 ++++++++++++++++++++++++++++
 sys-libs/libcap-ng/libcap-ng-0.8.2-r1.ebuild | 95 +++++++++++++++++++++++++++
 3 files changed, 196 insertions(+)
Comment 8 Sam James archtester Gentoo Infrastructure gentoo-dev Security 2022-04-07 02:42:44 UTC
gnome-base/gnome-keyring has since been fixed (>= 40): https://gitlab.gnome.org/GNOME/gnome-keyring/-/merge_requests/34
Comment 9 Larry the Git Cow gentoo-dev 2022-04-07 03:37:58 UTC
The bug has been referenced in the following commit(s):

https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=9d1c977852df6f69ece2d34b831c7869d120ea47

commit 9d1c977852df6f69ece2d34b831c7869d120ea47
Author:     Sam James <sam@gentoo.org>
AuthorDate: 2022-04-07 02:44:49 +0000
Commit:     Sam James <sam@gentoo.org>
CommitDate: 2022-04-07 03:37:41 +0000

    sys-libs/libcap-ng: add 0.8.3
    
    Keep the Fedora patch for now (one last time?) which reverts a behaviour
    change until we're a bit more certain consumers are fixed. Given Fedora
    is still shipping it (and the upstream maintainer == Fedora maintainer),
    I'd rather wait a bit longer before dropping.
    
    That said, gnome-keyring is fixed since 40, and it was the only
    known breakage AFAIK.
    
    Bug: https://bugs.gentoo.org/759550
    Signed-off-by: Sam James <sam@gentoo.org>

 sys-libs/libcap-ng/Manifest               |   1 +
 sys-libs/libcap-ng/libcap-ng-0.8.3.ebuild | 109 ++++++++++++++++++++++++++++++
 2 files changed, 110 insertions(+)
Comment 10 Larry the Git Cow gentoo-dev 2023-12-24 01:45:24 UTC
The bug has been referenced in the following commit(s):

https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=3f94f64e9243db42bda7a418edb8008b6acb4fc5

commit 3f94f64e9243db42bda7a418edb8008b6acb4fc5
Author:     Sam James <sam@gentoo.org>
AuthorDate: 2023-12-24 01:41:08 +0000
Commit:     Sam James <sam@gentoo.org>
CommitDate: 2023-12-24 01:45:07 +0000

    sys-libs/libcap-ng: add 0.8.4
    
    Note that this drops the workaround for bug #759550 - as the upstream maintainer
    has done in Fedora too [0]
    
    [0] https://lists.fedoraproject.org/archives/list/devel@lists.fedoraproject.org/thread/A4NEVRDJLLLOK5LLLTQC7Y2HS3MVAWQM/
    
    Bug: https://bugs.gentoo.org/759550
    Signed-off-by: Sam James <sam@gentoo.org>

 sys-libs/libcap-ng/Manifest               |   1 +
 sys-libs/libcap-ng/libcap-ng-0.8.4.ebuild | 100 ++++++++++++++++++++++++++++++
 2 files changed, 101 insertions(+)