Vulnerabilities in pkg:npm/@webrecorder/archivewebpage

PACKAGE
Advisory Identifier: GHSA-w765-jm6w-4hhj
Advisory Summary

CVE-2025-58765 is a HIGH (CVSS 7.1) cross-site scripting vulnerability (CWE-79: Improper Neutralization of Input During Web Page Generation ('Cross-site Scripting')) affecting @webrecorder/wabac libraries in the npm ecosystem. The issue involves webrecorder packages are vulnerable to xss through 404 error handling logic. Remediation is available by upgrading affected packages to version 2.23.11, 2.3.17, 0.15.4.

1 Known Advisory Record(s)
Package Vulnerability Intelligence

pkg:npm/@webrecorder/archivewebpage

1 Known Advisory Record(s)

Vulnerability advisories affecting package pkg:npm/@webrecorder/archivewebpage. Select an advisory below to view technical details or fixes.

Advisory ID CVE / NVD Severity Summary
GHSA-w765-jm6w-4hhj CVE-2025-58765 HIGH Webrecorder packages are vulnerable to XSS through 404 error handling logic

CVE-2025-58765 at a Glance

CVE Identifier CVE-2025-58765
GHSA Identifier GHSA-w765-jm6w-4hhj
Severity HIGH
CVSS v3.1 Base Score 7.1
CWE Classification CWE-79: Improper Neutralization of Input During Web Page Generation ('Cross-site Scripting')
Affected Product @webrecorder/wabac
Package Ecosystem npm
Published Date
Last Updated

Security Impact

CVSS: 7.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:R/S:C/C:L/I:L/A:L).

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

How to Fix CVE-2025-58765

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

@webrecorder/wabac fixed: 2.23.11
npm install @webrecorder/wabac@2.23.11
replaywebpage fixed: 2.3.17
npm install replaywebpage@2.3.17
@webrecorder/archivewebpage fixed: 0.15.4
npm install @webrecorder/archivewebpage@0.15.4
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 @webrecorder/wabac

How to Check if You Are Affected

To determine whether your Node.js application is affected by CVE-2025-58765, inspect your project dependencies using npm:

npm ls @webrecorder/wabac

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

Note: The npm ls @webrecorder/wabac 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-79: Improper Neutralization of Input During Web Page Generation ('Cross-site Scripting'), where the product does not neutralize or incorrectly neutralizes user-controllable input before it is placed in output that is used as a web page that is served to other users. In @webrecorder/wabac, 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

A Reflected Cross-Site Scripting (XSS) vulnerability exists in the 404 error handling logic of wabac.js v2.23.10 and below. The parameter `requestURL` (derived from the original request target) is directly embedded into an inline `<script>` block without sanitization or escaping. This allows an attacker to craft a malicious URL that executes arbitrary JavaScript in the victim’s browser. The scope may be limited by CORS policies, depending on the situation in which wabac.js is used. ### Patches The vulnerability is fixed in wabac.js v2.23.11.

CVE-2025-58765 Affected @webrecorder/wabac Versions

3 component(s)
Fixed Versions:
2.23.112.3.170.15.4
Product / Package Ecosystem Affected Versions Fixed Version
@webrecorder/wabac
npm
< 2.23.11
2.23.11
replaywebpage
npm
< 2.3.17
2.3.17
@webrecorder/archivewebpage
npm
< 0.15.4
0.15.4

References

Frequently Asked Questions

