{"id":"CVE-2026-118264","aliases":["CVE-2026-118264","GHSA-cxf3-9h37-7rr8","GO-2026-6839"],"related":[],"kind":"vulnerability","state":"published","title":"Echo: Rejected WebSocket upgrades can bypass Echo route-level access controls","summary":"Echo is a Go web framework. From 4.0.0 until 4.16.1 and 5.4.1, Echo's Proxy middleware selects a raw tunnel from a client WebSocket upgrade request before verifying that the configured upstream accepted the upgrade. If the upstream rejects the upgrade with an ordinary keep-alive response, later HTTP requests on the connection are sent directly to that upstream without passing through Echo's router or route-specific middleware. This can bypass authentication or authorization enforced only by Echo routes, but requires an accessible proxy route, a cooperating rejected-upgrade response, and a target without independent upstream authorization. This issue is fixed in 4.16.1 and 5.4.1.","summarySource":"cvelist","descriptions":[{"lang":"en","text":"Echo is a Go web framework. From 4.0.0 until 4.16.1 and 5.4.1, Echo's Proxy middleware selects a raw tunnel from a client WebSocket upgrade request before verifying that the configured upstream accepted the upgrade. If the upstream rejects the upgrade with an ordinary keep-alive response, later HTTP requests on the connection are sent directly to that upstream without passing through Echo's router or route-specific middleware. This can bypass authentication or authorization enforced only by Echo routes, but requires an accessible proxy route, a cooperating rejected-upgrade response, and a target without independent upstream authorization. This issue is fixed in 4.16.1 and 5.4.1.","source":"cvelist"},{"lang":"en","text":"## Impact\n\nEcho's Proxy middleware selected a raw tunnel when the client requested a WebSocket upgrade, before validating whether the configured upstream accepted it. If the upstream returned an ordinary HTTP response and kept the connection alive, subsequent HTTP requests on that connection were forwarded directly to the same upstream without passing through Echo's router or route-specific middleware.\n\nThis can bypass authentication or authorization enforced only at Echo's routes. Exploitation requires an accessible proxy route, an upstream that rejects the upgrade without closing the connection, and a target resource on that upstream without independent authorization. The issue does not provide arbitrary-host proxying or bypass the upstream's own authentication.\n\n## Affected versions and patch\n\nThe raw proxy implementation is present throughout the v4 and v5 release lines up to v4.16.0 and v5.4.0. Runtime reproductions confirmed v4.15.0, v4.16.0, v5.0.0 and v5.4.0; source history also shows the missing upgrade-response validation in v4.0.0.\n\nUpgrade to [v4.16.1](https://github.com/labstack/echo/releases/tag/v4.16.1) or [v5.4.1](https://github.com/labstack/echo/releases/tag/v5.4.1). The patch routes WebSocket upgrades through Go's HTTP reverse proxy and enters a tunnel only after a valid upstream upgrade response. Rejected upgrades remain ordinary HTTP requests.\n\nFix commits: [v4](https://github.com/labstack/echo/commit/3fb0ba7e17645bb65611e2a08875d0a2f65c421f), [v5](https://github.com/labstack/echo/commit/1855061e572ae9dab727c811d8382f266bfbaaec).\n\n## Workarounds\n\nReject WebSocket upgrade requests before they reach affected Echo proxy routes, or enforce authorization independently at every upstream resource. Merely returning a non-101 response from the upstream does not prevent the vulnerable raw tunnel.\n\n## Credits\n\nReported by @Duodum.","format":"markdown","source":"ghsa"},{"lang":"en","text":"Echo: Rejected WebSocket upgrades can bypass Echo route-level access controls in github.com/labstack/echo","format":"markdown","source":"go"},{"lang":"es","text":"Echo es un framework web de Go. Desde la versión 4.0.0 hasta la 4.16.1 y la 5.4.1, el middleware Proxy de Echo selecciona un túnel sin procesar de una solicitud de actualización de WebSocket del cliente antes de verificar que el upstream configurado aceptó la actualización. Si el upstream rechaza la actualización con una respuesta keep-alive ordinaria, las solicitudes HTTP posteriores en la conexión se envían directamente a ese upstream sin pasar por el router de Echo o el middleware específico de la ruta. Esto puede eludir la autenticación o autorización impuestas únicamente por las rutas de Echo, pero requiere una ruta de proxy accesible, una respuesta de actualización rechazada cooperativa y un objetivo sin autorización upstream independiente. Este problema se corrige en las versiones 4.16.1 y 5.4.1.","source":"nvd"}],"published":"2026-10-23T20:49:37.000Z","modified":"2026-11-05T23:26:10.984Z","severity":{"scorer":"GitHub_M","scheme":"CVSS:4.0","vector":"CVSS:4.0/AV:N/AC:L/AT:P/PR:N/UI:N/VC:H/VI:H/VA:N/SC:N/SI:N/SA:N","score":9.1,"rating":"CRITICAL"},"severities":[{"scorer":"GitHub_M","scheme":"CVSS:4.0","vector":"CVSS:4.0/AV:N/AC:L/AT:P/PR:N/UI:N/VC:H/VI:H/VA:N/SC:N/SI:N/SA:N","score":9.1,"rating":"CRITICAL"},{"scorer":"GitHub","scheme":"CVSS:4.0","vector":"CVSS:4.0/AV:N/AC:L/AT:P/PR:N/UI:N/VC:H/VI:H/VA:N/SC:N/SI:N/SA:N","rating":"CRITICAL"}],"cwes":["CWE-444","CWE-863"],"affected":[{"ranges":[{"version":">= 4.0.0, < 4.16.1","status":"affected"},{"version":">= 5.0.0, < 5.4.1","status":"affected"}],"vendor":"labstack","product":"echo","source":"cvelist"},{"ranges":[{"type":"semver","introduced":"4.0.0","status":"affected","fixed":"4.16.1"}],"ecosystem":"Go","package":"github.com/labstack/echo/v4","purl":"pkg:golang/github.com/labstack/echo/v4","source":"ghsa"},{"ranges":[{"type":"semver","introduced":"5.0.0","status":"affected","fixed":"5.4.1"}],"ecosystem":"Go","package":"github.com/labstack/echo/v5","purl":"pkg:golang/github.com/labstack/echo/v5","source":"ghsa"},{"ranges":[{"type":"semver","introduced":"4.0.0","status":"affected","fixed":"4.16.1"}],"ecosystem":"Go","package":"github.com/labstack/echo/v4","purl":"pkg:golang/github.com/labstack/echo/v4","source":"go"},{"ranges":[{"type":"semver","introduced":"5.0.0","status":"affected","fixed":"5.4.1"}],"ecosystem":"Go","package":"github.com/labstack/echo/v5","purl":"pkg:golang/github.com/labstack/echo/v5","source":"go"}],"references":[{"url":"https://github.com/labstack/echo/security/advisories/GHSA-cxf3-9h37-7rr8","tags":["advisory","web","x-refsource-confirm"],"sources":["cvelist","ghsa","go","nvd"]},{"url":"https://github.com/labstack/echo/commit/1855061e572ae9dab727c811d8382f266bfbaaec","tags":["fix","web","x-refsource-misc"],"sources":["cvelist","ghsa","go","nvd"]},{"url":"https://github.com/labstack/echo/commit/3fb0ba7e17645bb65611e2a08875d0a2f65c421f","tags":["fix","web","x-refsource-misc"],"sources":["cvelist","ghsa","go","nvd"]},{"url":"https://github.com/labstack/echo/releases/tag/v4.16.1","tags":["web","x-refsource-misc"],"sources":["cvelist","ghsa","go","nvd"]},{"url":"https://github.com/labstack/echo/releases/tag/v5.4.1","tags":["web","x-refsource-misc"],"sources":["cvelist","ghsa","go","nvd"]},{"url":"https://github.com/labstack/echo","tags":["package"],"sources":["ghsa"]}],"credits":[],"assigner":"GitHub_M","ssvc":{"scorer":"CISA-ADP","exploitation":"none","automatable":"yes","technicalImpact":"total","date":"2026-10-30T19:20:57.948Z"},"sources":[{"source":"cvelist","name":"CVE List","id":"CVE-2026-118264","url":"https://www.cve.org/CVERecord?id=CVE-2026-118264","licence":"CVE Terms of Use","modified":"2026-10-30T19:21:07.156Z"},{"source":"ghsa","name":"GitHub Advisory Database","id":"GHSA-cxf3-9h37-7rr8","url":"https://github.com/advisories/GHSA-cxf3-9h37-7rr8","licence":"CC-BY-4.0","modified":"2026-11-05T23:26:10.984Z"},{"source":"go","name":"Go Vulnerability Database","id":"GO-2026-6839","url":"https://pkg.go.dev/vuln/GO-2026-6839","licence":"CC-BY-4.0","modified":"2026-11-05T23:26:10.984Z"},{"source":"nvd","name":"NVD","id":"CVE-2026-118264","url":"https://nvd.nist.gov/vuln/detail/CVE-2026-118264","licence":"Public domain","modified":"2026-11-04T23:10:00.223Z"}],"updatedAt":"2026-11-25T22:59:47.670Z","epss":{"score":0.00519,"percentile":0.4561,"date":"2026-12-01T12:00:22.000Z"}}