# CVE-2026-85788: AWS Labs MySQL MCP Server read-only enforcement bypass via SQL comments

Source: https://junglewise.ai/threats/cve-2026-85788-aws-labs-mysql-mcp-server-read-only-enforcement-bypass-via-sql  
Publisher: Junglewise Threat Intelligence, https://junglewise.ai/threats  
Published: 2026-09-09. Updated: 2026-09-25  
License: CC BY 4.0 with a link back

CVE-2026-85788 · Severity: high · CVSS 5.5 · Published 2026-09-09

AWS Labs mysql-mcp-server is an open-source tool that allows applications to interact with MySQL databases through the Model Context Protocol. The tool includes a read-only enforcement feature designed to prevent unauthorized write operations. This vulnerability allows an attacker to bypass the read-only safeguard using SQL inline comments, potentially executing write or dangerous operations that should have been blocked.

Technologies: [Amazon AWS](https://junglewise.ai/threats/technologies/aws). Vendors: [Amazon](https://junglewise.ai/threats/vendors/amazon).

## Quick answers

**Is CVE-2026-85788 exploited in the wild?** No. Junglewise Threat Intelligence has no report of CVE-2026-85788 being exploited in the wild.

**How severe is CVE-2026-85788?** High severity, with a CVSS score of 5.5, published 9 September 2026.

**Which products and versions are affected?** AWS Labs mysql-mcp-server <=1.0.21.

**Is there a fix for CVE-2026-85788?** No fixed version is recorded yet. Check the vendor's advisory in the references below. If you run it, Junglewise drafts a mitigation that fits your setup and applies it once you approve, with senior security engineers behind it.

**How is CVE-2026-85788 attacked?** It is attacked over the network, in a software library.

**Am I affected by CVE-2026-85788?** Check whether you run Amazon AWS. Junglewise does that check for you around the clock: connect your code, cloud and domains, and it matches new vulnerabilities like this one against what you actually run and tells you when one reaches you.

## Technical details

The vulnerability exists in the read-only enforcement logic of AWS Labs mysql-mcp-server, where SQL inline comments can be used to bypass validation checks intended to prevent write operations in read-only mode. The root cause is insufficient parsing and normalization of SQL statements before the read-only check is applied. The attack vector is network-based, requiring network access to the MCP server; no authentication bypass is required if the attacker already has access to invoke the server. An attacker can craft malicious SQL statements with inline comments (e.g., /* ... */) to trigger execution of forbidden operations such as INSERT, UPDATE, DELETE, or DROP. AWS emphasizes that this is a best-effort safeguard; proper mitigation requires correctly scoped database user permissions. A patch is available in versions after 1.0.21.

## Affected products

- AWS Labs mysql-mcp-server <=1.0.21

## Timeline

- 2026-09-09: disclosed

## References

- [https://aws.amazon.com/security/security-bulletins/rss/2026-103-aws/](https://aws.amazon.com/security/security-bulletins/rss/2026-103-aws/)

## Related threats

- [An untrusted search path issue in Aurora PostgreSQL dialect detection in the AWS Advanced Go Wrapper from release 2026-04-06 (awssql/v2.0.0)](https://junglewise.ai/threats/cve-2026-126793-privilege-escalation-in-aurora-postgresql-dialect-detection-in)
- [AWS SDK for pandas EMR unverified bucket ownership](https://junglewise.ai/threats/cve-2026-127119-unverified-ownership-of-the-default-emr-cluster-log-location-in)
- [Amazon mcp-gateway-registry server-side request forgery in registration API](https://junglewise.ai/threats/cve-2026-125926-server-side-request-forgery-in-the-server-registration-and)
- [Amazon mcp-gateway-registry authorization bypass in management API](https://junglewise.ai/threats/cve-2026-100307-missing-authorization-on-the-external-management-api-in-mcp)
- [AWS Kiro CLI incorrect default permissions on session files](https://junglewise.ai/threats/cve-2026-124848-incorrect-default-permissions-on-session-transcripts-and-prompt)
