GHSA-3rw9-wmc8-8948: Github.com/coder/coder/v2 Coder Accepts An APIKey Beyond Vulnerability
LOWGHSA-3rw9-wmc8-8948 is a LOW coder accepts an apikey beyond vulnerability (CWE-324: Use of a Key Past its Expiration Date) affecting Github.com/coder/coder/v2 libraries in the Go ecosystem. The issue involves coder accepts an apikey beyond the linked oidc expiry if there is no refresh token. Remediation is available by upgrading affected packages to version 2.23.0.
GHSA-3rw9-wmc8-8948 at a Glance
How to Fix GHSA-3rw9-wmc8-8948
To remediate this vulnerability, upgrade all affected Github.com/coder/coder/v2 dependencies to a patched release. Both direct and transitive dependencies should be checked, as frameworks or security libraries may pull in vulnerable versions transitively.
Upgrade github.com/coder/coder/v2 to 2.23.0
Run the following command in your project directory to verify that all resolved dependencies use the patched release:
inspect dependencies for github.com/coder/coder/v2
How to Check if You Are Affected
To determine whether your application is affected by GHSA-3rw9-wmc8-8948, inspect your project dependencies for Github.com/coder/coder/v2:
inspect dependencies for github.com/coder/coder/v2
Analyze the terminal output to locate any version of Github.com/coder/coder/v2 in your dependency tree. If any resolved version matches the vulnerable ranges listed in the table below (for example, versions earlier than 2.23.0), your application is affected.
Note: Verify declared build manifests and deployed runtime container environments.
Technical Details
Vulnerability Mechanism & Technical Analysis
This vulnerability is classified under CWE-324: Use of a Key Past its Expiration Date, where the product uses a cryptographic key or password past its expiration date, which diminishes its safety significantly by increasing the timing window for cracking attacks against that key. In Github.com/coder/coder/v2, software state validation or input boundaries are circumvented during processing. Review the official source advisory statement below for specific affected components, classes, and reproduction details.
Source Advisory Statement
GHSA-3rw9-wmc8-8948 Affected Github.com/coder/coder/v2 Versions
1 component(s)| Product / Package | Ecosystem | Affected Versions | Fixed Version |
|---|---|---|---|
|
github.com/coder/coder/v2
|
Go |
< 2.23.0
|
2.23.0
|
References
Frequently Asked Questions
What is GHSA-3rw9-wmc8-8948?
Which Github.com/coder/coder/v2 versions are affected?
What version fixes GHSA-3rw9-wmc8-8948?
Is github.com/coder/coder/v2 affected?
What CWE is associated with GHSA-3rw9-wmc8-8948?
How can I check Go dependencies for GHSA-3rw9-wmc8-8948?
Machine-readable OSV JSON
OSV v1.5 Schema
{
"schema_version" : "1.4.0",
"id" : "GHSA-3rw9-wmc8-8948",
"modified" : "2025-08-28T19:36:05Z",
"published" : "2025-08-28T19:36:04Z",
"aliases" : [ ],
"summary" : "Coder accepts an APIKey beyond the linked OIDC expiry if there is no refresh token",
"details" : "### Summary\nIf users log in to Coder via OIDC, and the OpenID Identity Provider does not return a refresh token, then Coder may allow their web session to continue beyond the expiration of the token returned by the OpenID Identity Provider.\n\n### Details\nWhen a user logs in via OIDC, Coder stores the OIDC token and refresh token (if any) in its datastore and sets an APIKey in the user's cookies. If there is a refresh token, then when the OIDC token is expired and a request is made with the APIKey, we attempt to refresh the OIDC token. If refresh fails, the Coder API request is also failed and the user needs to log in again.\n\nHowever, if there is no refresh token provided, then affected versions of Coder fail to enforce the expiry of the OIDC token, and allow users to make API requests even if it is expired so long as their APIKey stored in cookies has not expired.\n\nCoder APIKeys have an expiry and lifetime of 24 hours, but Coder is configured to extend the lifetime of the APIKey by up to 24 hours from the time it is used successfully. So, an APIKey that is used at least once every 24 hours will not expire. (This behavior can be disabled by configuration). \n\n### Impact\nThis could allow a user to access the Coder service beyond the lifetime of the token issued by the OpenID provider, potentially indefinitely, even if they are no loner authorized via OIDC.",
"severity" : [ {
"type" : "CVSS_V4",
"score" : "CVSS:4.0/AV:N/AC:L/AT:P/PR:L/UI:N/VC:L/VI:L/VA:N/SC:N/SI:N/SA:N"
} ],
"affected" : [ {
"package" : {
"ecosystem" : "Go",
"name" : "github.com/coder/coder/v2"
},
"ranges" : [ {
"type" : "ECOSYSTEM",
"events" : [ {
"introduced" : "0"
}, {
"fixed" : "2.23.0"
} ]
} ]
} ],
"references" : [ {
"type" : "WEB",
"url" : "https://github.com/coder/coder/security/advisories/GHSA-3rw9-wmc8-8948"
}, {
"type" : "WEB",
"url" : "https://github.com/coder/coder/commit/1a4160803589034ce1518e24a78f232c8d08f996"
}, {
"type" : "PACKAGE",
"url" : "https://github.com/coder/coder"
} ],
"database_specific" : {
"cwe_ids" : [ "CWE-324" ],
"severity" : "LOW",
"github_reviewed" : true,
"github_reviewed_at" : "2025-08-28T19:36:04Z",
"nvd_published_at" : null
}
}