Bug 511101 - rpm --checksig is silent when being run non-rpms
Summary: rpm --checksig is silent when being run non-rpms
Keywords:
Status: CLOSED ERRATA
Alias: None
Product: Fedora
Classification: Fedora
Component: rpm
Version: 10
Hardware: All
OS: Linux
low
medium
Target Milestone: ---
Assignee: Panu Matilainen
QA Contact: Fedora Extras Quality Assurance
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2009-07-13 16:37 UTC by Ralf Corsepius
Modified: 2009-08-05 00:41 UTC (History)
3 users (show)

Fixed In Version: 4.7.1-1.fc11
Doc Type: Bug Fix
Doc Text:
Clone Of:
Environment:
Last Closed: 2009-08-05 00:41:14 UTC
Type: ---
Embargoed:


Attachments (Terms of Use)

Description Ralf Corsepius 2009-07-13 16:37:47 UTC
Description of problem:

rpm --checksig is silent when being run non rpms.

IMNSHO, this behavior is seriously defective.

Version-Release number of selected component (if applicable):
rpm-4.7.0-2.fc11.x86_64

How reproducible:
Always

Steps to Reproduce:
1.
echo "hello" > foo-1.1-1.fc11.x86_64.rpm
rpm --checksig foo-1.1-1.fc11.x86_64.rpm

2.
touch > foo-1.1-2.fc11.x86_64.rpm
rpm --checksig foo-1.1-1.fc11.x86_64.rpm foo-1.1-2.fc11.x86_64.rpm

  
Actual results:
No warning, no error, nothing.

Expected results:
rpm --checksig to raise an error message.

Comment 1 Ralf Corsepius 2009-07-13 17:04:15 UTC
Resetting version to Fedora 10, because FC10's rpm also exhibits this behavior, while rpm on FC9 doesn't.

On FC9:
# rpm --checksig foo-1.2-3.x86_64.rpm 
error: foo-1.2-3.x86_64.rpm: not an rpm package
# rpm -q rpm
rpm-4.4.2.3-3.fc9.x86_64

On FC10:
# rpm --checksig foo-1.2-3.x86_64.rpm
<nothing>
# rpm -q rpm
rpm-4.6.1-1.fc10.x86_64

=> A regression having been introduced between rpm-4.4 and rpm-4.6.

Comment 2 Panu Matilainen 2009-07-14 07:27:37 UTC
More precisely the bug is that rpm doesn't log an error on files shorter than the size of lead:
[pmatilai@localhost ~]$ echo "hellohellohellohellohellohellohellohellohellohellohellohellohellohellohellohellohellohello" > foo-1.1-1.fc11.x86_64.rpm ; rpm --checksig foo-1.1-1.fc11.x86_64.rpm; echo $?
1
[pmatilai@localhost ~]$ echo "hellohellohellohellohellohellohellohellohellohellohellohellohellohellohellohellohellohellohello" > foo-1.1-1.fc11.x86_64.rpm ; rpm --checksig foo-1.1-1.fc11.x86_64.rpm; echo $?
error: foo-1.1-1.fc11.x86_64.rpm: not an rpm package
1

Comment 3 Panu Matilainen 2009-07-14 11:27:55 UTC
Fixed upstream.

Comment 4 Fedora Update System 2009-07-24 05:17:05 UTC
rpm-4.7.1-1.fc11 has been submitted as an update for Fedora 11.
http://admin.fedoraproject.org/updates/rpm-4.7.1-1.fc11

Comment 5 Fedora Update System 2009-07-24 19:40:10 UTC
rpm-4.7.1-1.fc11 has been pushed to the Fedora 11 testing repository.  If problems still persist, please make note of it in this bug report.
 If you want to test the update, you can install it with 
 su -c 'yum --enablerepo=updates-testing update rpm'.  You can provide feedback for this update here: http://admin.fedoraproject.org/updates/F11/FEDORA-2009-7986

Comment 6 Fedora Update System 2009-08-05 00:40:47 UTC
rpm-4.7.1-1.fc11 has been pushed to the Fedora 11 stable repository.  If problems still persist, please make note of it in this bug report.


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