GHSA-wcx9-ccpj-hx3c

Suggest an improvement
Source
https://github.com/advisories/GHSA-wcx9-ccpj-hx3c
Import Source
https://github.com/github/advisory-database/blob/main/advisories/github-reviewed/2024/10/GHSA-wcx9-ccpj-hx3c/GHSA-wcx9-ccpj-hx3c.json
JSON Data
https://api.osv.dev/v1/vulns/GHSA-wcx9-ccpj-hx3c
Aliases
Published
2024-10-28T18:31:57Z
Modified
2024-10-30T18:50:39Z
Severity
  • 4.3 (Medium) CVSS_V3 - CVSS:3.1/AV:N/AC:L/PR:N/UI:R/S:U/C:N/I:L/A:N CVSS Calculator
  • 5.1 (Medium) CVSS_V4 - CVSS:4.0/AV:A/AC:L/AT:N/PR:N/UI:P/VC:N/VI:L/VA:N/SC:N/SI:N/SA:N CVSS Calculator
Summary
Coder vulnerable to post-auth URL redirection to untrusted site ('Open Redirect')
Details

Summary

An issue on Coder's login page allows attackers to craft a Coder URL that when clicked by a logged in user could redirect them to a website the attacker controls, e.g. https://google.com.

Details

On the login page, Coder checks for the presence of a redirect query parameter. On successful login, the user would be redirected to the location of the parameter. Improper sanitization allows attackers to specify a URL outside of the Coder application to redirect users to.

Impact

Coder users could potentially be redirected to a untrusted website if tricked into clicking a URL crafted by the attacker. Coder authentication tokens are not leaked to the resulting website.

To check if your deployment is vulnerable, visit the following URL for your Coder deployment: - https://<coder url>/login?redirect=https%3A%2F%2Fcoder.com%2Fdocs

Patched Versions

This vulnerability is remedied in - v2.16.1 - v2.15.3 - v2.14.4

All versions prior to 2.3.1 are not affected.

Thanks

  • https://github.com/jchristov

References

https://github.com/coder/coder/security/advisories/GHSA-wcx9-ccpj-hx3c https://github.com/coder/coder/commit/69c1d981e3131e50d52b01f6a360abadaad699e6

References

Affected packages

Go / github.com/coder/coder/v2

Package

Name
github.com/coder/coder/v2
View open source insights on deps.dev
Purl
pkg:golang/github.com/coder/coder/v2

Affected ranges

Type
SEMVER
Events
Introduced
2.16.0
Fixed
2.16.1

Affected versions

2.*

2.16.0

Go / github.com/coder/coder/v2

Package

Name
github.com/coder/coder/v2
View open source insights on deps.dev
Purl
pkg:golang/github.com/coder/coder/v2

Affected ranges

Type
SEMVER
Events
Introduced
2.15.0
Fixed
2.15.3

Go / github.com/coder/coder/v2

Package

Name
github.com/coder/coder/v2
View open source insights on deps.dev
Purl
pkg:golang/github.com/coder/coder/v2

Affected ranges

Type
SEMVER
Events
Introduced
2.3.1
Fixed
2.14.4