GitLab disclosed a critical vulnerability in its AI Gateway service on October 2, 2026. Tracked as CVE-2026-90970, this flaw carries a CVSS score of 9.9 and could allow authenticated users to execute arbitrary commands on self-hosted gateway instances. Consequently, organizations running their own AI Gateway must patch immediately. This article breaks down the vulnerability, its technical root cause, and the actions defenders should take now.
What Happened: Critical GitLab AI Gateway RCE Vulnerability Disclosed
On October 2, 2026, GitLab published a security advisory for CVE-2026-90970. The flaw affects the AI Gateway, a service that connects GitLab instances to AI models powering GitLab Duo features. Moreover, the vulnerability is rooted in an improper neutralization weakness in the prompt template of a custom flow.
An authenticated user with Duo Agent Platform access could escape the prompt template sandbox via a specially crafted flow configuration. This escape could lead to arbitrary command execution on the AI Gateway host. However, only self-hosted AI Gateway deployments are affected. Customers using GitLab-hosted gateways, including GitLab.com and GitLab Dedicated, do not need to act because GitLab has already remediated those instances.
GitLab released patched gateway versions 19.2.4, 19.3.2, and 19.4.1. The company also conducted targeted outreach to self-hosted gateway customers before public disclosure. Furthermore, the U.S. Cybersecurity and Infrastructure Security Agency (CISA) assessed exploitation as “none” at the time of disclosure. Still, the severity and the privileged position of the gateway make this a high-priority patch.
Technical Details of the CVE-2026-90970 Vulnerability
The vulnerability stems from a template engine weakness classified under CWE-1336. In the AI Gateway, custom flows allow users to build multi-step AI-powered workflows on the Duo Agent Platform. Furthermore, the prompt template for a custom flow did not properly neutralize user-supplied input.
An attacker with Duo Agent Platform access could craft a malicious flow configuration that breaks out of the template sandbox. Therefore, the injected payload could execute arbitrary commands on the underlying gateway host. The advisory does not disclose the exact escape technique or specific user roles beyond Duo Agent Platform access.
The AI Gateway holds sensitive credentials, including JSON Web Token (JWT) signing keys. It also connects to the GitLab instance and to external AI model providers. Consequently, compromise of the gateway could expose tokens, pivot to the GitLab instance, or leak AI traffic.
Affected Versions
- AI Gateway 18.1.6 or later, before 19.2.4
- AI Gateway 19.3, before 19.3.2
- AI Gateway 19.4, before 19.4.1
Notably, no fixed version is listed below 19.2.4. That means every gateway release from 18.1.6 through the 19.1 line is vulnerable. In addition, GitLab’s maintenance policy lists 19.4, 19.3, and 19.2 as the supported release lines receiving security fixes.
Business and Operational Impact
GitLab serves more than 30 million registered users. Over 50 percent of Fortune 100 companies rely on its DevSecOps platform, including Nvidia, Lockheed Martin, T-Mobile, Goldman Sachs, Airbus, and UBS. Therefore, a significant portion of the enterprise development ecosystem depends on GitLab services.
For organizations running a self-hosted AI Gateway, the impact of this vulnerability is severe:
- Arbitrary command execution on the gateway host could lead to full system compromise.
- JWT signing key exposure could allow attackers to forge tokens and impersonate users or services.
- Lateral movement from the gateway to connected GitLab instances and AI providers is possible.
- Data exfiltration of AI prompts and responses, which may contain sensitive code or business logic.
- Service disruption if attackers degrade or shut down the gateway.
Moreover, this is the second critical AI Gateway flaw disclosed in 2026. In February, GitLab patched CVE-2026-1868, also rated 9.9, which was a similar template engine weakness. Both flaws belong to the same class of vulnerability, suggesting the attack surface deserves ongoing scrutiny.
Mitigation and Recommendations
Defenders should treat this as an emergency patch for self-hosted AI Gateway deployments. GitLab strongly recommends updating immediately. There is no known workaround for instances that cannot be patched yet.
Immediate Actions for Defenders
- Identify self-hosted gateways. Inventory GitLab Self-Managed environments that use GitLab Duo Self-Hosted and run their own AI Gateway.
- Update to a fixed version. Upgrade Docker or Helm deployments to gateway version 19.2.4, 19.3.2, or 19.4.1.
- Review flow configurations. Audit custom flows created by Duo Agent Platform users for suspicious or unexpected configurations.
- Rotate credentials. After patching, rotate JWT signing keys and review connected service accounts.
- Monitor gateway logs. Look for anomalous command execution, unexpected network connections, or unauthorized access patterns.
Additional Guidance
For Docker deployments, stop and remove the running container, then pull and run the new image tag, for example self-hosted-v19.4.1-ee. For Helm deployments, set the new tag in the chart’s image setting and redeploy.
Because the advisory does not provide a way to detect prior exploitation, assume breach posture on unpatched gateways. Therefore, conduct forensic triage on affected hosts if patching was delayed.
Bottom line: CVE-2026-90970 is a near-maximum severity flaw in GitLab’s AI Gateway that grants command execution to authenticated users. Patch self-hosted gateways to 19.2.4, 19.3.2, or 19.4.1 immediately, rotate credentials, and audit custom flow configurations.
Incident Summary
| CVE ID / Incident: | CVE-2026-90970 |
| Affected Systems: | GitLab Self-Hosted AI Gateway versions 18.1.6+ through 19.1.x, 19.3 before 19.3.2, 19.4 before 19.4.1 |
| Disclosure Date: | October 2, 2026 |
| Patch Status: | Available in versions 19.2.4, 19.3.2, and 19.4.1 |
| CVSS Score: | 9.9 (Critical) |
| CISA Assessment: | Exploitation “none” at time of disclosure |
References
- GitLab, “Patch Release: GitLab AI Gateway 19.4.1 Released,” October 2, 2026, https://docs.gitlab.com/releases/patches/other-patches/patch-release-gitlab-ai-gateway-19-4-1-released/, accessed October 2, 2026.
- Sergiu Gatlan, “GitLab Warns of Critical RCE Vulnerability in AI Gateway Service,” BleepingComputer, October 2, 2026, https://www.bleepingcomputer.com/news/security/gitlab-warns-of-critical-rce-vulnerability-in-ai-gateway-service/, accessed October 2, 2026.
- The Hacker News, “GitLab Patches Critical 9.9 AI Gateway Flaw Allowing Command Execution on Self-Hosted Servers,” October 2, 2026, https://thehackernews.com/2026/10/gitlab-patches-critical-self-hosted-ai.html, accessed October 2, 2026.
- U.S. Cybersecurity and Infrastructure Security Agency (CISA), Known Exploited Vulnerabilities Catalog entry for CVE-2026-90970, https://www.cisa.gov/known-exploited-vulnerabilities-catalog, accessed October 2, 2026.
- National Vulnerability Database (NVD), CVE-2026-90970 Detail, https://nvd.nist.gov/vuln/detail/CVE-2026-90970, accessed October 2, 2026.