Use of Out-of-range Pointer Offset in the Elasticsearch Machine Learning Native Inference Process
The native inference process that Elasticsearch uses to evaluate uploaded machine learning models accepts a model operation that computes a memory address from an offset supplied inside the model, without validating that the offset stays within the bounds of the underlying storage. A user with the privileges required to upload and deploy a trained model can craft a model that reads and writes memory outside the intended allocation. The result is heap corruption that crashes the inference process, and, with sufficient control over the heap layout, could allow arbitrary code execution in the context of that process.
Affected Versions:
- All versions from 8.19.0 up to and including 8.19.19
- All versions from 9.4.0 up to and including 9.4.4
- Version 9.5.0
Affected Configurations:
- Elasticsearch deployments running an affected version with machine learning enabled and at least one machine learning node available
Solutions and Mitigations:
The issue is resolved in Elasticsearch versions 8.19.20, 9.4.5 and 9.5.1.
For Users that Cannot Upgrade:
- Grant the machine learning privileges required to upload and deploy trained models only to trusted administrators, and do not accept trained models from untrusted sources.
- Where machine learning is not required, disable it by setting xpack.ml.enabled to false on all nodes. Note that this removes all machine learning functionality, including anomaly detection, data frame analytics, and inference.
Indicators of Compromise (IOC)
No specific indicators of compromise have been identified for this vulnerability.
Elastic Cloud Serverless
Due to our continuous deployment and patching model, the vulnerability described in this security advisory was remediated in our Elastic Cloud Serverless offering before the public disclosure.
Severity: CVSSv3.1: High ( 8.8 ) - CVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:U/C:H/I:H/A:H
CVE ID: CVE-2026-72642
Problem Type: CWE-823 - Use of Out-of-range Pointer Offset