CVE-2023-2850: Nodebb Unintentional Leakage Of Private Information Vulnerability

MODERATE
Advisory Identifier: GHSA-4qcv-qf38-5j3j
CVSS 4.7
CWE-346 CWE-1385
Published
Advisory Summary

CVE-2023-2850 is a MODERATE (CVSS 4.7) unintentional leakage of private information vulnerability (CWE-346: Origin Validation Error) affecting Nodebb libraries in the npm ecosystem. The issue involves unintentional leakage of private information via cross-origin websocket session hijacking. Remediation is available by upgrading affected packages to version 3.1.3, 2.8.13.

CVE-2023-2850 at a Glance

CVE Identifier CVE-2023-2850
GHSA Identifier GHSA-4qcv-qf38-5j3j
Severity MODERATE
CVSS v3.1 Base Score 4.7
CWE Classification CWE-346: Origin Validation Error
Affected Product Nodebb
Package Ecosystem npm
Published Date
Last Updated

Security Impact

CVSS: 4.7

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:N/A:N).

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 None (I:N)
Availability None (A:N)

How to Fix CVE-2023-2850

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

nodebb fixed: 3.1.3
npm install nodebb@3.1.3
nodebb fixed: 2.8.13
npm install nodebb@2.8.13
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 nodebb

How to Check if You Are Affected

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

npm ls nodebb

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

Note: The npm ls nodebb 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-346: Origin Validation Error, where the product does not properly verify that the source of data or communication is valid. In Nodebb, 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

### Impact Private messages or posts might be leaked to third parties if victim opens the attackers site while browsing nodebb. ### Patches * Patched in v3.1.3 * Backported to v2.x line via v2.8.13 ### Workarounds Users can cherry-pick https://github.com/NodeBB/NodeBB/commit/51096ad2345fb1d1380bec0a447113489ef6c359 if they are on v3.x If you are running v2.x of NodeBB, you can cherry-pick a5d92da9ddac5607ab7f737520a66eaed6d3ddee followed by 62e162cf1e735e42462be1db9b4954b5a69accdf

CVE-2023-2850 Affected Nodebb Versions

2 component(s)
Fixed Versions:
3.1.32.8.13
Product / Package Ecosystem Affected Versions Fixed Version
nodebb
npm
≥ 3.0.0
< 3.1.3
3.1.3
nodebb
npm
< 2.8.13
2.8.13

References

Frequently Asked Questions

What is CVE-2023-2850?
CVE-2023-2850 is a security vulnerability in Nodebb involving Unintentional leakage of private information via cross-origin websocket session hijacking under CWE-346: Origin Validation Error.
Which Nodebb versions are affected?
Affected versions include releases prior to 3.1.3, 2.8.13 across affected packages: nodebb.
What version fixes CVE-2023-2850?
Upgrading to 3.1.3, 2.8.13 (or the latest patched release for your respective branch) resolves the vulnerability.
Is nodebb affected?
Yes, nodebb is affected in releases prior to 3.1.3, 2.8.13. Upgrade your dependency to 3.1.3, 2.8.13 or later.
What is the CVSS score of CVE-2023-2850?
CVE-2023-2850 has a CVSS v3.1 base score of 4.7 (MODERATE) with vector string CVSS:3.1/AV:N/AC:L/PR:N/UI:R/S:C/C:L/I:N/A:N.
What CWE is associated with CVE-2023-2850?
CVE-2023-2850 is classified under CWE-346: Origin Validation Error (The product does not properly verify that the source of data or communication is valid.).
How can I check npm dependencies for CVE-2023-2850?
Run the dependency tree command: 'npm ls nodebb'. 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-4qcv-qf38-5j3j",
  "modified" : "2023-07-25T18:04:28Z",
  "published" : "2023-07-25T18:04:28Z",
  "aliases" : [ "CVE-2023-2850" ],
  "summary" : "Unintentional leakage of private information via cross-origin websocket session hijacking",
  "details" : "### Impact\n\nPrivate messages or posts might be leaked to third parties if victim opens the attackers site while browsing nodebb.\n\n### Patches\n\n* Patched in v3.1.3\n* Backported to v2.x line via v2.8.13\n\n### Workarounds\n\nUsers can cherry-pick https://github.com/NodeBB/NodeBB/commit/51096ad2345fb1d1380bec0a447113489ef6c359 if they are on v3.x\n\nIf you are running v2.x of NodeBB, you can cherry-pick a5d92da9ddac5607ab7f737520a66eaed6d3ddee followed by 62e162cf1e735e42462be1db9b4954b5a69accdf\n",
  "severity" : [ {
    "type" : "CVSS_V3",
    "score" : "CVSS:3.1/AV:N/AC:L/PR:N/UI:R/S:C/C:L/I:N/A:N"
  } ],
  "affected" : [ {
    "package" : {
      "ecosystem" : "npm",
      "name" : "nodebb"
    },
    "ranges" : [ {
      "type" : "ECOSYSTEM",
      "events" : [ {
        "introduced" : "3.0.0"
      }, {
        "fixed" : "3.1.3"
      } ]
    } ]
  }, {
    "package" : {
      "ecosystem" : "npm",
      "name" : "nodebb"
    },
    "ranges" : [ {
      "type" : "ECOSYSTEM",
      "events" : [ {
        "introduced" : "0"
      }, {
        "fixed" : "2.8.13"
      } ]
    } ]
  } ],
  "references" : [ {
    "type" : "WEB",
    "url" : "https://github.com/NodeBB/NodeBB/security/advisories/GHSA-4qcv-qf38-5j3j"
  }, {
    "type" : "ADVISORY",
    "url" : "https://nvd.nist.gov/vuln/detail/CVE-2023-2850"
  }, {
    "type" : "WEB",
    "url" : "https://github.com/NodeBB/NodeBB/commit/51096ad2345fb1d1380bec0a447113489ef6c359"
  }, {
    "type" : "WEB",
    "url" : "https://github.com/NodeBB/NodeBB/commit/62e162cf1e735e42462be1db9b4954b5a69accdf"
  }, {
    "type" : "WEB",
    "url" : "https://github.com/NodeBB/NodeBB/commit/a5d92da9ddac5607ab7f737520a66eaed6d3ddee"
  }, {
    "type" : "PACKAGE",
    "url" : "https://github.com/NodeBB/NodeBB"
  }, {
    "type" : "WEB",
    "url" : "https://github.com/NodeBB/NodeBB/releases/tag/v3.1.3"
  } ],
  "database_specific" : {
    "cwe_ids" : [ "CWE-1385", "CWE-346" ],
    "severity" : "MODERATE",
    "github_reviewed" : true,
    "github_reviewed_at" : "2023-07-25T18:04:28Z",
    "nvd_published_at" : "2023-07-25T12:15:10Z"
  }
}