CVE-2022-31142
Fastify Bearer-Auth Timing Attack Mishandling
Description
@fastify/bearer-auth is a Fastify plugin to require bearer Authorization headers. @fastify/bearer-auth prior to versions 7.0.2 and 8.0.1 does not securely use crypto.timingSafeEqual. A malicious attacker could estimate the length of one valid bearer token. According to the corresponding RFC 6750, the bearer token has only base64 valid characters, reducing the range of characters for a brute force attack. Version 7.0.2 and 8.0.1 of @fastify/bearer-auth contain a patch. There are currently no known workarounds. The package fastify-bearer-auth, which covers versions 6.0.3 and prior, is also vulnerable starting at version 5.0.1. Users of fastify-bearer-auth should upgrade to a patched version of @fastify/bearer-auth.
INFO
Published Date :
July 14, 2022, 7:15 p.m.
Last Modified :
July 20, 2022, 12:45 p.m.
Source :
[email protected]
Remotely Exploitable :
Yes !
Impact Score :
3.6
Exploitability Score :
3.9
References to Advisories, Solutions, and Tools
Here, you will find a curated list of external links that provide in-depth
information, practical solutions, and valuable tools related to
CVE-2022-31142
.
URL | Resource |
---|---|
https://github.com/fastify/fastify-bearer-auth/commit/0c468a616d7e56126dc468150f6a5a92e530b8e4 | Patch Third Party Advisory |
https://github.com/fastify/fastify-bearer-auth/commit/39353b15409ee99474545f615ffb16180cf3b716 | Patch Third Party Advisory |
https://github.com/fastify/fastify-bearer-auth/commit/f921a0582dc83112039004a9b5041141b50c5b3f | Patch Third Party Advisory |
https://github.com/fastify/fastify-bearer-auth/security/advisories/GHSA-376v-xgjx-7mfr | Third Party Advisory |
https://hackerone.com/reports/1633287 | Permissions Required Third Party Advisory |
We scan GitHub repositories to detect new proof-of-concept exploits. Following list is a collection of public exploits and proof-of-concepts, which have been published on GitHub (sorted by the most recently updated).
Results are limited to the first 15 repositories due to potential performance issues.
The following list is the news that have been mention
CVE-2022-31142
vulnerability anywhere in the article.
The following table lists the changes that have been made to the
CVE-2022-31142
vulnerability over time.
Vulnerability history details can be useful for understanding the evolution of a vulnerability, and for identifying the most recent changes that may impact the vulnerability's severity, exploitability, or other characteristics.
-
CVE Modified by [email protected]
May. 14, 2024
Action Type Old Value New Value -
Initial Analysis by [email protected]
Jul. 20, 2022
Action Type Old Value New Value Added CVSS V3.1 NIST AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:N/A:N Changed Reference Type https://github.com/fastify/fastify-bearer-auth/commit/0c468a616d7e56126dc468150f6a5a92e530b8e4 No Types Assigned https://github.com/fastify/fastify-bearer-auth/commit/0c468a616d7e56126dc468150f6a5a92e530b8e4 Patch, Third Party Advisory Changed Reference Type https://github.com/fastify/fastify-bearer-auth/commit/39353b15409ee99474545f615ffb16180cf3b716 No Types Assigned https://github.com/fastify/fastify-bearer-auth/commit/39353b15409ee99474545f615ffb16180cf3b716 Patch, Third Party Advisory Changed Reference Type https://github.com/fastify/fastify-bearer-auth/commit/f921a0582dc83112039004a9b5041141b50c5b3f No Types Assigned https://github.com/fastify/fastify-bearer-auth/commit/f921a0582dc83112039004a9b5041141b50c5b3f Patch, Third Party Advisory Changed Reference Type https://github.com/fastify/fastify-bearer-auth/security/advisories/GHSA-376v-xgjx-7mfr No Types Assigned https://github.com/fastify/fastify-bearer-auth/security/advisories/GHSA-376v-xgjx-7mfr Third Party Advisory Changed Reference Type https://hackerone.com/reports/1633287 No Types Assigned https://hackerone.com/reports/1633287 Permissions Required, Third Party Advisory Added CWE NIST CWE-203 Added CPE Configuration OR *cpe:2.3:a:fastify:bearer-auth:*:*:*:*:*:node.js:*:* versions from (including) 5.0.1 up to (excluding) 7.0.2 *cpe:2.3:a:fastify:bearer-auth:8.0.0:*:*:*:*:node.js:*:*
CWE - Common Weakness Enumeration
While CVE identifies
specific instances of vulnerabilities, CWE categorizes the common flaws or
weaknesses that can lead to vulnerabilities. CVE-2022-31142
is
associated with the following CWEs:
Common Attack Pattern Enumeration and Classification (CAPEC)
Common Attack Pattern Enumeration and Classification
(CAPEC)
stores attack patterns, which are descriptions of the common attributes and
approaches employed by adversaries to exploit the CVE-2022-31142
weaknesses.
Exploit Prediction
EPSS is a daily estimate of the probability of exploitation activity being observed over the next 30 days.
0.12 }} -0.00%
score
0.46284
percentile