CVE-2020-7787: Improper Authentication in react-adal
8.2
CVSS Score
3.1
Basic Information
CVE ID
GHSA ID
EPSS Score
0.49996%
CWE
Published
4/13/2021
Updated
2/1/2023
KEV Status
No
Technology
JavaScript
Technical Details
CVSS Vector
CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:L/A:N
Package Name | Ecosystem | Vulnerable Versions | First Patched Version |
---|---|---|---|
react-adal | npm | < 0.5.1 | 0.5.1 |
Vulnerability Intelligence
Miggo AI
Root Cause Analysis
The vulnerability stems from how nonce and state values were stored with trailing || delimiters, creating empty string entries. The original validation functions (_matchNonce and _matchState) iterated through split values without checking for empty elements. This allowed attackers to submit empty nonce/session parameters that would match the stored empty strings. The commit diff shows these functions were modified to add truthiness checks (requestNonce[i] && ...), confirming these were the vulnerable validation points. The CVE description directly implicates the nonce and state validation logic as the flawed authentication mechanism.