{"id":"CVE-2021-45709","aliases":["GHSA-pmcv-mgcf-rvxg","RUSTSEC-2021-0121"],"url":"https://o3.security/vulnerability/CVE-2021-45709","summary":"Use of a Broken or Risky Cryptographic Algorithm in crypto2","details":"The implementation does not enforce alignment requirements on input slices while incorrectly assuming 4-byte alignment through an unsafe call to std::slice::from_raw_parts_mut, which breaks the contract and introduces undefined behavior.\n\nThis affects Chacha20 encryption and decryption in crypto2.","published":"2022-01-06T22:04:51Z","modified":"2023-11-08T04:07:23.178602Z","cvss":{"score":9.8,"severity":"CRITICAL","vector":"CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:H"},"epss":null,"cisaKev":null,"exploitsKnown":0,"affectedPackages":[{"ecosystem":"crates.io","name":"crypto2","fixedVersion":null}],"fix":null,"references":[{"type":"ADVISORY","url":"https://nvd.nist.gov/vuln/detail/CVE-2021-45709"},{"type":"WEB","url":"https://github.com/shadowsocks/crypto2/issues/27"},{"type":"PACKAGE","url":"https://github.com/shadowsocks/crypto2"},{"type":"WEB","url":"https://raw.githubusercontent.com/rustsec/advisory-db/main/crates/crypto2/RUSTSEC-2021-0121.md"},{"type":"WEB","url":"https://rustsec.org/advisories/RUSTSEC-2021-0121.html"}],"provenance":{"sources":["OSV.dev","FIRST.org (EPSS)"],"lastVerified":"2023-11-08T04:07:23.178602Z"}}