9.8
CRITICAL CVSS 3.1
CVE-2026-42249
Remote Code Execution in Ollama via Update Mechanism
Description

Ollama for Windows contains a Remote Code Execution vulnerability in its update mechanism due to improper handling of attacker‑controlled HTTP response headers. When downloading updates, the application constructs local file paths using values derived from HTTP headers without validation. These values are passed directly to filepath.Join, allowing path traversal sequences (../) to be resolved and enabling files to be written outside the intended update staging directory. An attacker who can influence update responses can exploit this flaw to write arbitrary executables to attacker‑chosen locations accessible to the current user, including the Windows Startup directory. This allows execution of arbitrary executables. Critically, when chained with CVE‑2026‑42248 (Missing Signature Verification for Updates), an attacker can deliver malicious payloads that are written to sensitive locations and executed automatically. Because Ollama for Windows performs silent automatic updates and executes staged binaries without user interaction, this results in automatic and persistent code execution without user awareness. Maintainers of this project were notified early about this vulnerability, but didn't respond with the details of vulnerability or vulnerable version range. Versions from 0.12.10 to 0.17.5 were tested and confirmed as vulnerable, other versions were not tested but might also be vulnerable.

INFO

Published Date :

April 29, 2026, 12:16 p.m.

Last Modified :

Nov. 11, 2026, 9:10 p.m.

Remotely Exploit :

Yes !
Affected Products

The following products are affected by CVE-2026-42249 vulnerability. Even if cvefeed.io is aware of the exact versions of the products that are affected, the information is not represented in the table below.

ID Vendor Product Action
1 Microsoft windows
1 Ollama ollama
CVSS Scores
The Common Vulnerability Scoring System is a standardized framework for assessing the severity of vulnerabilities in software and systems. We collect and displays CVSS scores from various sources for each CVE.
Score Version Severity Vector Exploitability Score Impact Score Source
CVSS 134c704f-9b21-4f2e-91b3-4a467353bcc0
CVSS 3.1 CRITICAL [email protected]
CVSS 4.0 HIGH 4bb8329e-dd38-46c1-aafb-9bf32bcb93c6
CVSS 4.0 HIGH [email protected]
Solution
Update Ollama to the latest version to fix path traversal and RCE in the update mechanism.
  • Update Ollama to the latest version.
  • Validate HTTP response headers during updates.
  • Sanitize all user-supplied input.
  • Apply signature verification to updates.
Public PoC/Exploit Available at Github

CVE-2026-42249 has a 2 public PoC/Exploit available at Github. Go to the Public Exploits tab to see the list.

References to Advisories, Solutions, and Tools

Here, you will find a curated list of external links that provide in-depth information, practical solutions, and valuable tools related to CVE-2026-42249.

URL Resource
https://cert.pl/en/posts/2026/04/CVE-2026-42248/ Third Party Advisory
https://ollama.com/ Product
CWE - Common Weakness Enumeration

While CVE identifies specific instances of vulnerabilities, CWE categorizes the common flaws or weaknesses that can lead to vulnerabilities. CVE-2026-42249 is associated with the following CWEs:

Common Attack Pattern Enumeration and Classification (CAPEC)

Common Attack Pattern Enumeration and Classification (CAPEC) stores attack patterns, which are descriptions of the common attributes and approaches employed by adversaries to exploit the CVE-2026-42249 weaknesses.

We scan GitHub repositories to detect new proof-of-concept exploits. Following list is a collection of public exploits and proof-of-concepts, which have been published on GitHub (sorted by the most recently updated).

Full Disclosure: 7 Critical Vulnerabilities in Ollama — SSRF, RCE, CORS, Memory Leaks. 15+ PoCs. 3 CVEs. By k4w_wak

ai-security bug-bounty cors cve disclosure gguf llm-security local-ai ollama ollama-security rce responsible-disclosure security ssrf vulnerability model-hijacking

Python Shell HTML

Updated: 5 months, 1 week ago
1 stars 0 fork 0 watcher
Born at : June 9, 2026, 10:07 p.m. This repo has been linked 5 different CVEs too.

A curated timeline of real AI agent security incidents, breaches, and vulnerabilities (2024-2026). Every entry sourced and dated.

ai-agent-security ai-agents ai-security awesome-list cybersecurity llm-security mcp-security prompt-injection supply-chain-security adversarial-attacks agent-security agentic-ai ai-attacks ai-safety cve incident-response owasp red-team security-research vulnerability

Updated: 4 months ago
37 stars 3 fork 3 watcher
Born at : April 7, 2026, 2:19 p.m. This repo has been linked 113 different CVEs too.

Results are limited to the first 15 repositories due to potential performance issues.

The following list is the news that have been mention CVE-2026-42249 vulnerability anywhere in the article.

  • The Hacker News
Ollama Out-of-Bounds Read Vulnerability Allows Remote Process Memory Leak

Cybersecurity researchers have disclosed a critical security vulnerability in Ollama that, if successfully exploited, could allow a remote, unauthenticated attacker to leak its entire process memory. ... Read more

Published Date: May 10, 2026 (6 months, 1 week ago)
  • cert.pl
Vulnerabilities in Ollama software

Vulnerabilities in Ollama software CVE ID CVE-2026-42248 Publication date 29 April 2026 Vendor Ollama Product Ollama Vulnerable versions From 0.12.10 through 0.17.5 Vulnerability type (CWE) Download o ... Read more

Published Date: Apr 29, 2026 (6 months, 2 weeks ago)

The following table lists the changes that have been made to the CVE-2026-42249 vulnerability over time.

Vulnerability history details can be useful for understanding the evolution of a vulnerability, and for identifying the most recent changes that may impact the vulnerability's severity, exploitability, or other characteristics.

  • CVE Translated by [email protected]

    Nov. 11, 2026

    Action Type Old Value New Value
    Added Translation Title: Ollama, Description: Ollama para Windows contiene una vulnerabilidad de ejecución remota de código en su mecanismo de actualización debido a un manejo inadecuado de los encabezados de respuesta HTTP controlados por el atacante. Al descargar actualizaciones, la aplicación construye rutas de archivo locales utilizando valores derivados de los encabezados HTTP sin validación. Estos valores se pasan directamente a filepath.Join, permitiendo que las secuencias de salto de ruta (.. / ) se resuelvan y permitiendo que los archivos se escriban fuera del directorio de preparación de actualizaciones previsto. Un atacante que puede influir en las respuestas de actualización puede explotar esta falla para escribir ejecutables arbitrarios en ubicaciones elegidas por el atacante accesibles para el usuario actual, incluyendo el directorio de Inicio de Windows. Esto permite la ejecución de ejecutables arbitrarios. Críticamente, cuando se encadena con CVE?2026?42248 (Verificación de Firma Faltante para Actualizaciones), un atacante puede entregar cargas útiles maliciosas que se escriben en ubicaciones sensibles y se ejecutan automáticamente. Debido a que Ollama para Windows realiza actualizaciones automáticas silenciosas y ejecuta binarios preparados sin interacción del usuario, esto resulta en una ejecución de código automática y persistente sin el conocimiento del usuario. Los mantenedores de este proyecto fueron notificados con antelación sobre esta vulnerabilidad, pero no respondieron con los detalles de la vulnerabilidad o el rango de versiones vulnerables. Las versiones de 0.12.10 a 0.17.5 fueron probadas y confirmadas como vulnerables, otras versiones no fueron probadas pero también podrían ser vulnerables.
  • CVE Modified by [email protected]

    Jun. 17, 2026

    Action Type Old Value New Value
    Added Affected [{'repo': 'https://github.com/ollama/ollama', 'vendor': 'Ollama', 'product': 'Ollama', 'versions': [{'status': 'affected', 'version': '0.12.10', 'versionType': 'semver', 'lessThanOrEqual': '0.17.5'}], 'platforms': ['Windows'], 'defaultStatus': 'unknown'}]
  • CVE Modified by 134c704f-9b21-4f2e-91b3-4a467353bcc0

    Jun. 17, 2026

    Action Type Old Value New Value
    Added SSVC {'id': 'CVE-2026-42249', 'role': 'CISA Coordinator', 'options': [{'exploitation': 'none'}, {'automatable': 'no'}, {'technicalImpact': 'total'}], 'version': '2.0.3', 'timestamp': '2026-04-29T13:20:16.814725Z'}
  • Initial Analysis by [email protected]

    May. 18, 2026

    Action Type Old Value New Value
    Added CVSS V3.1 AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:H
    Added CPE Configuration AND OR *cpe:2.3:a:ollama:ollama:*:*:*:*:*:*:*:* versions from (including) 0.12.10 up to (including) 0.17.5 OR cpe:2.3:o:microsoft:windows:-:*:*:*:*:*:*:*
    Added Reference Type CERT.PL: https://cert.pl/en/posts/2026/04/CVE-2026-42248/ Types: Third Party Advisory
    Added Reference Type CERT.PL: https://ollama.com/ Types: Product
  • New CVE Received by [email protected]

    Apr. 29, 2026

    Action Type Old Value New Value
    Added Description Ollama for Windows contains a Remote Code Execution vulnerability in its update mechanism due to improper handling of attacker‑controlled HTTP response headers. When downloading updates, the application constructs local file paths using values derived from HTTP headers without validation. These values are passed directly to filepath.Join, allowing path traversal sequences (../) to be resolved and enabling files to be written outside the intended update staging directory. An attacker who can influence update responses can exploit this flaw to write arbitrary executables to attacker‑chosen locations accessible to the current user, including the Windows Startup directory. This allows execution of arbitrary executables. Critically, when chained with CVE‑2026‑42248 (Missing Signature Verification for Updates), an attacker can deliver malicious payloads that are written to sensitive locations and executed automatically. Because Ollama for Windows performs silent automatic updates and executes staged binaries without user interaction, this results in automatic and persistent code execution without user awareness. Maintainers of this project were notified early about this vulnerability, but didn't respond with the details of vulnerability or vulnerable version range. Versions from 0.12.10 to 0.17.5 were tested and confirmed as vulnerable, other versions were not tested but might also be vulnerable.
    Added CVSS V4.0 AV:A/AC:H/AT:P/PR:N/UI:N/VC:H/VI:H/VA:H/SC:L/SI:L/SA:L/E:X/CR:X/IR:X/AR:X/MAV:X/MAC:X/MAT:X/MPR:X/MUI:X/MVC:X/MVI:X/MVA:X/MSC:X/MSI:X/MSA:X/S:X/AU:X/R:X/V:X/RE:X/U:X
    Added CWE CWE-22
    Added CWE CWE-494
    Added Reference https://cert.pl/en/posts/2026/04/CVE-2026-42248/
    Added Reference https://ollama.com/
EPSS is a daily estimate of the probability of exploitation activity being observed over the next 30 days. Following chart shows the EPSS score history of the vulnerability.