{"answers":{"affected":"2 open source packages ship an affected version, including @nfid/embed.","exploited":"There is no known exploitation of GHSA-84c3-j8r2-mcm8 in the wild and no public exploit code.","fix":"Upgrade @nfid/embed to 0.10.1-alpha.6 or later.","what":"GHSA-84c3-j8r2-mcm8 is a vulnerability in @nfid/embed, published on 26 Feb 2024. An attacker can exploit it over the internet without logging in, with no action from the victim."},"fix_prompt":"Check this codebase for GHSA-84c3-j8r2-mcm8 and fix it if it is affected.\n\nWhat it is: GHSA-84c3-j8r2-mcm8 is a vulnerability in @nfid/embed, published on 26 Feb 2024. An attacker can exploit it over the internet without logging in, with no action from the victim.\nExploitation: There is no known exploitation of GHSA-84c3-j8r2-mcm8 in the wild and no public exploit code.\n\nAffected packages and fixed versions:\n- @nfid/embed (npm): affected from 0.10.0; fixed in 0.10.1-alpha.6\n- @nfid/embed (npm): affected from 0.10.0; fixed in 0.10.1-alpha.6\n\nTask:\n1. Search the dependency manifests and lockfiles (for example package.json, package-lock.json, requirements.txt, poetry.lock, uv.lock, pom.xml, build.gradle, go.mod, Cargo.lock, Gemfile.lock) and any Dockerfiles for the affected packages, including transitive dependencies.\n2. If an affected version is in use, upgrade it to the fixed version for its release line with the project's package manager, so the lockfile is regenerated. Prefer the smallest upgrade that fixes it.\n3. If there is no fix, or the upgrade would break the build, do not guess: explain the risk and the safest workaround instead.\n4. Run the tests and summarise what changed and why.\n5. If nothing in the project is affected, say so and change nothing.\n\nReference: https://insights.sbomify.com/GHSA-84c3-j8r2-mcm8/ (Markdown: https://insights.sbomify.com/GHSA-84c3-j8r2-mcm8/index.md)","id":"GHSA-84c3-j8r2-mcm8","markdown":"https://insights.sbomify.com/GHSA-84c3-j8r2-mcm8/index.md","name":"GHSA-84c3-j8r2-mcm8","record":{"aliases":[],"analysis":{"component_type":"library","fix_type":"upgrade","impacts":["account_takeover","data_read"],"network_reachable":"yes","non_default_config":false,"product_category":"JavaScript authentication library","requires_auth":"none","summary":"Insecure key generation in DFINITY auth-client allows attackers to compromise user sessions and access funds or canisters.","user_interaction":"not_required","vuln_class":"weak_cryptography"},"analysis_generated_by":"qwen3.8-flash-next","assigner":null,"cpe":[],"cvss":{"score":null,"severity":null,"source":null,"vector":null,"version":null},"cwes":[],"description":"### Problem\nUser sessions in the @nfid/embed SDK with Ed25519 keys are vulnerable due to a compromised private key `535yc-uxytb-gfk7h-tny7p-vjkoe-i4krp-3qmcl-uqfgr-cpgej-yqtjq-rqe`. This exposes users to potential loss of funds on ledgers and unauthorized access to canisters they control.\n\n### Solution\nUsing version \u003e1.0.1 of @dfinity/auth-client and @dfinity/identity packages, or @nfid/embed \u003e0.10.1-alpha.6 includes patched versions of the issue.\n\nUser sessions will be automatically fixed when they re-authenticate.\n\n### Why this happened\nThe DFINITY auth client library provides a function, `Ed25519KeyIdentity.generate`, for generating an Ed25519 key pair. This function includes an optional parameter to supply a 32-byte seed value, which will be utilized as the secret key. In cases where no seed value is provided, the library is expected to generate the secret key using secure randomness. However, a recent update of DFINITY libraries has compromised this assurance by employing an insecure seed for key pair generation.\n\n### References\n[AgentJS CVE ](https://github.com/dfinity/agent-js/security/advisories/GHSA-c9vv-fhgv-cjc3)","ecosystems":["npm"],"exploits":{"exploitdb":null,"first_seen":null,"github_poc":null,"max_poc_stars":null,"metasploit":null,"nuclei":null,"refs":[],"tier":null},"has_fix":true,"headline":"@nfid/embed has compromised private key due to @dfinity/auth-client producing insecure session keys","id":"GHSA-84c3-j8r2-mcm8","indexable":true,"kev":null,"kind":"advisory","links":{"ecosystem":"npm","product":null,"products":[],"type":"weak_cryptography","year":"2024"},"n_packages":2,"n_references":null,"packages":[{"ecosystem":"npm","fixed":["0.10.1-alpha.6"],"introduced":["0.10.0"],"last_affected":[],"package":"@nfid/embed","purl":null,"source":"GHSA-84c3-j8r2-mcm8"},{"ecosystem":"npm","fixed":["0.10.1-alpha.6"],"introduced":["0.10.0"],"last_affected":[],"package":"@nfid/embed","purl":"pkg:npm/%40nfid/embed","source":"GHSA-84c3-j8r2-mcm8"}],"products":null,"published":"2024-02-26","related":[],"sources":[{"class":"attribution","licence":"CC BY 4.0","name":"GitHub Advisory Database","prefix":"GHSA"}],"ssvc":{"automatable":null,"exploitation":null,"technical_impact":null},"state":null,"updated":null,"vendors":null},"summary":"Insecure key generation in DFINITY auth-client allows attackers to compromise user sessions and access funds or canisters.","url":"https://insights.sbomify.com/GHSA-84c3-j8r2-mcm8/"}