# CVE-2022-39218: Random number seed fixed during compilation

- Severity: High 7.5 (CVSS:3.1, scored by GitHub_M) `CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:N/A:N`
- Known to be exploited: not in CISA's catalogue, which lists only what CISA has confirmed
- Likelihood of exploitation in the next 30 days (EPSS): 0.94%, higher than 62% of CVEs (2026-12-01)
- Published: 2022-09-20T19:50:08.000Z
- Modified: 2026-06-17T04:57:56.313Z
- Also known as: GHSA-cmr8-5w4c-44v8
- Weaknesses: CWE-330, CWE-335
- SSVC (CISA-ADP): exploitation none, automatable yes, technical impact partial
- Assigned by: GitHub_M

## Description

The JS Compute Runtime for Fastly's Compute@Edge platform provides the environment JavaScript is executed in when using the Compute@Edge JavaScript SDK. In versions prior to 0.5.3, the `Math.random` and `crypto.getRandomValues` methods fail to use sufficiently random values. The initial value to seed the PRNG (pseudorandom number generator) is baked-in to the final WebAssembly module, making the sequence of random values for that specific WebAssembly module predictable. An attacker can use the fixed seed to predict random numbers generated by these functions and bypass cryptographic security controls, for example to disclose sensitive data encrypted by functions that use these generators. The problem has been patched in version 0.5.3. No known workarounds exist.

(As written by CVE List.)

## Affected

- fastly js-compute-runtime: < 0.5.3
- @fastly/js-compute (npm): from 0.4.0 before 0.5.3
- fastly js-compute: before 0.5.3

## Every score

- GitHub_M: CVSS:3.1 7.5 High `CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:N/A:N`
- GitHub: CVSS:3.1 7.5 High `CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:N/A:N`
- NVD: CVSS:3.1 7.5 High `CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:N/A:N`

## References

- <https://github.com/fastly/js-compute-runtime/security/advisories/GHSA-cmr8-5w4c-44v8> (third-party-advisory, web)
- <https://nvd.nist.gov/vuln/detail/CVE-2022-39218> (advisory)
- <https://github.com/fastly/js-compute-runtime/commit/65524ffc962644e9fc39f4b368a326b6253912a9> (web)
- <https://github.com/fastly/js-compute-runtime> (package)

## Sources

- CVE List: [CVE-2022-39218](https://www.cve.org/CVERecord?id=CVE-2022-39218), CVE Terms of Use, modified 2025-04-23
- GitHub Advisory Database: [GHSA-cmr8-5w4c-44v8](https://github.com/advisories/GHSA-cmr8-5w4c-44v8), CC-BY-4.0, modified 2023-11-08
- NVD: [CVE-2022-39218](https://nvd.nist.gov/vuln/detail/CVE-2022-39218), Public domain, modified 2026-06-17

---

Page: https://cve.day/CVE-2022-39218 · Whole record: https://cve.day/CVE-2022-39218.json · Rebuilt by cve.day 2026-11-25T22:58:15.144Z
