{"id":"CVE-2024-42475","published":"2024-08-15T18:40:49Z","modified":"2024-08-19T19:23:56Z","title":"OAuth library for nim allows insecure generation of state values by generateState - entropy too low and uses regular…","vendor":"CORDEA","product":"oauth","tier":"tail","description":{"text":"In the OAuth library for nim prior to version 0.11, the `state` values generated by the `generateState` function do not have sufficient entropy. These can be successfully guessed by an attacker allowing them to perform a CSRF vs a user, associating the user's session with the attacker's protected resources. While `state` isn't exactly a cryptographic value, it should be generated in a cryptographically secure way. `generateState` should be using a CSPRNG. Version 0.11 modifies the `generateState` function to generate `state` values of at least 128 bits of entropy while using a CSPRNG.","provenance":"source","from":"CVE.org"},"cvss":{"score":6.5,"severity":"MEDIUM","version":"3.1","vector":"CVSS:3.1/AV:N/AC:L/PR:N/UI:R/S:U/C:H/I:N/A:N","provenance":"source","from":"CVE.org CNA"},"epss":{"score":0.00328,"percentile":0.18384,"provenance":"source"},"cwes":[{"id":"CWE-330","name":"Use of Insufficiently Random Values"},{"id":"CWE-352","name":"Cross-Site Request Forgery"}],"references":[{"url":"https://github.com/CORDEA/oauth/security/advisories/GHSA-332c-q46h-fg8f","tags":["x_refsource_CONFIRM"]},{"url":"https://github.com/CORDEA/oauth/blob/b8c163b0d9cfad6d29ce8c1fb394e5f47182ee1c/src/oauth2.nim#L179","tags":["x_refsource_MISC"]}],"priority":{"score":8.2,"factors":[{"name":"EPSS percentile","points":3.68},{"name":"CVSS severity","points":4.55}]},"vendorSlug":"cordea","affectedVersions":[{"vendor":"CORDEA","product":"oauth","versions":["< 0.11"]}],"ssvc":{"exploitation":"none","automatable":"no","technicalImpact":"partial","timestamp":"2024-08-19T19:19:16.514547Z","from":"CISA ADP","provenance":"source"},"euvd":{"id":"EUVD-2024-39635","exploited":false,"provenance":"source"}}