- Security researchers at Wiz discovered a vulnerability in Azure Cosmos DB that could have allowed an attacker to gain full read and write access to customer databases across tenants.
- Dubbed CosmosEscape, the exploit chain used a crafted Gremlin query to achieve code execution on a multi-tenant gateway, exposing a platform-wide signing key and account directory.
- Microsoft blocked the initial entry point within 48 hours of the November 2025 report and completed the fix across all regions by July 2026, finding no evidence of unauthorized customer access.
A now-patched vulnerability in Azure Cosmos DB could have let an attacker escape the service’s Gremlin query sandbox and obtain full read and write access to databases across customer tenants, according to Wiz. The researchers, who codenamed the chain CosmosEscape, said the exploit began with a crafted query against a Gremlin database the attacker controlled.
Microsoft blocked the vulnerable Gremlin entry point within 48 hours of the November 2025 report, and Wiz said the company completed the fix across all regions in July 2026. A Microsoft spokesperson told The Hacker News, “We have fully addressed the issue and found no evidence of customer impact based on our investigations.”
According to Wiz‘s technical write-up, Cosmos DB’s custom Gremlin engine translates queries into .NET code and runs them inside a restricted environment. The researchers said the restrictions failed to account for .NET reflection, allowing them to build file-read and file-write primitives before achieving arbitrary code execution.
The code execution landed on a component called the DB Gateway, which could retrieve the primary key for any requested Cosmos DB account. Consequently, credentials available to the gateway provided access to a signing key that could retrieve the primary key for any account across tenants and multiple APIs.
The same secret opened a regional database called the Config Store, which contained account names, subscription identifiers, and network settings. Wiz said the chain could also reach private and network-isolated accounts because the compromised gateway enforced those network boundaries from inside the service.
✅ Follow BITNEWSBOT on Telegram, Facebook, LinkedIn, X.com, and Google News for instant updates.
