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

Bug#638963: marked as done (busybox: undefined behavior in bunzip2)



Your message dated Fri, 28 Oct 2011 21:30:13 +0400
with message-id <4EAAE6A5.7020507@msgid.tls.msk.ru>
and subject line Re: Bug#638963: busybox: undefined behavior in bunzip2
has caused the Debian Bug report #638963,
regarding busybox: undefined behavior in bunzip2
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.)


-- 
638963: http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=638963
Debian Bug Tracking System
Contact owner@bugs.debian.org with problems
--- Begin Message ---
Package: busybox
Version: 1:1.18.5-1
Severity: normal
Tags: patch

Function start_bunzip() in archival/libarchive/decompress_bunzip2.c, line 689
calls setjmp() in a way resulting in undefined behavior.  Patch below.


--- decompress_bunzip2.c        2011-06-12 16:55:58.000000000 +0200
+++ decompress_bunzip2_new.c    2011-08-23 13:13:31.196926790 +0200
@@ -687,6 +687,6 @@

        /* Setup for I/O error handling via longjmp */
-       i = setjmp(bd->jmpbuf);
-       if (i) return i;
+       if (setjmp(bd->jmpbuf))
+               return RETVAL_UNEXPECTED_INPUT_EOF;

        /* Ensure that file starts with "BZh['1'-'9']." */



-- System Information:
Debian Release: wheezy/sid
  APT prefers unstable
  APT policy: (500, 'unstable'), (500, 'testing')
Architecture: amd64 (x86_64)

Kernel: Linux 2.6.39-2-amd64 (SMP w/4 CPU cores)
Locale: LANG=pl_PL.utf8, LC_CTYPE=pl_PL.utf8 (charmap=UTF-8)
Shell: /bin/sh linked to /bin/dash

Versions of packages busybox depends on:
ii  libc6                         2.13-16    Embedded GNU C Library: Shared lib

busybox recommends no packages.

busybox suggests no packages.

-- no debconf information



--- End Message ---
--- Begin Message ---
Version: 1:1.19.2-1

On 23.08.2011 15:23, Mikolaj Izdebski wrote:
> Package: busybox
> Version: 1:1.18.5-1
> Severity: normal
> Tags: patch
> 
> Function start_bunzip() in archival/libarchive/decompress_bunzip2.c, line 689
> calls setjmp() in a way resulting in undefined behavior.  Patch below.
> 
> 
> --- decompress_bunzip2.c        2011-06-12 16:55:58.000000000 +0200
> +++ decompress_bunzip2_new.c    2011-08-23 13:13:31.196926790 +0200
> @@ -687,6 +687,6 @@
> 
>         /* Setup for I/O error handling via longjmp */
> -       i = setjmp(bd->jmpbuf);
> -       if (i) return i;
> +       if (setjmp(bd->jmpbuf))
> +               return RETVAL_UNEXPECTED_INPUT_EOF;

This code is #ifdef'ed out in 1.19 version:


/* In bbox, we are ok with aborting through setjmp which is set up in start_bunzip */
#if 0
        /* Reset longjmp I/O error handling */
        i = setjmp(bd->jmpbuf);
        if (i) return i;
#endif

So closing this bug.

Thank you!

/mjt


--- End Message ---

Reply to: