---
id: "CVE-2026-112073"
kind: "vulnerability"
aliases: ["CVE-2026-112073"]
title: "Tencent ncnn: out-of-bounds read in MatMul layer during matrix multiplication"
severity: "high"
cvss: 7.5
epss: null
exploited: false
status: "open"
category: "package"
products: []
ecosystems: []
tags: ["c++", "ncnn", "on-device-ml", "package", "self-hosted"]
not_affected_if: ["trusted-models-only"]
published_at: "2026-10-19T04:17:08+00:00"
first_seen_at: "2026-10-23T21:57:17+00:00"
updated_at: "2026-10-25T03:23:26+00:00"
sources: [{"source": "nvd", "url": "https://nvd.nist.gov/vuln/detail/CVE-2026-112073", "first_seen_at": "2026-10-23T21:57:17+00:00"}]
---

# Tencent ncnn: out-of-bounds read in MatMul layer during matrix multiplication

Tencent's ncnn neural network inference library has an out-of-bounds read in the matmul_transb function of its MatMul layer, reachable through crafted model input. An attacker can read memory beyond the intended buffer, which may leak data from the process.

_Summary, check and fix written by a model from the sources; labelled as such._

## How to check

- Check the ncnn version or commit in use against `44b02dabdcf97499281a4692ebd65bad73dcf8b6`; the sources do not name a fixed release.
- Look for the MatMul layer (src/layer/matmul.cpp) in builds that load untrusted models.

## Fix

- unknown: the sources say the project has not responded to the report and name no patched version or commit.
- Until a fix exists, avoid loading untrusted or externally supplied models with ncnn.

## Timeline

- 2026-10-23T21:57:17+00:00 nvd https://nvd.nist.gov/vuln/detail/CVE-2026-112073

## From the sources

A vulnerability was identified in Tencent ncnn up to 44b02dabdcf97499281a4692ebd65bad73dcf8b6. Affected by this vulnerability is the function matmul_transb of the file src/layer/matmul.cpp of the component MatMul. The manipulation leads to out-of-bounds read. The attack can be initiated remotely. The exploit is publicly available and might be used. The project was informed of the problem early through an issue report but has not responded yet.

---

_Free to read at a human pace. An API with keys and an MCP server are in preparation; early access: hello@infrastack.ai_
