CVE-2024-51752: @workos inc/authkit nextjs @workos-inc/authkit-nextjs Refresh Tokens Are Logged Vulnerability
LOWCVE-2024-51752 is a LOW @workos-inc/authkit-nextjs refresh tokens are logged vulnerability (CWE-532: Insertion of Sensitive Information into Log File) affecting @workos inc/authkit nextjs libraries in the npm ecosystem. The issue involves @workos-inc/authkit-nextjs refresh tokens are logged when the debug flag is enabled. Remediation is available by upgrading affected packages to version 0.13.2.
CVE-2024-51752 at a Glance
How to Fix CVE-2024-51752
To remediate this vulnerability, upgrade all affected @workos inc/authkit nextjs dependencies to a patched release. Both direct and transitive dependencies should be checked, as frameworks or security libraries may pull in vulnerable versions transitively.
npm install @workos-inc/authkit-nextjs@0.13.2
Run the following command in your project directory to verify that all resolved dependencies use the patched release:
npm ls @workos-inc/authkit-nextjs
How to Check if You Are Affected
To determine whether your Node.js application is affected by CVE-2024-51752, inspect your project dependencies using npm:
npm ls @workos-inc/authkit-nextjs
Analyze the terminal output to locate any version of @workos inc/authkit nextjs in your dependency tree. If any resolved version matches the vulnerable ranges listed in the table below (for example, versions earlier than 0.13.2), your application is affected.
Note: The npm ls @workos-inc/authkit-nextjs command inspects dependencies declared in your package.json and lockfile; it does not perform automated runtime dynamic scanning.
Technical Details
Vulnerability Mechanism & Technical Analysis
This vulnerability is classified under CWE-532: Insertion of Sensitive Information into Log File, where the product writes sensitive information to a log file. In @workos inc/authkit nextjs, 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-51752 Affected @workos inc/authkit nextjs Versions
1 component(s)| Product / Package | Ecosystem | Affected Versions | Fixed Version |
|---|---|---|---|
|
@workos-inc/authkit-nextjs
|
npm |
< 0.13.2
|
0.13.2
|
References
Frequently Asked Questions
What is CVE-2024-51752?
Which @workos inc/authkit nextjs versions are affected?
What version fixes CVE-2024-51752?
Is @workos-inc/authkit-nextjs affected?
What CWE is associated with CVE-2024-51752?
How can I check npm dependencies for CVE-2024-51752?
Machine-readable OSV JSON
OSV v1.5 Schema
{
"schema_version" : "1.4.0",
"id" : "GHSA-5wmg-9cvh-qw25",
"modified" : "2024-11-05T21:37:24Z",
"published" : "2024-11-05T17:34:23Z",
"aliases" : [ "CVE-2024-51752" ],
"summary" : "@workos-inc/authkit-nextjs refresh tokens are logged when the debug flag is enabled",
"details" : "### Impact\nRefresh tokens are logged to the console when the disabled by default `debug` flag, is enabled.\n\n### Patches\nPatched in [https://github.com/workos/authkit-nextjs/releases/tag/v0.13.2](https://github.com/workos/authkit-nextjs/releases/tag/v0.13.2)\n",
"severity" : [ {
"type" : "CVSS_V4",
"score" : "CVSS:4.0/AV:L/AC:L/AT:P/PR:L/UI:N/VC:L/VI:N/VA:N/SC:N/SI:N/SA:N/E:U"
} ],
"affected" : [ {
"package" : {
"ecosystem" : "npm",
"name" : "@workos-inc/authkit-nextjs"
},
"ranges" : [ {
"type" : "ECOSYSTEM",
"events" : [ {
"introduced" : "0"
}, {
"fixed" : "0.13.2"
} ]
} ]
} ],
"references" : [ {
"type" : "WEB",
"url" : "https://github.com/workos/authkit-nextjs/security/advisories/GHSA-5wmg-9cvh-qw25"
}, {
"type" : "ADVISORY",
"url" : "https://nvd.nist.gov/vuln/detail/CVE-2024-51752"
}, {
"type" : "WEB",
"url" : "https://github.com/workos/authkit-nextjs/commit/15a332632f7560b03cc6d8cc8da24fd2ac931da7"
}, {
"type" : "PACKAGE",
"url" : "https://github.com/workos/authkit-nextjs"
}, {
"type" : "WEB",
"url" : "https://github.com/workos/authkit-nextjs/releases/tag/v0.13.2"
} ],
"database_specific" : {
"cwe_ids" : [ "CWE-532" ],
"severity" : "LOW",
"github_reviewed" : true,
"github_reviewed_at" : "2024-11-05T17:34:23Z",
"nvd_published_at" : "2024-11-05T20:15:15Z"
}
}