Red Hat Bugzilla – Bug 159405
rpm --verify reports spurious md5 errors for empty files
Last modified: 2007-11-30 17:11:07 EST
If you use "rpm --verify" on a package with empty files, rpm will report "?"
in the MD5 column for the empty files. This is because mmap files when you
try to map a file of length zero. Whether that failure is correct is, I
suppose, a matter of some debate; the man page doesn't make it clear, although
the specs may be clearer. In any case, the attached patch eliminates the
Created attachment 115085 [details]
patch not to try to mmap empty files
This started happening when I upgraded my custom kernel from 2.6.11 to 2.6.12.
It's also reproducable with kernel-2.6.11-1.1369_FC4.
It appears that this 'breakage' was deliberate, according to the ChangeLog for
Author: Zhang Yanmin <firstname.lastname@example.org>
Date: Sun May 22 17:47:00 2005 -0700
[IA64] sys_mmap doesn't follow posix.1 when parameter len=0
In IA64 kernel, sys_mmap calls do_mmap2 and do_mmap2 returns addr if
len=0, which means the mmap sys call succeeds.
The mmap() function shall fail if:
[EINVAL] The value of len is zero.
Here is a patch to fix it.
Signed-off-by: Zhang Yanmin <email@example.com>
Acked-by: David Mosberger <firstname.lastname@example.org>
Signed-off-by: Tony Luck <email@example.com>
Real bug. Affects security (since some people use rpm --verity regularly to
audit their systems, and this bug causes spurious output from rpm --verity).
Reported over a month ago. Fix included in bug report. Can we please move this
Fixed in rpm-4.4.2-1.
Shouldn't this be backported to RHEL 4 (RPM version 4.3.3) as well?
For consideration for RHEL please file an issue with support.
as described at https://bugzilla.redhat.com/
Well, there you have your answer!
Service request #766776 has been filed to request backporting this patch to RHEL 4.