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

Bug#930366: marked as done (initramfs-tools: unmkinitramfs fails to unpack lz4 compressed initrd)



Your message dated Fri, 23 Aug 2019 07:57:03 +0000
with message-id <E1i14RT-00065z-KH@fasolo.debian.org>
and subject line Bug#930366: fixed in initramfs-tools 0.133+deb10u1
has caused the Debian Bug report #930366,
regarding initramfs-tools: unmkinitramfs fails to unpack lz4 compressed initrd
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.)


-- 
930366: https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=930366
Debian Bug Tracking System
Contact owner@bugs.debian.org with problems
--- Begin Message ---
Package: initramfs-tools
Version: 0.133
Severity: normal
Tags: patch

Dear Maintainer,

unmkinitramfs fails to unpack lz4 compressed initrd, ie.:

$ sudo apt install initramfs-tools lz4 file
$ mkinitramfs -c lz4 -o foo.img
$ unmkinitramfs foo.img bar
cpio: premature end of archive
$ echo $?
2

I think this is because lz4cat is strict with file extensions:

$ file foo.img 
foo.img: LZ4 compressed data (v0.1-v0.9)
$ lz4cat -t foo.img 
File extension doesn't match expected LZ4_EXTENSION (.lz4); will not process file: foo.img

I propose the attached patch to change 'lz4cat -t $archive'
invocations to become 'lz4cat -t <$archive' instead. As lz4cat does
not / cannot enforce extension checking on streams.

Regards,

Dimitri.
diff -Nru initramfs-tools-0.133ubuntu6/unmkinitramfs initramfs-tools-0.133ubuntu8/unmkinitramfs
--- initramfs-tools-0.133ubuntu6/unmkinitramfs	2019-06-07 19:22:58.000000000 +0000
+++ initramfs-tools-0.133ubuntu8/unmkinitramfs	2019-06-09 23:21:17.000000000 +0000
@@ -33,8 +33,8 @@
 		gzip -c -d "$archive"
 	elif xzcat -t "$archive" >/dev/null 2>&1 ; then
 		xzcat "$archive"
-	elif lz4cat -t "$archive" >/dev/null 2>&1 ; then
-		lz4cat "$archive"
+	elif lz4cat -t <"$archive" >/dev/null 2>&1 ; then
+		lz4cat <"$archive"
 	elif bzip2 -t "$archive" >/dev/null 2>&1 ; then
 		bzip2 -c -d "$archive"
 	elif lzop -t "$archive" >/dev/null 2>&1 ; then


--- End Message ---
--- Begin Message ---
Source: initramfs-tools
Source-Version: 0.133+deb10u1

We believe that the bug you reported is fixed in the latest version of
initramfs-tools, 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 930366@bugs.debian.org,
and the maintainer will reopen the bug report if appropriate.

Debian distribution maintenance software
pp.
Ben Hutchings <ben@decadent.org.uk> (supplier of updated initramfs-tools 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@ftp-master.debian.org)


-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA512

