CVE-2026-5186Public exploit

Memory corruption via zero-size realloc double-free

Published Mar 31, 2026 · Updated Mar 31, 2026

Double-free in stb_image.h in Sean Barrett stb 2.30 and earlier allows local users to corrupt heap memory via a crafted multi-frame GIF. The out-of-memory path in stbi__load_gif_main passes a zero-sized layers-by-stride allocation to realloc, then frees the retained out pointer again when realloc returns null. Reaching the fault requires a multi-threaded host application to decode the crafted GIF; the demonstrated result is an AddressSanitizer-detected double-free, while code execution is only the reported upper bound.

CVSS severity4.8
Medium
EPSS probability0.11%
Next 30 days · Sep 16, 2026
Known exploitationUnconfirmed
Based on sourced intelligence
Hinoki checkNot available
Coverage for this vulnerability

See if you're affected

Explore vulnerability checks for your environment with Hinoki.

Book a demo

Summary

What happened

Double-free in stb_image.h in Sean Barrett stb 2.30 and earlier allows local users to corrupt heap memory via a crafted multi-frame GIF. The out-of-memory path in stbi__load_gif_main passes a zero-sized layers-by-stride allocation to realloc, then frees the retained out pointer again when realloc returns null. Reaching the fault requires a multi-threaded host application to decode the crafted GIF; the demonstrated result is an AddressSanitizer-detected double-free, while code execution is only the reported upper bound.

The record

CVE
CVE-2026-5186
Published
Mar 31, 2026
Updated
Mar 31, 2026
Vendor
Sean Barrett
Product
stb
Classifications
CWE-119, CWE-415, T1203
Attack vector
local
Privileges
authenticated

Timeline

How it unfolded

  1. Mar 31, 2026CVE publishedPublication date reported by the CVE source.
  2. Mar 31, 2026Record updatedLatest update available in the CVE record.

Exploitability

Present is not the same as exploitable

Compare your product and version with the public record. A matching version still requires validation against your environment.

Is a vulnerable build present?

Compare these published version ranges with your installed build and any vendor patches.

  1. Affected versionversion=2.0
  2. Affected versionversion=2.1
  3. Affected versionversion=2.10
  4. Affected versionversion=2.11
  5. Affected versionversion=2.12
  6. Affected versionversion=2.13
  7. Affected versionversion=2.14
  8. Affected versionversion=2.15
  9. Affected versionversion=2.16
  10. Affected versionversion=2.17
  11. Affected versionversion=2.18
  12. Affected versionversion=2.19
  13. Affected versionversion=2.2
  14. Affected versionversion=2.20
  15. Affected versionversion=2.21
  16. Affected versionversion=2.22
  17. Affected versionversion=2.23
  18. Affected versionversion=2.24
  19. Affected versionversion=2.25
  20. Affected versionversion=2.26
  21. Affected versionversion=2.27
  22. Affected versionversion=2.28
  23. Affected versionversion=2.29
  24. Affected versionversion=2.3
  25. Affected versionversion=2.30
  26. Affected versionversion=2.4
  27. Affected versionversion=2.5
  28. Affected versionversion=2.6
  29. Affected versionversion=2.7
  30. Affected versionversion=2.8
  31. Affected versionversion=2.9

What conditions does exploitation require?

Attack vectorlocal
Required privilegesauthenticated

What is affected?

Sean Barrett · stbversion=2.0; version=2.1; version=2.10; version=2.11; version=2.12; version=2.13; version=2.14; version=2.15; version=2.16; version=2.17; version=2.18; version=2.19; version=2.2; version=2.20; version=2.21; version=2.22; version=2.23; version=2.24; version=2.25; version=2.26; version=2.27; version=2.28; version=2.29; version=2.3; version=2.30; version=2.4; version=2.5; version=2.6; version=2.7; version=2.8; version=2.9

Published CVSS scores

4.8VulDBCVSS:4.0/AV:L/AC:L/AT:N/PR:L/UI:N/VC:L/VI:L/VA:L/SC:N/SI:N/SA:N
4.3VulDBAV:L/AC:L/Au:S/C:P/I:P/A:P
5.3VulDBCVSS:3.1/AV:L/AC:L/PR:L/UI:N/S:U/C:L/I:L/A:L

CVSS describes severity. EPSS estimates exploitation probability.

Attacks

What attackers are doing with it

Daily unique IPs observed by Shadowserver honeypots for known exploited vulnerabilities (KEVs). Missing observations do not establish an absence of attacks.

Daily unique IPsNo honeypot observations are available for this CVE in the selected window.

No observations available

Sep 10, 2026Sep 16, 2026
Latest reporting daySep 16, 2026
Latest daily unique IPsUnavailable
Prior 30-day averageUnavailable
SourceShadowserver honeypots (KEV)
Vectorlocal
Privilegesauthenticated
Known exploitationUnconfirmed
Public exploitPublished

Weakness, pattern, technique

CWE-119Improper Restriction of Operations within the Bounds of a Memory Buffer
CWE-415Double Free
T1203Exploitation for Client Execution

Public exploit references

Labels summarize the accepted research assessment. They do not indicate a test against your environment.

Technologies

Your stack

See the directory against your own environment.

Your stack

Check the software in your environment

Book a demo to see how Hinoki identifies affected software and validates exploitability in your environment.

Book a demo