Hello, I can't reproduce the crash. I tried with the normal binary and also a new build using your arguments.
I get a lot of "Nonfatal Error : 'SEGV-Get32s-exif-333' Illegal number format 1024 for tag 0000 in Exif" but NO crash. How can I reproduce the problem? Bye Le 06/08/2020 à 05:14, Anshunkang Zhou a écrit :
Package: jhead Version: 1:3.04-2 Severity: important Dear Maintainer, I found a segmentation fault in the latest version of jhead, detailed information is as follows, the poc is in the mail attachment. ## System info Ubuntu x86_64, gcc , jhead (latest 1:3.04-2) ## Configure CFLAGS="-g -fsanitize=address" LDFLAGS="-fsanitize=address" make ## Command line ./jhead -ft -exifmap -de -purejpg -di -dx @@ ## Output ``` Segmentation fault ``` ## AddressSanitizer output ``` ASAN:SIGSEGV ================================================================= ==17939==ERROR: AddressSanitizer: SEGV on unknown address 0x61a00003f28c (pc 0x00000041a7f0 bp 0x000000000000 sp 0x7ffc54eee3a0 T0) #0 0x41a7ef in Get32s /home/seviezhou/jhead/exif.c:333 #1 0x42c908 in ProcessGpsInfo /home/seviezhou/jhead/gpsinfo.c:138 #2 0x42411f in ProcessExifDir /home/seviezhou/jhead/exif.c:866 #3 0x423e0e in ProcessExifDir /home/seviezhou/jhead/exif.c:852 #4 0x4255e1 in process_EXIF /home/seviezhou/jhead/exif.c:1041 #5 0x4103ad in ReadJpegSections /home/seviezhou/jhead/jpgfile.c:287 #6 0x4117ce in ReadJpegSections /home/seviezhou/jhead/jpgfile.c:126 #7 0x4117ce in ReadJpegFile /home/seviezhou/jhead/jpgfile.c:379 #8 0x408e4e in ProcessFile /home/seviezhou/jhead/jhead.c:905 #9 0x402e40 in main /home/seviezhou/jhead/jhead.c:1756 #10 0x7ffacc7e783f in __libc_start_main (/lib/x86_64-linux-gnu/libc.so.6+0x2083f) #11 0x406c88 in _start (/home/seviezhou/jhead/jhead+0x406c88) AddressSanitizer can not provide additional info. SUMMARY: AddressSanitizer: SEGV /home/seviezhou/jhead/exif.c:333 Get32s ==17939==ABORTING ```
-- Dr. Ludovic Rousseau