Vulnerabilities in pkg:nuget/Duende.AccessTokenManagement.OpenIdConnect
PACKAGECVE-2024-51987 is a MODERATE (CVSS 5.4) http client uses incorrect token vulnerability (CWE-270: Privilege Context Switching Error) affecting Duende.AccessTokenManagement.OpenIdConnect libraries in the NuGet ecosystem. The issue involves http client uses incorrect token after refresh. Remediation is available by upgrading affected packages to version 3.0.1.
pkg:nuget/Duende.AccessTokenManagement.OpenIdConnect
Vulnerability advisories affecting package pkg:nuget/Duende.AccessTokenManagement.OpenIdConnect. Select an advisory below to view technical details or fixes.
| Advisory ID | CVE / NVD | Severity | Summary |
|---|---|---|---|
| GHSA-7mr7-4f54-vcx5 | CVE-2024-51987 | MODERATE | HTTP Client uses incorrect token after refresh |
CVE-2024-51987 at a Glance
Security Impact
CVSS: 5.4
The security impact metrics below are parsed directly from the CVSS v3.1 vector string (CVSS:3.1/AV:N/AC:L/PR:N/UI:R/S:U/C:L/I:L/A:N).
How to Fix CVE-2024-51987
To remediate this vulnerability, upgrade all affected Duende.AccessTokenManagement.OpenIdConnect 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 Duende.AccessTokenManagement.OpenIdConnect to 3.0.1
Run the following command in your project directory to verify that all resolved dependencies use the patched release:
inspect dependencies for Duende.AccessTokenManagement.OpenIdConnect
How to Check if You Are Affected
To determine whether your application is affected by CVE-2024-51987, inspect your project dependencies for Duende.AccessTokenManagement.OpenIdConnect:
inspect dependencies for Duende.AccessTokenManagement.OpenIdConnect
Analyze the terminal output to locate any version of Duende.AccessTokenManagement.OpenIdConnect in your dependency tree. If any resolved version matches the vulnerable ranges listed in the table below (for example, versions earlier than 3.0.1), 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-270: Privilege Context Switching Error, where the product does not properly manage privileges while it is switching between different contexts that have different privileges or spheres of control. In Duende.AccessTokenManagement.OpenIdConnect, 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
CVE-2024-51987 Affected Duende.AccessTokenManagement.OpenIdConnect Versions
1 component(s)| Product / Package | Ecosystem | Affected Versions | Fixed Version |
|---|---|---|---|
|
Duende.AccessTokenManagement.OpenIdConnect
|
NuGet |
≥ 3.0.0
< 3.0.1
All 1 versions
3.0.0
|
3.0.1
|
References
Frequently Asked Questions
What is CVE-2024-51987?
Which Duende.AccessTokenManagement.OpenIdConnect versions are affected?
What version fixes CVE-2024-51987?
Is Duende.AccessTokenManagement.OpenIdConnect affected?
What is the CVSS score of CVE-2024-51987?
What CWE is associated with CVE-2024-51987?
How can I check NuGet dependencies for CVE-2024-51987?
Machine-readable OSV JSON
OSV v1.5 Schema
{
"schema_version" : "1.4.0",
"id" : "GHSA-7mr7-4f54-vcx5",
"modified" : "2024-11-08T13:55:27Z",
"published" : "2024-11-07T21:57:52Z",
"aliases" : [ "CVE-2024-51987" ],
"summary" : "HTTP Client uses incorrect token after refresh",
"details" : "### Impact\nHTTP Clients created by `AddUserAccessTokenHttpClient` may use a different user's access token after a token refresh. This occurs because a refreshed token will be captured in pooled `HttpClient` instances, which may be used by a different user.\n\n### Workarounds\nInstead of using `AddUserAccessTokenHttpClient` to create an `HttpClient` that automatically adds a managed token to outgoing requests, you can use the `HttpConext.GetUserAccessTokenAsync` extension method or the `IUserTokenManagementService.GetAccessTokenAsync` method.\n\n### Patches\nThis issue is fixed in Duende.AccessTokenManagement.OpenIdConnect 3.0.1.\n\n",
"severity" : [ {
"type" : "CVSS_V3",
"score" : "CVSS:3.1/AV:N/AC:L/PR:N/UI:R/S:U/C:L/I:L/A:N"
}, {
"type" : "CVSS_V4",
"score" : "CVSS:4.0/AV:N/AC:L/AT:N/PR:N/UI:P/VC:L/VI:L/VA:N/SC:N/SI:N/SA:N"
} ],
"affected" : [ {
"package" : {
"ecosystem" : "NuGet",
"name" : "Duende.AccessTokenManagement.OpenIdConnect"
},
"ranges" : [ {
"type" : "ECOSYSTEM",
"events" : [ {
"introduced" : "3.0.0"
}, {
"fixed" : "3.0.1"
} ]
} ],
"versions" : [ "3.0.0" ]
} ],
"references" : [ {
"type" : "WEB",
"url" : "https://github.com/DuendeSoftware/Duende.AccessTokenManagement/security/advisories/GHSA-7mr7-4f54-vcx5"
}, {
"type" : "ADVISORY",
"url" : "https://nvd.nist.gov/vuln/detail/CVE-2024-51987"
}, {
"type" : "WEB",
"url" : "https://github.com/DuendeSoftware/Duende.AccessTokenManagement/commit/09c73e32b182da5c6d7b55ec790cb2271cc4b63f"
}, {
"type" : "PACKAGE",
"url" : "https://github.com/DuendeSoftware/Duende.AccessTokenManagement"
}, {
"type" : "WEB",
"url" : "https://github.com/DuendeSoftware/Duende.AccessTokenManagement/releases/tag/3.0.1"
} ],
"database_specific" : {
"cwe_ids" : [ "CWE-270" ],
"severity" : "MODERATE",
"github_reviewed" : true,
"github_reviewed_at" : "2024-11-07T21:57:52Z",
"nvd_published_at" : "2024-11-08T00:15:15Z"
}
}