{"id":"CVE-2018-8905","details":"In LibTIFF 4.0.9, a heap-based buffer overflow occurs in the function LZWDecodeCompat in tif_lzw.c via a crafted TIFF file, as demonstrated by tiff2ps.","modified":"2026-03-20T11:26:47.307816Z","published":"2018-03-22T04:29:00.483Z","related":["MGASA-2018-0246","SUSE-SU-2018:1826-1","SUSE-SU-2018:1835-1","SUSE-SU-2018:1889-1","openSUSE-SU-2024:11461-1"],"references":[{"type":"ADVISORY","url":"https://access.redhat.com/errata/RHSA-2019:2053"},{"type":"ADVISORY","url":"https://lists.debian.org/debian-lts-announce/2018/05/msg00008.html"},{"type":"ADVISORY","url":"https://lists.debian.org/debian-lts-announce/2018/05/msg00009.html"},{"type":"ADVISORY","url":"https://lists.debian.org/debian-lts-announce/2018/07/msg00002.html"},{"type":"ADVISORY","url":"https://www.debian.org/security/2018/dsa-4349"},{"type":"ADVISORY","url":"https://usn.ubuntu.com/3864-1/"},{"type":"REPORT","url":"http://bugzilla.maptools.org/show_bug.cgi?id=2780"},{"type":"FIX","url":"https://gitlab.com/libtiff/libtiff/commit/58a898cb4459055bb488ca815c23b880c242a27d"},{"type":"EVIDENCE","url":"https://github.com/halfbitteam/POCs/tree/master/libtiff-4.08_tiff2ps_heap_overflow"}],"affected":[{"ranges":[{"type":"GIT","repo":"https://github.com/vadz/libtiff","events":[{"introduced":"0"},{"last_affected":"636f2684a0faaf9510ae4219f286a53f98f37483"}],"database_specific":{"versions":[{"introduced":"0"},{"last_affected":"4.0.9"}]}},{"type":"GIT","repo":"https://gitlab.com/libtiff/libtiff","events":[{"introduced":"0"},{"fixed":"58a898cb4459055bb488ca815c23b880c242a27d"}]}],"versions":["Pre360","Release-","Release-3-7-0","Release-v3-5-","Release-v3-5-4","Release-v3-5-5","Release-v3-5-7","Release-v3-6-0","Release-v3-6-0beta2","Release-v3-6-1","Release-v3-7-0-alpha","Release-v3-7-0beta","Release-v3-7-0beta2","Release-v3-7-1","Release-v3-7-2","Release-v3-7-3","Release-v3-7-4","Release-v3-8-0","Release-v3-8-1","Release-v3-8-2","Release-v4-0-0","Release-v4-0-0alpha","Release-v4-0-0alpha4","Release-v4-0-0alpha5","Release-v4-0-0alpha6","Release-v4-0-0beta7","Release-v4-0-1","Release-v4-0-2","Release-v4-0-3","Release-v4-0-4","Release-v4-0-4beta","Release-v4-0-5","Release-v4-0-6","Release-v4-0-7","Release-v4-0-8","Release-v4-0-9","v3.5.3","v3.5.4","v3.5.5","v3.5.7","v3.6.0","v3.6.0beta2","v3.6.1","v3.7.0","v3.7.0alpha","v3.7.0beta","v3.7.0beta2","v3.7.1","v3.7.2","v3.7.3","v3.7.4","v3.8.0","v3.8.1","v3.8.2","v4.0.0","v4.0.0alpha","v4.0.0alpha4","v4.0.0alpha5","v4.0.0alpha6","v4.0.0beta7","v4.0.1","v4.0.2","v4.0.3","v4.0.4","v4.0.4beta","v4.0.5","v4.0.6","v4.0.7","v4.0.8","v4.0.9"],"database_specific":{"vanir_signatures":[{"deprecated":false,"digest":{"length":4134,"function_hash":"120825719578505321660184962155054746977"},"target":{"function":"LZWDecodeCompat","file":"libtiff/tif_lzw.c"},"source":"https://gitlab.com/libtiff/libtiff@58a898cb4459055bb488ca815c23b880c242a27d","signature_type":"Function","id":"CVE-2018-8905-3fbe4683","signature_version":"v1"},{"deprecated":false,"digest":{"threshold":0.9,"line_hashes":["177967733808906035883593633810155823881","203737156195573976975904104044591611902","167066477237446475925485410116217217762","173059985397098238975525246124703618955","99427663126675737957365031708259496074","289243857886536227372722331896346644343","10214055182485147416901345635429964874","183337954797534262759069573818295556151","139234947298997046072255456576489018581","244051190731298221544905369957809947884","94663415500484428692874645151769140260","212093616533759937923555560260924140032","35273233916047150958507687928769187078","217767932149858445127393940380373206037"]},"target":{"file":"libtiff/tif_lzw.c"},"source":"https://gitlab.com/libtiff/libtiff@58a898cb4459055bb488ca815c23b880c242a27d","signature_type":"Line","id":"CVE-2018-8905-e4506fa1","signature_version":"v1"}],"unresolved_ranges":[{"events":[{"introduced":"0"},{"last_affected":"7.0"}]},{"events":[{"introduced":"0"},{"last_affected":"8.0"}]},{"events":[{"introduced":"0"},{"last_affected":"9.0"}]},{"events":[{"introduced":"0"},{"last_affected":"14.04"}]},{"events":[{"introduced":"0"},{"last_affected":"16.04"}]},{"events":[{"introduced":"0"},{"last_affected":"18.04"}]},{"events":[{"introduced":"0"},{"last_affected":"18.10"}]},{"events":[{"introduced":"0"},{"last_affected":"7.0"}]},{"events":[{"introduced":"0"},{"last_affected":"7.0"}]},{"events":[{"introduced":"0"},{"last_affected":"7.0"}]}],"source":"https://storage.googleapis.com/osv-test-cve-osv-conversion/osv-output/CVE-2018-8905.json"}}],"schema_version":"1.7.5","severity":[{"type":"CVSS_V3","score":"CVSS:3.1/AV:N/AC:L/PR:N/UI:R/S:U/C:H/I:H/A:H"}]}