Auth bypass in React-Adal Project
CVE-2020-7787
- CVSS v3
- 8.2 High
- Public exploits
- None known
- EPSS
- 0.013 · 70.8th percentile
- Published
- 2020-12-09
This affects all versions of package react-adal. It is possible for a specially crafted JWT token and request URL can cause the nonce, session and refresh values to be incorrectly validated, causing the application to treat an attacker-generated JWT token as authentic. The logical defect is caused by how the nonce, session and refresh values are stored in the browser local storage or session storage. Each key is automatically appended by ||. When the received nonce and session keys are generated, the list of values is stored in the browser storage, separated by ||, with || always appended to the end of the list. Since || will always be the last 2 characters of the stored values, an empty string ("") will always be in the list of the valid values. Therefore, if an empty session parameter is provided in the callback URL, and a specially-crafted JWT token contains an nonce value of "" (empty string), then adal.js will consider the JWT token as authentic.
Vulnerability class: Broken Authentication
Published · last modified .
CVSS v3 metric
CVSS v3 base score 8.2 (High). Vector: CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:L/A:N.
- Attack Vector
- Network
AV:N - Attack Complexity
- Low
AC:L - Privileges Required
- None
PR:N - User Interaction
- None
UI:N - Scope
- Unchanged
S:U - Confidentiality
- High
C:H - Integrity
- Low
I:L - Availability
- None
A:N
EPSS exploit prediction
EPSS 0.013, 70.8th percentile (last changed ); unchanged over 30 days. About EPSS.
Affected products
- React-Adal Project
- React-Adal — versions 0
Weakness classification (CWE)
References
- snyk.io/vuln/SNYK-JS-REACTADAL-1018907 (Exploit, Third Party Advisory)
- github.com/salvoravida/react-adal/pull/115 (Exploit, Third Party Advisory)