{"id":"CVE-2026-118658","published":"2026-10-28T20:17:11Z","modified":"2026-11-02T20:44:22Z","title":"Echo: Arbitrary Scheme Injection in WWWRedirect/NonWWWRedirect Middlewares via X-Forwarded-Proto","vendor":"labstack","product":"echo","tier":"tail","description":{"text":"Echo is a Go web framework. Prior to 4.15.2 and 5.1.1, Context.Scheme returns values from X-Forwarded-Proto, X-Forwarded-Protocol, or X-Url-Scheme without validating that they are supported web schemes. WWWRedirect and NonWWWRedirect use that value to construct a Location header, so an attacker controlling a forwarded scheme header can cause a redirect to use an arbitrary URI scheme. Exploitation requires an affected redirect middleware and user interaction with the response; the HTTPS-specific redirect variants hardcode HTTPS and are unaffected. This issue is fixed in 4.15.2 and 5.1.1.","provenance":"source","from":"CVE.org"},"cvss":{"score":4.7,"severity":"MEDIUM","version":"3.1","vector":"CVSS:3.1/AV:N/AC:H/PR:N/UI:R/S:C/C:L/I:L/A:N","provenance":"source","from":"CVE.org CNA"},"epss":{"score":0.00269,"percentile":0.19033,"provenance":"source"},"cwes":[{"id":"CWE-601","name":"URL Redirection to Untrusted Site"}],"references":[{"url":"https://github.com/labstack/echo/security/advisories/GHSA-23wf-92cp-8pcj","tags":["x_refsource_CONFIRM"]},{"url":"https://github.com/labstack/echo/commit/ca4f38a474302aabee93c66bdd0052359882e181","tags":["x_refsource_MISC"]},{"url":"https://github.com/labstack/echo/commit/d1d8ad3f99dd9b80542cd0c357d56a8916c515df","tags":["x_refsource_MISC"]},{"url":"https://github.com/labstack/echo/releases/tag/v4.15.2","tags":["x_refsource_MISC"]},{"url":"https://github.com/labstack/echo/releases/tag/v5.1.1","tags":["x_refsource_MISC"]}],"priority":{"score":7.1,"factors":[{"name":"EPSS percentile","points":3.81},{"name":"CVSS severity","points":3.29}]},"vendorSlug":"labstack","affectedVersions":[{"vendor":"labstack","product":"echo","versions":[">= 5.0.0, < 5.1.1","< 4.15.2"]}],"ssvc":{"exploitation":"poc","automatable":"no","technicalImpact":"partial","timestamp":"2026-11-02T20:43:55.876009Z","from":"CISA ADP","provenance":"source"},"affected":[{"ecosystem":"Go","package":"github.com/labstack/echo/v5","vulnerableRanges":["<5.1.1"],"patched":["5.1.1"],"from":["GHSA-23wf-92cp-8pcj","GO-2026-6878"],"provenance":"source"},{"ecosystem":"Go","package":"github.com/labstack/echo/v4","vulnerableRanges":["<4.15.2"],"patched":["4.15.2"],"from":["GHSA-23wf-92cp-8pcj","GO-2026-6878"],"provenance":"source"}],"euvd":{"id":"EUVD-2026-112465","exploited":false,"provenance":"source"},"lineage":{"packageHistory":[{"cve":"CVE-2026-25766","published":"2026-02-19","fixed":"5.0.3","kev":false},{"cve":"CVE-2026-118653","published":"2026-10-28","fixed":"5.1.0","kev":false,"link":{"from":"CVE-2026-118653","to":"CVE-2026-118658","relation":"successor","confidence":"high","kind":"sequence","orderedBy":"description","evidence":[{"kind":"version-step","provenance":"source","package":"Go:github.com/labstack/echo/v5","fromFixed":"5.1.0","toFixed":"5.1.1","daysApart":0},{"kind":"same-code","provenance":"machine","files":["context.go"],"commits":["https://github.com/labstack/echo/commit/22e4b71109ef072ef011a489066ec662ca9565b2","https://github.com/labstack/echo/commit/ebbb855f5827b76fb206e267dd91d020000baf66","https://github.com/labstack/echo/commit/ca4f38a474302aabee93c66bdd0052359882e181","https://github.com/labstack/echo/commit/d1d8ad3f99dd9b80542cd0c357d56a8916c515df"],"basis":"shared file"}]}},{"cve":"CVE-2026-118658","published":"2026-10-28","fixed":"5.1.1","kev":false},{"cve":"CVE-2026-118655","published":"2026-10-28","fixed":"5.2.0","kev":false,"link":{"from":"CVE-2026-118658","to":"CVE-2026-118655","relation":"successor","confidence":"low","kind":"sequence","orderedBy":"description","evidence":[{"kind":"version-step","provenance":"source","package":"Go:github.com/labstack/echo/v4","fromFixed":"4.15.2","toFixed":"4.15.3","daysApart":0},{"kind":"version-step","provenance":"source","package":"Go:github.com/labstack/echo/v5","fromFixed":"5.1.1","toFixed":"5.2.0","daysApart":0}]}},{"cve":"CVE-2026-55677","published":"2026-06-26","fixed":"5.2.0","kev":false},{"cve":"CVE-2026-118266","published":"2026-10-28","fixed":"5.4.0","kev":false}],"package":"Go:github.com/labstack/echo/v5"}}