Note: This is a beta release of Red Hat Bugzilla 5.0. The data contained within is a snapshot of the live data so any changes you make will not be reflected in the production Bugzilla. Also email is disabled so feel free to test any aspect of the site that you want. File any problems you find or give feedback here.
Bug 1690876 - %_minimize_writes strips s-bits and capabilities from files
Summary: %_minimize_writes strips s-bits and capabilities from files
Alias: None
Product: Red Hat Enterprise Linux 8
Classification: Red Hat
Component: rpm
Version: 8.0
Hardware: Unspecified
OS: Unspecified
Target Milestone: rc
: 8.0
Assignee: Panu Matilainen
QA Contact: Eva Mrakova
Depends On:
TreeView+ depends on / blocked
Reported: 2019-03-20 11:27 UTC by Panu Matilainen
Modified: 2019-04-16 07:01 UTC (History)
2 users (show)

Fixed In Version: rpm-4.14.2-15
Doc Type: If docs needed, set a value
Doc Text:
Clone Of:
Last Closed:
Type: Bug
Target Upstream Version:

Attachments (Terms of Use)

Description Panu Matilainen 2019-03-20 11:27:22 UTC
Description of problem:
%_minimize_writes feature strips capabilities and s-bits from files.

Version-Release number of selected component (if applicable):
Upstream versions rpm 4.14.0 -

How reproducible:

Steps to Reproduce (on F29 but it's the same on rhel-8):
[root@sopuli ~]# rpm -V iputils
[root@sopuli ~]# getcap /usr/bin/ping
/usr/bin/ping = cap_net_admin,cap_net_raw+p
[root@sopuli ~]# rpm --reinstall --define "%_minimize_writes 1" /tmp/iputils-20180629-2.fc29.x86_64.rpm 

Actual results:
[root@sopuli ~]# rpm -V iputils
........P    /usr/bin/ping
........P    /usr/sbin/arping
........P    /usr/sbin/clockdiff
[root@sopuli ~]# getcap /usr/bin/ping

Expected results:
[root@sopuli ~]# rpm -V iputils
[root@sopuli ~]# getcap /usr/bin/ping
/usr/bin/ping = cap_net_admin,cap_net_raw+p

Additional info:
As those s-bits and capabilities are critical to system functionality, applying real-world updates could be rather fatal. The minimize-writes feature is never on by default so this is not a critical bug but as we're probably advertising this feature to SSD users in release notes, it is of high severity anyway.

Just noticed and fixed upstream:

Comment 3 Panu Matilainen 2019-04-12 06:59:44 UTC
Fixed in rpm-4.14.2-15

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