Format: 1.8
Date: Fri, 23 Aug 2019 02:16:37 +0100
Source: initramfs-tools
Architecture: source
Version: 0.133+deb10u1
Distribution: buster
Urgency: medium
Maintainer: Debian kernel team <debian-kernel@lists.debian.org>
Changed-By: Ben Hutchings <ben@decadent.org.uk>
Closes: 916696 928689 928736 930366 930754
Changes:
 initramfs-tools (0.133+deb10u1) buster; urgency=medium
 .
   [ Ben Hutchings ]
   * [998371a] hooks/resume: Disable resume when there are no suitable swap
     devices. Thanks to Trek <trek00@inbox.ru> (Closes: #916696)
   * [d653197] hook-functions: Include all keyboard driver modules when
     MODULES=most. Thanks to Alper Nebi Yasak <alpernebiyasak@gmail.com>
   * [5681ccb] hook-functions: Include cros_ec_spi and SPI drivers when
     MODULES=most. Thanks to Alper Nebi Yasak <alpernebiyasak@gmail.com>
   * [8d62542] resume: Set plymouth status only if there is a suspend image
     (Closes: #928736)
   * [073586a] hook-functions: Fix copy_file with target of "/bin"
     (Closes: #928689)
   * [a78d9a5] unmkinitramfs: Work around lz4cat filename check.
     Thanks to Dimitri John Ledkov <xnox@ubuntu.com> (Closes: #930366)
   * [48a35de] update-initramfs(8): Update description of "-k all" option
 .
   [ Alper Nebi Yasak ]
   * [1abb6f6] hook-functions: Include extcon-usbc-cros-ec when MODULES=most
   * [db6d4e2] hook-functions: Include extcon drivers when MODULES=dep
 .
   [ Uwe Kleine-König ]
   * [360fb48] mkinitramfs: suppress warning when using bzip2 or lzma
     (Closes: #930754)
Checksums-Sha1:
 1541b4607a86dadebe2aabe08f391f8413f77fd5 1853 initramfs-tools_0.133+deb10u1.dsc
 381e708765f000420ba283f78275abb3a659cca7 90600 initramfs-tools_0.133+deb10u1.tar.xz
 f34193508db55b569fd2b58ce37bb3ee8748cec1 6202 initramfs-tools_0.133+deb10u1_source.buildinfo
Checksums-Sha256:
 3b76e73268fe4af04cafef8474352492781848dd2ad8ec9c176360f658e52b00 1853 initramfs-tools_0.133+deb10u1.dsc
 fc892de827952b0d51a9dd8e916fedf441039db7256da301715b028855114f34 90600 initramfs-tools_0.133+deb10u1.tar.xz
 2b5efddc78fd17ff2b9638f9ac4acb05566121db90d5c34746e66ab6cc1942b2 6202 initramfs-tools_0.133+deb10u1_source.buildinfo
Files:
 ecd7ebf3e0a93ae141b9ea2fe25a9fa7 1853 utils optional initramfs-tools_0.133+deb10u1.dsc
 258df11dfdc5f1434621ae0bcaf58907 90600 utils optional initramfs-tools_0.133+deb10u1.tar.xz
 32c0531b69164a84739464324ee27c04 6202 utils optional initramfs-tools_0.133+deb10u1_source.buildinfo

-----BEGIN PGP SIGNATURE-----

iQIzBAEBCgAdFiEErCspvTSmr92z9o8157/I7JWGEQkFAl1fQE8ACgkQ57/I7JWG
EQla/g//bR6iOmu3CBiKOMgeGZj3iB1N7pJ9FWnzTH0tOz/CPTohuSxPCD84+yHg
bFZxkA/D/a7iDVqLFcFRAshYK9JWaYYAKf7O3cUUIQakqMc2BQQnT83PS04L/1FY
DWx0/HWdMnlSlYZ7nj+5qcRctrtpOy3VjppXLMcT4KCv+Vk42VboGvaVaTUlP2qr
1Y1glvuEc2uT1LPRNLalSDIKpdBFXlsoUm/j/idShSAdjRlUX5qmTtj7bS9EruI8
XMhgpo7L1LjnB5/CJMSZPF4+b4rDZOlYfPoHfN9v4M/MzXmbpPstLpXu1zf4jM68
KoLhOlIgkdpWdwuJe3kzMAJavfn1ubZ3FxoOo1SsLfpjmu4r1u0Ntmq2lSMMxQMe
OfmgiUS5C+daT5zucLyW/376ed3TyYoM8B9cF1b02AVv0NqJ6WOPJEWIRp51h1/U
rJB9G0Z/Auzg2wHYrKvoJ0UEQDQmNM5BcppQMAq9dBYYRT5W4UDIbEfb/Cqur5SX
eeV059sL6aiOuCXrtY83IsKXp23Pqm3dlH/kDgczbd4Fr9AVs6t8t/FeN2L9vfFS
5ki5sQld0FaVoANmM5zJggegY7U3fDTnmX1JK+DlX+G5yC1WFZbjhG7wETIBaDy4
qj92J3UMQ7oVvNqu7aF+XGff+L2x8DFPgVSU/fcMmN9u3z0oP9U=
=1DHC
-----END PGP SIGNATURE-----

--- End Message ---

Reply to: