Hi Salvatore,
How to reproduce your bug?
I'm currently using valgrind with the rar file you provided. And found
that there are some unconditional jump based some uninit value. Please
see the attachment [1].
After fixing that [2], valgrind is happy now without any errors.
Not sure if this is related to this bug.
Attaching the autopkgtest scripts [3] for testing the package.
If this looks good for you I'll upload this soon.
[1] val_log1.txt
[2] 0002-CVE-2017-14122.patch
[3] 0003-CVE-2017-14122
Yours Sincerely,
Paul
--
PaulLiu (劉穎駿)
E-mail: Ying-Chun Liu (PaulLiu)
==4627== Memcheck, a memory error detector
==4627== Copyright (C) 2002-2017, and GNU GPL'd, by Julian Seward et al.
==4627== Using Valgrind-3.13.0 and LibVEX; rerun with -h for copyright info
==4627== Command: /usr/bin/unrar-free x unrar-gpl-stack-overread.rar
==4627== Parent PID: 11514
==4627==
==4627== Use of uninitialised value of size 8
==4627==at 0x10BCE7: CalcCRC32 (unrarlib.c:2180)
==4627==by 0x10BCE7: ReadHeader (unrarlib.c:627)
==4627==by 0x10C090: ReadBlock (unrarlib.c:506)
==4627==by 0x10C5A5: urarlib_list (unrarlib.c:389)
==4627==by 0x10A911: unrar_extract (unrar.c:425)
==4627==by 0x109CB4: main (unrar.c:561)
==4627== Uninitialised value was created by a stack allocation
==4627==at 0x10BAE0: ReadHeader (unrarlib.c:596)
==4627==
==4627== Conditional jump or move depends on uninitialised value(s)
==4627==at 0x10BFEB: ReadBlock (unrarlib.c:509)
==4627==by 0x10C5A5: urarlib_list (unrarlib.c:389)
==4627==by 0x10A911: unrar_extract (unrar.c:425)
==4627==by 0x109CB4: main (unrar.c:561)
==4627== Uninitialised value was created by a stack allocation
==4627==at 0x10BAE0: ReadHeader (unrarlib.c:596)
==4627==
==4627== Conditional jump or move depends on uninitialised value(s)
==4627==at 0x10C022: ReadBlock (unrarlib.c:514)
==4627==by 0x10C5A5: urarlib_list (unrarlib.c:389)
==4627==by 0x10A911: unrar_extract (unrar.c:425)
==4627==by 0x109CB4: main (unrar.c:561)
==4627== Uninitialised value was created by a stack allocation
==4627==at 0x10BAE0: ReadHeader (unrarlib.c:596)
==4627==
==4627== Conditional jump or move depends on uninitialised value(s)
==4627==at 0x4C2BACC: malloc (vg_replace_malloc.c:298)
==4627==by 0x4C2DE9F: realloc (vg_replace_malloc.c:785)
==4627==by 0x10C282: ReadBlock (unrarlib.c:538)
==4627==by 0x10C5A5: urarlib_list (unrarlib.c:389)
==4627==by 0x10A911: unrar_extract (unrar.c:425)
==4627==by 0x109CB4: main (unrar.c:561)
==4627== Uninitialised value was created by a stack allocation
==4627==at 0x10BAE0: ReadHeader (unrarlib.c:596)
==4627==
==4627== Conditional jump or move depends on uninitialised value(s)
==4627==at 0x4E9FA54: fread (iofread.c:35)
==4627==by 0x10C2A4: fread (stdio2.h:295)
==4627==by 0x10C2A4: ReadBlock (unrarlib.c:539)
==4627==by 0x10C5A5: urarlib_list (unrarlib.c:389)
==4627==by 0x10A911: unrar_extract (unrar.c:425)
==4627==by 0x109CB4: main (unrar.c:561)
==4627== Uninitialised value was created by a stack allocation
==4627==at 0x10BAE0: ReadHeader (unrarlib.c:596)
==4627==
==4627== Conditional jump or move depends on uninitialised value(s)
==4627==at 0x4EAA9C8: _IO_file_xsgetn (fileops.c:1386)
==4627==by 0x4E9FAD8: fread (iofread.c:38)
==4627==by 0x10C2A4: fread (stdio2.h:295)
==4627==by 0x10C2A4: ReadBlock (unrarlib.c:539)
==4627==by 0x10C5A5: urarlib_list (unrarlib.c:389)
==4627==by 0x10A911: unrar_extract (unrar.c:425)
==4627==by 0x109CB4: main (unrar.c:561)
==4627== Uninitialised value was created by a stack allocation
==4627==at 0x10BAE0: ReadHeader (unrarlib.c:596)
==4627==
==4627== Conditional jump or move depends on uninitialised value(s)
==4627==at 0x4EAA9E0: _IO_file_xsgetn (fileops.c:1389)
==4627==by 0x4E9FAD8: fread (iofread.c:38)
==4627==by 0x10C2A4: fread (stdio2.h:295)
==4627==by 0x10C2A4: ReadBlock (unrarlib.c:539)
==4627==by 0x10C5A5: urarlib_list (unrarlib.c:389)
==4627==by 0x10A911: unrar_extract (unrar.c:425)
==4627==by 0x109CB4: main (unrar.c:561)
==4627== Uninitialised value was created by a stack allocation
==4627==at 0x10BAE0: ReadHeader (unrarlib.c:596)
==4627==
==4627== Conditional jump or move depends on uninitialised value(s)
==4627==at 0x4EAAA2C: _IO_file_xsgetn (fileops.c:1420)
==4627==by 0x4E9FAD8: fread (iofread.c:38)
==4627==by 0x10C2A4: fread (stdio2.h:295)
==4627==by 0x10C2A4: ReadBlock (unrarlib.c:539)
==4627==by 0x10C5A5: urarlib_list (unrarlib.c:389)
==4627==by 0x10A911: unrar_extract (unrar.c:425)
==4627==by 0x109CB4: main (unrar.c:561)
==4627== Uninitialised value was created by a stack allocation
==4627==at 0x10BAE0: ReadHeader (unrarlib.c:596)
==4627==
==4627== Conditional jump or move depends on uninitialised value(s)
==4627==at 0x4E9FB27: fread (iofread.c:40)
==4627==