{"id":"CVE-2025-54883","summary":"Vision UI's security-kit Contains Cryptographic Weakness","details":"Vision UI is a collection of enterprise-grade, dependency-free modules for modern web projects. In versions 1.4.0 and below, the getSecureRandomInt function in security-kit versions prior to 3.5.0 (packaged in Vision-ui \u003c= 1.4.0) contains a critical cryptographic weakness. Due to a silent 32-bit integer overflow in its internal masking logic, the function fails to produce a uniform distribution of random numbers when the requested range between min and max is larger than 2³². The root cause is the use of a 32-bit bitwise left-shift operation (\u003c\u003c) to generate a bitmask for the rejection sampling algorithm. This causes the mask to be incorrect for any range requiring 32 or more bits of entropy. This issue is fixed in version 1.5.0.","aliases":["GHSA-c9xg-x7h3-mq2q"],"modified":"2026-04-02T12:54:14.072812Z","published":"2025-08-05T23:36:27.029Z","database_specific":{"osv_generated_from":"https://github.com/CVEProject/cvelistV5/tree/main/cves/2025/54xxx/CVE-2025-54883.json","cna_assigner":"GitHub_M","cwe_ids":["CWE-338"]},"references":[{"type":"ADVISORY","url":"https://github.com/CVEProject/cvelistV5/tree/main/cves/2025/54xxx/CVE-2025-54883.json"},{"type":"ADVISORY","url":"https://github.com/DavidOsipov/Vision-ui/security/advisories/GHSA-c9xg-x7h3-mq2q"},{"type":"ADVISORY","url":"https://nvd.nist.gov/vuln/detail/CVE-2025-54883"},{"type":"FIX","url":"https://github.com/DavidOsipov/Vision-ui/commit/347355859f05e98047efbd96fc0e61b9191324f1"}],"affected":[{"ranges":[{"type":"GIT","repo":"https://github.com/davidosipov/vision-ui","events":[{"introduced":"0"},{"fixed":"f3e67769b7ded045d2feb48f2ad85cba991f02d5"}]}],"versions":["1.0.0","1.4.0"],"database_specific":{"source":"https://storage.googleapis.com/cve-osv-conversion/osv-output/CVE-2025-54883.json"}}],"schema_version":"1.7.5","severity":[{"type":"CVSS_V4","score":"CVSS:4.0/AV:N/AC:L/AT:N/PR:N/UI:N/VC:H/VI:H/VA:N/SC:L/SI:L/SA:N"}]}