What is CVE-2025-58765?
CVE-2025-58765 is a security vulnerability in @webrecorder/wabac involving Webrecorder packages are vulnerable to XSS through 404 error handling logic under CWE-79: Improper Neutralization of Input During Web Page Generation ('Cross-site Scripting').
Which @webrecorder/wabac versions are affected?
Affected versions include releases prior to 2.23.11, 2.3.17, 0.15.4 across affected packages: @webrecorder/wabac, replaywebpage, @webrecorder/archivewebpage.
What version fixes CVE-2025-58765?
Upgrading to 2.23.11, 2.3.17, 0.15.4 (or the latest patched release for your respective branch) resolves the vulnerability.
Is @webrecorder/wabac affected?
Yes, @webrecorder/wabac is affected in releases prior to 2.23.11. Upgrade your dependency to 2.23.11 or later.
Is replaywebpage affected?
Yes, replaywebpage is affected in releases prior to 2.3.17. Upgrade your dependency to 2.3.17 or later.
What is the CVSS score of CVE-2025-58765?
CVE-2025-58765 has a CVSS v3.1 base score of 7.1 (HIGH) with vector string CVSS:3.1/AV:N/AC:L/PR:N/UI:R/S:C/C:L/I:L/A:L.
What CWE is associated with CVE-2025-58765?
CVE-2025-58765 is classified under CWE-79: Improper Neutralization of Input During Web Page Generation ('Cross-site Scripting') (The product does not neutralize or incorrectly neutralizes user-controllable input before it is placed in output that is used as a web page that is served to other users.).
How can I check npm dependencies for CVE-2025-58765?
Run the dependency tree command: 'npm ls @webrecorder/wabac'. 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-w765-jm6w-4hhj",
  "modified" : "2025-09-10T17:13:45Z",
  "published" : "2025-09-10T17:13:45Z",
  "aliases" : [ "CVE-2025-58765" ],
  "summary" : "Webrecorder packages are vulnerable to XSS through 404 error handling logic",
  "details" : "A Reflected Cross-Site Scripting (XSS) vulnerability exists in the 404 error handling logic of wabac.js v2.23.10 and below. The parameter `requestURL` (derived from the original request target) is directly embedded into an inline `<script>` block without sanitization or escaping.\n\nThis allows an attacker to craft a malicious URL that executes arbitrary JavaScript in the victim’s browser.\n\nThe scope may be limited by CORS policies, depending on the situation in which wabac.js is used.\n\n### Patches\n\nThe vulnerability is fixed in wabac.js v2.23.11.",
  "severity" : [ {
    "type" : "CVSS_V3",
    "score" : "CVSS:3.1/AV:N/AC:L/PR:N/UI:R/S:C/C:L/I:L/A:L"
  } ],
  "affected" : [ {
    "package" : {
      "ecosystem" : "npm",
      "name" : "@webrecorder/wabac"
    },
    "ranges" : [ {
      "type" : "ECOSYSTEM",
      "events" : [ {
        "introduced" : "0"
      }, {
        "fixed" : "2.23.11"
      } ]
    } ]
  }, {
    "package" : {
      "ecosystem" : "npm",
      "name" : "replaywebpage"
    },
    "ranges" : [ {
      "type" : "ECOSYSTEM",
      "events" : [ {
        "introduced" : "0"
      }, {
        "fixed" : "2.3.17"
      } ]
    } ]
  }, {
    "package" : {
      "ecosystem" : "npm",
      "name" : "@webrecorder/archivewebpage"
    },
    "ranges" : [ {
      "type" : "ECOSYSTEM",
      "events" : [ {
        "introduced" : "0"
      }, {
        "fixed" : "0.15.4"
      } ]
    } ]
  } ],
  "references" : [ {
    "type" : "WEB",
    "url" : "https://github.com/webrecorder/wabac.js/security/advisories/GHSA-w765-jm6w-4hhj"
  }, {
    "type" : "ADVISORY",
    "url" : "https://nvd.nist.gov/vuln/detail/CVE-2025-58765"
  }, {
    "type" : "WEB",
    "url" : "https://github.com/webrecorder/archiveweb.page/pull/315"
  }, {
    "type" : "WEB",
    "url" : "https://github.com/webrecorder/replayweb.page/pull/448"
  }, {
    "type" : "WEB",
    "url" : "https://github.com/webrecorder/wabac.js/commit/25feb4a5af69a6b65694426eae67b890be438c4c"
  }, {
    "type" : "WEB",
    "url" : "https://github.com/webrecorder/replayweb.page/releases/tag/v2.3.17"
  }, {
    "type" : "PACKAGE",
    "url" : "https://github.com/webrecorder/wabac.js"
  }, {
    "type" : "WEB",
    "url" : "https://github.com/webrecorder/wabac.js/releases/tag/v2.23.11"
  } ],
  "database_specific" : {
    "cwe_ids" : [ "CWE-79" ],
    "severity" : "HIGH",
    "github_reviewed" : true,
    "github_reviewed_at" : "2025-09-10T17:13:45Z",
    "nvd_published_at" : "2025-09-09T21:15:38Z"
  }
}