[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Bug#684611: marked as done (busybox fails to parse less-than-3-component linux version string)



Your message dated Thu, 20 Sep 2012 08:47:55 +0000
with message-id <E1TEcQN-0005xS-CN@franck.debian.org>
and subject line Bug#684611: fixed in busybox 1:1.20.0-7
has caused the Debian Bug report #684611,
regarding busybox fails to parse less-than-3-component linux version string
to be marked as done.

This means that you claim that the problem has been dealt with.
If this is not the case it is now your responsibility to reopen the
Bug report if necessary, and/or fix the problem forthwith.

(NB: If you are a system administrator and have no idea what this
message is talking about, this may indicate a serious mail system
misconfiguration somewhere. Please contact owner@bugs.debian.org
immediately.)


-- 
684611: http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=684611
Debian Bug Tracking System
Contact owner@bugs.debian.org with problems
--- Begin Message ---
Source: busybox
Version: 1:1.20.0-5
Severity: important
Tags: patch upstream
Forwarded: https://bugs.busybox.net/show_bug.cgi?id=5444

Busybox have the same issue with 2-component linux version code as
lots of other utils had (discovered when linux 3.0 were released):
it just segfaults when such a kernel is used.

This does not affect wheezy directly, since wheezy uses 3.2.0 kernel
(with fake trailing zero to work around exactly this problem in
various software), but yet it is important to get this fixed for
wheezy, to let backported and self-compiled kernels to work.
Especially since busybox is used in initramfs to boot the system.

Patch to fix this issue is below.

/mjt

Subject: allow less-than-3-component kernel version number
From: Michael Tokarev <mjt@tls.msk.ru>
Forwarded: https://bugs.busybox.net/show_bug.cgi?id=5444

Busybox expects at least 3-component linux version number,
and segfaults if less than 3 components are available.

--- debian.orig/libbb/kernel_version.c
+++ debian/libbb/kernel_version.c
@@ -21,18 +21,19 @@
 {
 	struct utsname name;
 	char *s;
-	int i, r;
+	int r;
  	if (uname(&name) == -1) {
 		bb_perror_msg("can't get system information");
 		return 0;
 	}
 -	s = name.release;
-	r = 0;
-	for (i = 0; i < 3; i++) {
-		r = r * 256 + atoi(strtok(s, "."));
-		s = NULL;
+	r = atoi(strtok(name.release, ".")) * 256 * 256;
+	if ((s = strtok(NULL, ".")) != NULL) {
+		r |= atoi(s) * 256;
+		if ((s = strtok(NULL, ".")) != NULL)
+			r |= atoi(s);
 	}
+
 	return r;
 }

--- End Message ---
--- Begin Message ---
Source: busybox
Source-Version: 1:1.20.0-7

We believe that the bug you reported is fixed in the latest version of
busybox, which is due to be installed in the Debian FTP archive.

A summary of the changes between this version and the previous one is
attached.

Thank you for reporting the bug, which will now be closed.  If you
have further comments please address them to 684611@bugs.debian.org,
and the maintainer will reopen the bug report if appropriate.

Debian distribution maintenance software
pp.
Michael Tokarev <mjt@tls.msk.ru> (supplier of updated busybox package)

(This message was generated automatically at their request; if you
believe that there is a problem with it please contact the archive
administrators by mailing ftpmaster@debian.org)


-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

Format: 1.8
Date: Thu, 20 Sep 2012 10:32:55 +0400
Source: busybox
Binary: busybox busybox-static busybox-udeb busybox-syslogd udhcpc udhcpd
Architecture: source all i386
Version: 1:1.20.0-7
Distribution: unstable
Urgency: low
Maintainer: Debian Install System Team <debian-boot@lists.debian.org>
Changed-By: Michael Tokarev <mjt@tls.msk.ru>
Description: 
 busybox    - Tiny utilities for small and embedded systems
 busybox-static - Standalone rescue shell with tons of builtin utilities
 busybox-syslogd - Provides syslogd and klogd using busybox
 busybox-udeb - Tiny utilities for the debian-installer (udeb)
 udhcpc     - Provides the busybox DHCP client implementation
 udhcpd     - Provides the busybox DHCP server implementation
Closes: 652672 684611
Changes: 
 busybox (1:1.20.0-7) unstable; urgency=low
 .
   * set CONFIG_FEATURE_COPYBUF_KB from 4 to 64 for all flavours.  This
     increases speed of various applets *dramatically*.  For example, wget
     applet downlad time for certain file decreased from 3.8sec to 0.6sec.
   * modprobe-read-modules-builtin.patch: stop modprobe from complaining
     when asked to load a "module" which is built-in.  Thank you
     Ben Hutchings for the patch. (Closes: #652672)
   * udeb: enable ping6 applet and FEATURE_FANCY_PING - more featureful
     ping(6) variant with statistics et al.  This makes ping6 available in
     d-i (initial network debugging), and makes ping there not only more
     useful but also using a more tested code, as used in other variants.
     4Kb file size increase on i386.
   * stop-checking-ancient-kernel-version.patch: a rather trivial patch
     to disable compatibility code for kernels <2.2.18 in nfs mount.
     This was the only place in debian busybox which used
     get_linux_version_code() function which was buggy on kernels with
     less than 3 components version number.  So instead of fixing that
     function, we got rid of the last user of it.  (Closes: #684611)
Checksums-Sha1: 
 e889eef1794958f12671118dfecc929ee7362eec 1610 busybox_1.20.0-7.dsc
 4cdbb29e66e1bc5986878baf4088b6d93fe23457 57915 busybox_1.20.0-7.debian.tar.gz
 fb7708e45ba80f94ab6a731446dd160ca81e4acf 20604 busybox-syslogd_1.20.0-7_all.deb
 7c989d8a04c678e5a965d2e23a708527a10137b7 876744 busybox-static_1.20.0-7_i386.deb
 269f0e6255904b4bf664fccaf39b98e6740c70f9 440902 busybox_1.20.0-7_i386.deb
 1990a093a3729eff368546644968755723f8281d 18142 udhcpc_1.20.0-7_i386.deb
 0de48462a30e77a5b479a8fd1dda5bdc84cc6205 21510 udhcpd_1.20.0-7_i386.deb
 985bdb98d131c1c9b2ef66278572848627f63576 178296 busybox-udeb_1.20.0-7_i386.udeb
Checksums-Sha256: 
 6ead33e18508ba3f8ed51406d2d487025279f82e50b094857379ecce84e33a6c 1610 busybox_1.20.0-7.dsc
 0bcbb11216f859c7f41c96f7b21fc9d6165282f9a58b3d1fe9d9dff2c96e1791 57915 busybox_1.20.0-7.debian.tar.gz
 6a334128601674c55b429c6ae3e64ec804b8979107465788a168d34d183f413a 20604 busybox-syslogd_1.20.0-7_all.deb
 172c88a32b34ccce0fb50468325729ee8409f236986e75c113b8305036548a14 876744 busybox-static_1.20.0-7_i386.deb
 b1468a23002b3135c5bf6dbf00b999e530332b0f703c148d112d80af6c7a37f3 440902 busybox_1.20.0-7_i386.deb
 2a90c7ab3407b96354f415c034aef0120856008d6e00e009df55a0d0d3890976 18142 udhcpc_1.20.0-7_i386.deb
 32c32b247096d517f898a995abc7acfd1500309025fa141c700aaa4b08c1782a 21510 udhcpd_1.20.0-7_i386.deb
 c9f50ec742228bc44a3c68e20b4d67ffe1b95ec55ed5e16b2f8e66f56175ba30 178296 busybox-udeb_1.20.0-7_i386.udeb
Files: 
 509650ecbdf198f7bd1758849c054ba1 1610 utils optional busybox_1.20.0-7.dsc
 5a13c668dd85178ca2afdf6692e596ec 57915 utils optional busybox_1.20.0-7.debian.tar.gz
 e2acb96e4b4e5aa16213384403aa9dd8 20604 utils optional busybox-syslogd_1.20.0-7_all.deb
 e4d88aaa4ccd61137fe12867e0d4835d 876744 shells extra busybox-static_1.20.0-7_i386.deb
 9bd499979ac7ce0e3b32de1de5946984 440902 utils optional busybox_1.20.0-7_i386.deb
 95950da6b6ced050636b0da03a1aa119 18142 net optional udhcpc_1.20.0-7_i386.deb
 a11f08a6b3cf8e756af6c8969d81fafb 21510 net optional udhcpd_1.20.0-7_i386.deb
 30092cf5bfc4d859011d9290083dbd27 178296 debian-installer extra busybox-udeb_1.20.0-7_i386.udeb

-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.12 (GNU/Linux)

iJwEAQECAAYFAlBauckACgkQUlPFrXTwyDjjVAP+OqrI195GGL46RqcUcf/kOP/y
XoUcf+OkDvpGqPhQLuoZHtOWwSrgqMzxlziJacasXApwZZxSNEpW3o4ozyGR9j7a
NRTE0syMTD54PCViwHcOPtvG7CYcQ5NdmE8EigdOGJTdpHg69IbcmcAjUxZQ5AaD
FKZdyKcaKKbVxzd7wns=
=cbJg
-----END PGP SIGNATURE-----

--- End Message ---

Reply to: