Skip to main content

LibTIFF CVE-2025-8176

LOW
Buffer Overflow (CWE-119)
2025-07-26 cna@vuldb.com
1.9
CVSS 4.0 · NVD
View

Attack ChainAIDerived

Hypothetical attack flow derived from CVE metadata – not a confirmed exploit chain

  1. Access
    Obtain local system access
  2. Delivery
    Craft malicious TIFF file
  3. Exploit
    Invoke tiffmedian on crafted file
  4. Execution
    Trigger use-after-free in get_histogram
  5. Impact
    Cause denial of service or information leak

Vulnerability Assessment

Weakness
CWE
ASVS 5.0
V15 - Secure Coding and Architecture Bounds checking, buffer size validation
MITRE ATT&CK

2 techniques across 2 tactics: Execution, Privilege Escalation

The technique list with ATT&CK links and the kill-chain view is part of the Basic plan and up.

Exploitation Conditions

Exploitation requires: (1) local command-line access to the affected system (AV:L), (2) authenticated user account with execution privileges (PR:L), (3) ability to supply a malformed TIFF file to the tiffmedian utility or an application that uses the vulnerable get_histogram function internally, and (4) the vulnerable LibTIFF version (up to 4.7.0) must be installed and active. The attack does not require user interaction beyond normal tool invocation (UI:N). Systems where LibTIFF is only used as a backend library (not via direct tiffmedian command-line tool) remain vulnerable if the application exposes TIFF processing to local users. Systems running patched versions, versions after 4.7.0, or deployments where local users lack execution permissions on TIFF processing utilities are not affected.

Impact

This vulnerability presents a significant discrepancy between declared severity and real-world exploitability. The CVSS 4.0 vector (AV:L/AC:L/PR:L) correctly identifies local-only access with low attack complexity but authenticated privileges required (PR:L), limiting exposure to users with local shell access to an affected system. The impact scope is confined (VC:L/VI:L/VA:L with no scope change), producing a CVSS score of 1.9 - legitimately low. However, EPSS at 0.03% (7th percentile) indicates minimal real-world exploitation probability despite publicly available POC code, suggesting the exploit either requires specific conditions, works against outdated versions, or has limited practical utility beyond denial of service. The declaration as 'critical' by the source appears inconsistent with CVSS and EPSS data; this may reflect conservative library maintainer standards or the presence of use-after-free in memory-critical code. For organizations embedding LibTIFF in user-facing applications processing untrusted TIFF files, the local authentication requirement significantly reduces risk compared to network-exposed vulnerabilities. Patch availability and low attack complexity favor rapid remediation.

Exploit ScenarioDerived

An authenticated local user with shell access to a system running a vulnerable LibTIFF version processes a specially crafted TIFF file using the tiffmedian utility, triggering the use-after-free condition in get_histogram. Depending on heap state, this could cause a denial of service crash (most likely outcome given CVSS impact scores) or, with precise heap spray techniques, potentially leak sensitive data from process memory. The public exploit code referenced in GitLab issue #707 likely demonstrates the crash condition; achieving reliable code execution would require additional heap manipulation not confirmed in available reports.

Monitor Track and reassess. Why: LOW severity (CVSS 0.1-3.9).
Patch available 0.0% exploitation probability (EPSS)

Get an e-mail when this CVE is exploited, patched or re-scored. Free account.

Alert me

AnalysisAIv1 – Apr 29, 2026

Use-after-free vulnerability in LibTIFF up to version 4.7.0 affects the get_histogram function in tiffmedian.c, allowing local authenticated attackers to cause denial of service or limited data corruption. Despite a critical severity declaration and publicly available exploit code, the CVSS 4.0 vector assigns a low score (1.9) due to local-only access requirements, high attack complexity constraints, and limited impact scope; EPSS places real exploitation probability at 0.03%, suggesting this remains a low-priority issue in typical deployments.

RemediationAI

Apply the vendor-released patch identified by commit fe10872e53efba9cc36c66ac4ab3b41a839d5172 from the LibTIFF GitLab repository (https://gitlab.com/libtiff/libtiff/-/commit/fe10872e53efba9cc36c66ac4ab3b41a839d5172). Upgrade to LibTIFF version 4.7.1 or later when released, or pull the latest development branch. For systems unable to immediately patch, implement filesystem-level access controls restricting which local users can invoke the tiffmedian utility tool (e.g., via file permissions or AppArmor/SELinux policy); this eliminates PR:L (low-privilege local user) attack surface if only trusted administrators run TIFF processing. Verify that embedded LibTIFF instances in third-party applications are updated, as security updates to the base library may not automatically propagate. Test patched builds with locally-stored TIFF files from the GitLab issue #707 to confirm the use-after-free condition is resolved before full deployment.

Affects your stack

Find out whether the stacks and servers you run are on an affected version.

Checking this CVE against your own stacks and servers is part of the Basic plan and up.

Technical ContextAI · show details

LibTIFF is a widely-used image processing library for handling Tagged Image File Format (TIFF) files, commonly embedded in applications that process image data. The vulnerability exists in tiffmedian.c, a utility tool within LibTIFF's toolkit, specifically in the get_histogram function which processes histogram data from TIFF files. The root cause is classified under CWE-119 (improper restriction of operations within the bounds of a memory buffer), manifesting as a use-after-free condition where memory is accessed after it has been freed. This memory safety flaw can occur when processing specially crafted TIFF files, potentially leading to information disclosure or denial of service depending on memory layout and exploitation context.

Know when Libtiff gets its next vulnerability

  • Watch products and get an email when something new is published
  • Check this CVE against your own stack and servers
  • Exploit and PoC references, threat intelligence from 22 sources

No credit card · 7-day full trial

Severity by source

NVD PRIMARY 1.9 LOW
CVSS:4.0/AV:L/AC:L/AT:N/PR:L/UI:N/VC:L/VI:L/VA:L/SC:N/SI:N/SA:N/E:P

Primary rating from NVD · only source for this CVE.

CVSS VectorNVD

Attack Vector
Local
Attack Complexity
Low
Attack Requirements
None
Privileges Required
Low
User Interaction
None
Vulnerable system: Confidentiality
Low
Vulnerable system: Integrity
Low
Vulnerable system: Availability
Low
Subsequent system: Confidentiality
None
Subsequent system: Integrity
None
Subsequent system: Availability
None

DescriptionCVE.org

A vulnerability was found in LibTIFF up to 4.7.0. It has been declared as critical. This vulnerability affects the function get_histogram of the file tools/tiffmedian.c. The manipulation leads to use after free. The attack needs to be approached locally. The exploit has been disclosed to the public and may be used. The patch is identified as fe10872e53efba9cc36c66ac4ab3b41a839d5172. It is recommended to apply a patch to fix this issue.

Threat Intelligence Overview

EPSS Score
0.0%
Top 93% exploitable
Exploit
POC
Public exploit code exists
Data Quality
4 sources
Confidence: Medium

How this decision was reached

The engine reads each signal below and applies a fixed list of rules from top to bottom. The first rule that matches sets the recommended action – like a statement, every line is shown.

SignalValue
Severity LOW
CISA KEV No
Public POC Yes
EPSS 0.0%
Patch available Yes
Active threat No
Deciding rule
LOW severity (CVSS 0.1-3.9)
What every action level means
Emergency Immediate action required. Criteria: CRITICAL + in CISA KEV (actively exploited) without patch, OR CRITICAL + EPSS > 30% without patch, OR CRITICAL + active threat signals without patch.
Act Now Prioritize within 24-48h. Criteria: in KEV with patch available, OR CRITICAL + public POC, OR HIGH + EPSS > 10%, OR CRITICAL + active threat, OR any CRITICAL severity.
This Week Schedule remediation this week. Criteria: HIGH severity (CVSS 7.0-8.9). Patch within normal change window.
This Month Plan within 30 days. Criteria: MEDIUM severity (CVSS 4.0-6.9), lower exploitation probability. Include in regular patch cycle.
Monitor Track and reassess. Criteria: LOW severity (CVSS 0.1-3.9), minimal exploitation risk. No immediate action needed.

SSVC AssessmentENISA

SSVC Decision· derived
Defer
Exploitation· derived
Poc
System Exposure· derived
Small
Automatable· derived
No
Human Impact· derived
Low

Priority Score

30
Low Medium High Critical
KEV: 0
EPSS: 0
CVSS: +10
PoC: +20
Weaponized: 0
Threat intel: 0
Gov advisory: 0

Attack Technique

A buffer overflow occurs when a program writes more data to a memory buffer than it was allocated to hold, causing the excess data to spill into adjacent memory regions.

Denial of Service attacks render applications or systems unavailable by overwhelming resources or triggering failure conditions.

Affected Products (CPE)CVE.org

cpe:2.3:a:libtiff:libtiff:*:*:*:*:*:*:*:*
CVE-2012-4564 MEDIUM POC
6.8 Nov 11

ppm2tiff does not check the return value of the TIFFScanlineSize function, which allows remote attackers to cause a deni

CVE-2015-8668 CRITICAL POC
9.8 Jan 08

Heap-based buffer overflow in the PackBitsPreEncode function in tif_packbits.c in bmp2tiff in libtiff 4.0.6 and earlier

CVE-2015-7554 CRITICAL POC
9.8 Jan 08

The _TIFFVGetField function in tif_dir.c in libtiff 4.0.6 allows attackers to cause a denial of service (invalid memory

CVE-2016-9534 CRITICAL POC
9.8 Nov 22

tif_write.c in libtiff 4.0.6 has an issue in the error code path of TIFFFlushData1() that didn't reset the tif_rawcc and

CVE-2017-17095 HIGH POC
8.8 Dec 02

tools/pal2rgb.c in pal2rgb in LibTIFF 4.0.9 allows remote attackers to cause a denial of service (TIFFSetupStrips heap-b

CVE-2016-8331 HIGH POC
8.1 Oct 28

An exploitable remote code execution vulnerability exists in the handling of TIFF images in LibTIFF version 4.0.6. Rated

CVE-2017-5225 HIGH POC
8.8 Jan 12

LibTIFF version 4.0.7 is vulnerable to a heap buffer overflow in the tools/tiffcp resulting in DoS or code execution via

CVE-2017-17973 HIGH POC
8.8 Dec 29

In LibTIFF 4.0.8, there is a heap-based use-after-free in the t2p_writeproc function in tiff2pdf.c. Rated high severity

CVE-2017-9935 HIGH POC
8.8 Jun 26

In LibTIFF 4.0.8, there is a heap-based buffer overflow in the t2p_write_pdf function in tools/tiff2pdf.c. Rated high se

CVE-2017-17942 HIGH POC
8.8 Dec 28

In LibTIFF 4.0.9, there is a heap-based buffer over-read in the function PackBitsEncode in tif_packbits.c. Rated high se

CVE-2023-25434 HIGH POC
8.8 Jun 14

libtiff 4.5.0 is vulnerable to Buffer Overflow via extractContigSamplesBytes() at /libtiff/tools/tiffcrop.c:3215. Rated

CVE-2022-3970 HIGH POC
8.8 Nov 13

A vulnerability was found in LibTIFF. Rated high severity (CVSS 8.8), this vulnerability is remotely exploitable, no aut

This site uses cookies essential for authentication and security. No tracking or analytics cookies are used. Privacy Policy