ContextForge: DNS TOCTOU race condition causes SSRF protection bypass (`/admin/gateways/test`)
Key facts
- Attack vector
- Network
- Privileges required
- High
- User interaction
- None
- Attack complexity
- High
- Impact type
- —
- Confidentiality · integrity · availability
- High · Low · None
- Fix status
- Fixed
Attack profile from CVSS 3.1 · CNA. Fix status from CNA and GitHub.
Summary
ContextForge is an AI gateway, registry, and proxy that provides centralized discovery, guardrails, and management for MCP, A2A, and REST or gRPC APIs. Prior to 1.0.3, the /admin/gateways/test call site in mcpgateway/admin.py calls validate_gateway_test_url() in mcpgateway/common/validators.py to resolve and reject private, loopback, link-local, and cloud-metadata addresses, but ResilientHttpClient later resolves the original hostname again without binding the validated address. When MCPGATEWAY_ADMIN_API_ENABLED is enabled, an attacker with a database-backed role containing explicit gateways.read permission can use DNS rebinding to return a public address during validation and a private or metadata address during connection, bypassing ssrf_blocked_networks and ssrf_dns_fail_closed because those controls apply only to the validation-time result. The endpoint's allow_admin_bypass=False setting means a bootstrap-only virtual platform-admin identity without a database role is not sufficient. Successful exploitation can reach internal services and cloud metadata, expose cloud credentials, access internal APIs, or probe internal network ports. This issue is fixed in version 1.0.3.
Why it matters now
SSVC decision points
CISA ADP · SSVC 2.0.3
- Exploitation
- Poc
- Automatable
- No
- Technical impact
- Partial
The decision (Track, Attend, Act) also depends on your mission and well-being impact; see CISA's SSVC guide.
Affected products
Remediation
- Fix · CNA mcp-context-forge (IBM) Fixed in 1.0.3
- Fix · CNA mcp-contextforge-gateway (IBM) Fixed in 1.0.3
- Fix · GHSA-9hgc-g3w5-67cm mcp-contextforge-gateway (PyPI) Fixed in 1.0.3 Advisory →
Timeline
- 2026-10-02 Threatist record created from CVE-2026-53708
- 2026-10-03 Alias added: GHSA-9hgc-g3w5-67cm
References
More IBM vulnerabilities
- TI-2026-08085 Unauthenticated Remote Code Execution via Auto-Login Bypass and Code Validation KEVCVSS 3.1CRITICAL 9.8
- TI-2022-23774 IBM Aspera Faspex code execution KEVCVSS 3.1CRITICAL 9.8
- TI-2020-03794 Improper authentication in IBM Data Risk Manager KEVCVSS 3.1CRITICAL 9.8
- TI-2019-03441 Code injection in IBM Planning Analytics KEVCVSS 3.1CRITICAL 9.8
- TI-2017-03639 Improper handling of exceptional conditions in Apache Struts KEVCVSS 3.1CRITICAL 9.8
- TI-2015-06198 Serialized-object interfaces in certain IBM analytics, business solutions, cognitive, IT… KEVCVSS 3.1CRITICAL 9.8
Sources
- CVE-2026-53708 · CVE Program
- CVE-2026-53708 · NVD
- FIRST EPSS
- GHSA-9hgc-g3w5-67cm · GitHub Advisory Database · CC BY 4.0
This product uses the NVD API but is not endorsed or certified by the NVD. Sources and licences