Vulnerabilities in pkg:npm/libp2p-secio

PACKAGE
Advisory Summary

GHSA-rch7-f4h5-x9rj is a CRITICAL (CVSS 9.1) identity spoofing vulnerability (CWE-290: Authentication Bypass by Spoofing) affecting Libp2p secio libraries in the npm ecosystem. The issue involves identity spoofing in libp2p-secio. Remediation is available by upgrading affected packages to version 0.9.0.

1 Known Advisory Record(s)
Package Vulnerability Intelligence

pkg:npm/libp2p-secio

1 Known Advisory Record(s)

Vulnerability advisories affecting package pkg:npm/libp2p-secio. Select an advisory below to view technical details or fixes.

Advisory ID CVE / NVD Severity Summary
GHSA-rch7-f4h5-x9rj - CRITICAL Identity Spoofing in libp2p-secio

GHSA-rch7-f4h5-x9rj at a Glance

CVE Identifier N/A
GHSA Identifier GHSA-rch7-f4h5-x9rj
Severity CRITICAL
CVSS v3.1 Base Score 9.1
CWE Classification CWE-290: Authentication Bypass by Spoofing
Affected Product Libp2p secio
Package Ecosystem npm
Published Date
Last Updated

Security Impact

CVSS: 9.1

The security impact metrics below are parsed directly from the CVSS v3.1 vector string (CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:N).

Attack Vector Network (AV:N)
Attack Complexity Low (AC:L)
Privileges Required None (PR:N)
User Interaction None (UI:N)
Scope Unchanged (S:U)
Confidentiality High (C:H)
Integrity High (I:H)
Availability None (A:N)

How to Fix GHSA-rch7-f4h5-x9rj

To remediate this vulnerability, upgrade all affected Libp2p secio dependencies to a patched release. Both direct and transitive dependencies should be checked, as frameworks or security libraries may pull in vulnerable versions transitively.

libp2p-secio fixed: 0.9.0
npm install libp2p-secio@0.9.0
Verify Direct and Transitive Dependencies

Run the following command in your project directory to verify that all resolved dependencies use the patched release:

npm ls libp2p-secio

How to Check if You Are Affected

To determine whether your Node.js application is affected by GHSA-rch7-f4h5-x9rj, inspect your project dependencies using npm:

npm ls libp2p-secio

Analyze the terminal output to locate any version of Libp2p secio in your dependency tree. If any resolved version matches the vulnerable ranges listed in the table below (for example, versions earlier than 0.9.0), your application is affected.

Note: The npm ls libp2p-secio command inspects dependencies declared in your package.json and lockfile; it does not perform automated runtime dynamic scanning.

Technical Details

Vulnerability Mechanism & Technical Analysis

This vulnerability is classified under CWE-290: Authentication Bypass by Spoofing, where this attack-focused weakness is caused by incorrectly implemented authentication schemes that are subject to spoofing attacks. In Libp2p secio, software state validation or input boundaries are circumvented during processing. Review the official source advisory statement below for specific affected components, classes, and reproduction details.

Source Advisory Statement

Affected versions of `libp2p-secio` does not correctly verify that the `PeerId` of `DstPeer` matches the `PeerId` discovered in the crypto handshake, resulting in a high severity identity spoofing vulnerability. ## Recommendation Update to version 0.9.0 or later.

GHSA-rch7-f4h5-x9rj Affected Libp2p secio Versions

1 component(s)
Fixed Versions:
0.9.0
Product / Package Ecosystem Affected Versions Fixed Version
libp2p-secio
npm
< 0.9.0
0.9.0

References

Frequently Asked Questions

What is GHSA-rch7-f4h5-x9rj?
GHSA-rch7-f4h5-x9rj is a security vulnerability in Libp2p secio involving Identity Spoofing in libp2p-secio under CWE-290: Authentication Bypass by Spoofing.
Which Libp2p secio versions are affected?
Affected versions include releases prior to 0.9.0 across affected packages: libp2p-secio.
What version fixes GHSA-rch7-f4h5-x9rj?
Upgrading to 0.9.0 (or the latest patched release for your respective branch) resolves the vulnerability.
Is libp2p-secio affected?
Yes, libp2p-secio is affected in releases prior to 0.9.0. Upgrade your dependency to 0.9.0 or later.
What is the CVSS score of GHSA-rch7-f4h5-x9rj?
GHSA-rch7-f4h5-x9rj has a CVSS v3.1 base score of 9.1 (CRITICAL) with vector string CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:N.
What CWE is associated with GHSA-rch7-f4h5-x9rj?
GHSA-rch7-f4h5-x9rj is classified under CWE-290: Authentication Bypass by Spoofing (This attack-focused weakness is caused by incorrectly implemented authentication schemes that are subject to spoofing attacks.).
How can I check npm dependencies for GHSA-rch7-f4h5-x9rj?
Run the dependency tree command: 'npm ls libp2p-secio'. This command lists direct and transitive dependencies in your build configuration so you can verify if a vulnerable version is resolved.
Machine-readable OSV JSON OSV v1.5 Schema
Normalized schema output
{
  "schema_version" : "1.4.0",
  "id" : "GHSA-rch7-f4h5-x9rj",
  "modified" : "2021-08-17T21:32:42Z",
  "published" : "2019-08-23T00:04:52Z",
  "aliases" : [ ],
  "summary" : "Identity Spoofing in libp2p-secio",
  "details" : "Affected versions of `libp2p-secio` does not correctly verify that the `PeerId` of `DstPeer` matches the `PeerId` discovered in the crypto handshake, resulting in a high severity identity spoofing vulnerability. \n\n\n## Recommendation\n\nUpdate to version 0.9.0 or later.",
  "severity" : [ {
    "type" : "CVSS_V3",
    "score" : "CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:N"
  } ],
  "affected" : [ {
    "package" : {
      "ecosystem" : "npm",
      "name" : "libp2p-secio"
    },
    "ranges" : [ {
      "type" : "ECOSYSTEM",
      "events" : [ {
        "introduced" : "0"
      }, {
        "fixed" : "0.9.0"
      } ]
    } ]
  } ],
  "references" : [ {
    "type" : "WEB",
    "url" : "https://github.com/libp2p/js-libp2p-secio/pull/95"
  }, {
    "type" : "WEB",
    "url" : "https://snyk.io/vuln/npm:libp2p-secio:20180115"
  }, {
    "type" : "WEB",
    "url" : "https://www.npmjs.com/advisories/558"
  } ],
  "database_specific" : {
    "cwe_ids" : [ "CWE-290" ],
    "severity" : "CRITICAL",
    "github_reviewed" : true,
    "github_reviewed_at" : "2019-08-22T14:56:33Z",
    "nvd_published_at" : null
  }
}