CVE-2017-9614
Status: Alpha
Brought to you by:
robde
I researched a recent CVE report https://cve.mitre.org/cgi-bin/cvename.cgi?name=CVE-2017-9614. I believe it is caused by a bug in stills2dv. In the s2d_jpg.c readjpg() function, fclose() is called before jpeg_finish_decompress(). This triggers a memory access error during the file read operation reading the file trailer within jpeg_finish_decompress().
The correct sequence should be:
jpeg_finish_decompress(&cinfo);
jpeg_destroy_decompress(&cinfo);
fclose(in);