Note: This bug is displayed in read-only format because the product is no longer active in Red Hat Bugzilla.
RHEL Engineering is moving the tracking of its product development work on RHEL 6 through RHEL 9 to Red Hat Jira (issues.redhat.com). If you're a Red Hat customer, please continue to file support cases via the Red Hat customer portal. If you're not, please head to the "RHEL project" in Red Hat Jira and file new tickets here. Individual Bugzilla bugs in the statuses "NEW", "ASSIGNED", and "POST" are being migrated throughout September 2023. Bugs of Red Hat partners with an assigned Engineering Partner Manager (EPM) are migrated in late September as per pre-agreed dates. Bugs against components "kernel", "kernel-rt", and "kpatch" are only migrated if still in "NEW" or "ASSIGNED". If you cannot log in to RH Jira, please consult article #7032570. That failing, please send an e-mail to the RH Jira admins at rh-issues@redhat.com to troubleshoot your issue as a user management inquiry. The email creates a ServiceNow ticket with Red Hat. Individual Bugzilla bugs that are migrated will be moved to status "CLOSED", resolution "MIGRATED", and set with "MigratedToJIRA" in "Keywords". The link to the successor Jira issue will be found under "Links", have a little "two-footprint" icon next to it, and direct you to the "RHEL project" in Red Hat Jira (issue links are of type "https://issues.redhat.com/browse/RHEL-XXXX", where "X" is a digit). This same link will be available in a blue banner at the top of the page informing you that that bug has been migrated.

Bug 1993242

Summary: "signature hdr data BAD" on trying to parse RPM with more than 64KB signature header
Product: Red Hat Enterprise Linux 7 Reporter: Patrick Uiterwijk <puiterwijk>
Component: rpmAssignee: Michal Domonkos <mdomonko>
Status: CLOSED ERRATA QA Contact: Jan Blazek <jblazek>
Severity: unspecified Docs Contact:
Priority: unspecified    
Version: 7.9CC: alex.iribarren, anwa, blc, chaekim, igulina, jpazdziora, jreznik, mdomonko, rmcgover, wcheang
Target Milestone: rcKeywords: Triaged, ZStream
Target Release: ---Flags: pm-rhel: mirror+
Hardware: Unspecified   
OS: Unspecified   
Whiteboard:
Fixed In Version: rpm-4.11.3-46.el7_9 Doc Type: If docs needed, set a value
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2021-10-12 15:30:57 UTC Type: Bug
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:

Description Patrick Uiterwijk 2021-08-12 15:39:45 UTC
Description of problem:
RPM on RHEL7 only accepts at most 64KB signature header size, contrary to the documented (upstream) 64MB size.

Version-Release number of selected component (if applicable):
rpm-4.11.3-45.el7.x86_64

How reproducible:
Consistent

Steps to Reproduce:
1. Get an RPM with a larger than 64KB
2. Run anything on that RPM that tries to parse it (rpm -Kv, rpm -ivh, dnf install)

Actual results:
error: python3-mechanize-0.4.5-4.fc34.noarch.rpm: signature hdr data: BAD, no. of bytes(19088) out of range


Expected results:
The RPM should get successfully processed.

Additional info:
This is fixed upstream to the documented behaviour by https://github.com/rpm-software-management/rpm/pull/1252 .
This is a RHEL7 duplicate of 1918777.

Acceptance Criteria:
RPM understands packages with a signature header exceeding 64KB.  This can be verified by IMA-signing a package with RPM version 4.16 (e.g. on a recent Fedora version) - that's because since 4.15, file signatures are stored in the signature header.  The test case from Bug 1896046 can be reused here.

Comment 12 Brian Stinson 2021-10-11 20:49:07 UTC
*** Bug 2012919 has been marked as a duplicate of this bug. ***

Comment 13 Alex Iribarren 2021-10-12 07:20:07 UTC
This still seems to fail on CentOS 8.3:

 ~ > rpm -qip http://linuxsoft.cern.ch/centos-stream/9-stream/BaseOS/aarch64/os/Packages/bash-5.1.8-2.el9.aarch64.rpm
error: /var/tmp/rpm-tmp.HGmeBg: signature hdr data: BAD, no. of bytes(31000) out of range
error: http://linuxsoft.cern.ch/centos-stream/9-stream/BaseOS/aarch64/os/Packages/bash-5.1.8-2.el9.aarch64.rpm: not an rpm package (or package manifest)
 ~ > rpm -q rpm
rpm 4.14.2-37.el8 aarch64

Comment 16 errata-xmlrpc 2021-10-12 15:30:57 UTC
Since the problem described in this bug report should be
resolved in a recent advisory, it has been closed with a
resolution of ERRATA.

For information on the advisory (rpm bug fix and enhancement update), and where to find the updated
files, follow the link below.

If the solution does not work for you, open a new bug report.

https://access.redhat.com/errata/RHBA-2021:3805