CVE-2026-50144: Tencent ncnn heap out-of-bounds write in ParamDict::load_param

CVE-2026-50144 · Severity: high · CVSS 7.1 · Published 2026-07-15

ncnn is a high-performance tool used to run artificial intelligence models on mobile devices. A security flaw allows a malicious actor to create a specially crafted model file that, when opened by an application using ncnn, can corrupt the device's memory. This could lead to the application crashing or potentially allow the attacker to gain unauthorized control over the application.

Technologies: Tencent Ncnn. Vendors: Tencent.

Quick answers

Is CVE-2026-50144 exploited in the wild?
No. Junglewise Threat Intelligence has no report of CVE-2026-50144 being exploited in the wild.
How severe is CVE-2026-50144?
High severity, with a CVSS score of 7.1, published 15 July 2026.
Which products and versions are affected?
Tencent Ncnn <= e54f7b1f88434e1d844ea0551b880a1cfb079ce1.
Is there a fix for CVE-2026-50144?
A patch was published on 2026-07-15: Fix identified in commit 5a0288f255daa6c3294f77109f67718e434ec020 Junglewise finds every place you run it, drafts the upgrade and applies it once you approve.
How is CVE-2026-50144 attacked?
It is attacked with local access, in a software library.
Am I affected by CVE-2026-50144?
Check whether you run Tencent Ncnn at an affected version. Junglewise does that check for you around the clock: connect your code, cloud and domains, and it matches new vulnerabilities like this one against what you actually run and tells you when one reaches you.

Technical details

An out-of-bounds (OOB) heap write exists in ncnn::ParamDict::load_param() and load_param_bin(). The vulnerability stems from improper input validation where a parsed parameter 'id' (a signed integer) is only checked against an upper bound (id >= NCNN_MAX_PARAM_COUNT). An attacker can provide a negative 'id' in the range [-23299, -1], which bypasses the check and is used as an index for the fixed-size 'params' array. This results in a relative OOB write before the heap allocation. The attacker controls both the offset (via the negative ID) and the 4-byte value written (integer or float), making this a reliable primitive for memory corruption or potential code execution during model loading. The issue is fixed in commit 5a0288f255daa6c3294f77109f67718e434ec020.

Affected products

  • Tencent ncnn <= e54f7b1f88434e1d844ea0551b880a1cfb079ce1

Timeline

  • 2026-05-28: advisory: GitHub Security Advisory published
  • 2026-07-15: disclosed: NVD publication date
  • 2026-07-15: patched: Fix identified in commit 5a0288f255daa6c3294f77109f67718e434ec020

References

This page as Markdown. Free to reuse under CC BY 4.0 with a link back.