Cyber Resilience

CVE-2024-1631

Crypto Weakness in Dfinity Icp-Js-Core 0.20.0 – 1.0.1

Published
21 February 2024
Modified
17 June 2026
Patch / advisory
CVSS Score v3.1 9.1
Click a component to see what it means
Raw vectorCVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:N
EPSS Score 0.0088 56th percentile
Risk Priority 70 floored blend · peak EPSS

Summary

CVE-2024-1631 is a critical-severity Use of Hard-coded Cryptographic Key (CWE-321) vulnerability in Dfinity Icp-Js-Core. Its CVSS base score is 9.1 (Critical).

Operationally, exploitation aligns with the MITRE ATT&CK technique Private Keys (T1552.004); ranked in the top 44% of CVEs by exploit likelihood; it is not currently listed in the CISA KEV catalog; a public proof-of-concept is referenced.

The strongest mitigations our analysis identified map to SC-12 (Cryptographic Key Establishment and Management) and SC-13 (Cryptographic Protection) — see the control section below for these in your framework.

OWASP Top 10 for Web (2025)

EU & UK References

Vulnerability Data

Impact: The library offers a function to generate an ed25519 key pair via Ed25519KeyIdentity.generate with an optional param to provide a 32 byte seed value, which will then be used as the secret key. When no seed value is provided,…

more

it is expected that the library generates the secret key using secure randomness. However, a recent change broke this guarantee and uses an insecure seed for key pair generation. Since the private key of this identity (535yc-uxytb-gfk7h-tny7p-vjkoe-i4krp-3qmcl-uqfgr-cpgej-yqtjq-rqe) is compromised, one could lose funds associated with the principal on ledgers or lose access to a canister where this principal is the controller.

CWE(s)

Related Threats

MITRE ATT&CK Enterprise Techniques

T1552.004 Private Keys Credential Access
Adversaries may search for private key certificate files on compromised systems for insecurely stored credentials.
T1552 Unsecured Credentials Credential Access
Adversaries may search compromised systems to find and obtain insecurely stored credentials.
T1552.001 Credentials In Files Credential Access
Adversaries may search local file systems and remote file shares for files containing insecurely stored credentials.
T1606 Forge Web Credentials Credential Access
Adversaries may forge credential materials that can be used to gain access to web applications or Internet services.
T1606.001 Web Cookies Credential Access
Adversaries may forge web cookies that can be used to gain access to web applications or Internet services.
T1110 Brute Force Credential Access
Adversaries may use brute force techniques to gain access to accounts when passwords are unknown or when password hashes are obtained.
Derived from this CVE’s CWE(s) via the direct CWE→ATT&CK cross-walk.

CVEs Like This One

CVE-2023-20016Shared CWE-321, CWE-330
CVE-2024-11991Same vendor: Dfinity
CVE-2024-7884Same vendor: Dfinity
CVE-2024-4435Same vendor: Dfinity
CVE-2023-6245Same vendor: Dfinity
CVE-2025-22150Shared CWE-330
CVE-2025-10745Shared CWE-330
CVE-2025-13353Shared CWE-330
CVE-2025-15574Shared CWE-330
CVE-2025-43866Shared CWE-330

Affected Assets

dfinity
icp-js-core
0.20.0 — 1.0.1

Mitigating Controls

Control response

Prevent
Stop it (NIST 800-53)

Detect
Catch it (NIST detect / respond)

Harden
Shrink the surface (DISA STIG)
  • 8 hardening rules · 4 OS baselines
Validate
Prove the fix (OWASP ASVS)

Mitigating Controls (NIST 800-53 r5) AI

Requiring cryptographic keys to be established and managed according to defined requirements prevents developers from embedding static unchangeable keys.

SC-13 requires selection and implementation of approved cryptographic algorithms and methods, which inherently depend on and enforce sufficiently random values.

Mitigating Controls (NIST CSF 2.0) AI

Derived directly from the weakness types (CWEs) cited in the NVD entry via our AI-authored CWE→CSF cross-walk (authority under review) — links open the control.

PR.PS-06 mostly match
prevents

Secure-SDLC activities such as code review and secret scanning directly prevent embedding static keys.

PR.DS-01 partial match
prevents

Data-at-rest protection policies require proper key management and therefore discourage hard-coded keys.

PR.DS-02 partial match
prevents

Data-in-transit protection similarly depends on non-hard-coded keys for encryption.

PR.PS-01 partial match
prevents

Configuration baselines and reviews can prohibit hard-coded keys in deployed artifacts.

Mitigating Controls (ISO/IEC 27001:2022 Annex A) AI

Derived directly from the weakness types (CWEs) cited in the NVD entry via our AI-authored CWE→ISO cross-walk (authority under review) — links open the control.

prevents

Cryptographic controls require use of approved, sufficiently random values for keys and nonces.

finds

Security testing can detect weak randomness but does not prescribe the control itself.

prevents

Secure SDLC processes include verification steps that can catch insufficient randomness but do not directly specify RNG requirements.

prevents

Secure coding standards explicitly prohibit use of weak or predictable random number generators.

degrades

Secure authentication mechanisms depend on unpredictable values (nonces, salts, session tokens) to resist guessing.

Hardening callouts derived

Configuration rules from DISA STIG baselines that bear on weaknesses of the type cited by this CVE. Each rule is shown with the relationship its mapping actually records, against the CWE it was authored against. Derived via CVE→CWE over `controls_xwalks` (authoritative rows only; rows rated `none` are excluded).

Oracle Linux 8 (3 rules)
  • V-248563 The OL 8 SSH server must be configured to use strong entropy. prevents CWE-330
  • V-248599 OL 8 must enable the hardware random number generator entropy gatherer service. prevents CWE-330
  • V-248600 OL 8 must have the packages required to use the hardware random number generator entropy gatherer service. prevents CWE-330
Oracle Linux 9 (1 rule)
  • V-271511 OL 9 must enable the hardware random number generator entropy gatherer service. prevents CWE-330
RHEL 8 (3 rules)
  • V-244527 RHEL 8 must have the packages required to use the hardware random number generator entropy gatherer service. prevents CWE-330
  • V-230253 RHEL 8 must ensure the SSH server uses strong entropy. prevents CWE-330
  • V-230285 RHEL 8 must enable the hardware random number generator entropy gatherer service. prevents CWE-330
RHEL 9 (1 rule)
  • V-257782 RHEL 9 must enable the hardware random number generator entropy gatherer service. prevents CWE-330

References