Bug 9029 - LILO does not fully initialize map file
Summary: LILO does not fully initialize map file
Alias: None
Product: Red Hat Linux
Classification: Retired
Component: lilo   
(Show other bugs)
Version: 6.1
Hardware: All
OS: Linux
Target Milestone: ---
Assignee: Michael K. Johnson
QA Contact:
Depends On:
TreeView+ depends on / blocked
Reported: 2000-01-31 23:46 UTC by cac
Modified: 2008-05-01 15:37 UTC (History)
0 users

Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Last Closed: 2000-02-15 22:14:55 UTC
Type: ---
Regression: ---
Mount Type: ---
Documentation: ---
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---

Attachments (Terms of Use)

Description cac 2000-01-31 23:46:30 UTC
LILO fails to initialize the "name" and "password" strings of the
IMAGE_DESCR struct to zero. LILO relies on strcpy to put a trailing zero in
the field so that the boot loader correctly interprets the field, and
ignores any bytes after the trailing NUL.

This problem does not affect the operation of LILO or the boot process, but
in order to pass Quality Assurance, I need successive builds to produce
bit-wise identical results, and because of the problem the /boot/map file
ends up with random characters in the name and passwd fields.

I believe that a code change along the lines of:

  static void bsect_common ( ....)

-  *descr->password = 0;
+  memset (descr->password, 0, MAX_PW + 1);
+  memset (descr->name, 0, MAX_NAME + 1);


would do the trick.

Comment 1 Jeremy Katz 2002-06-04 05:05:25 UTC
This is perfectly reasonable due to the way that data segments get initialized
on Linux

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