Vulnerabilities in pkg:npm/ssb-db
PACKAGECVE-2020-4045 is a HIGH (CVSS 7.5) information disclosure vulnerability (CWE-200: Exposure of Sensitive Information to an Unauthorized Actor) affecting Ssb db libraries in the npm ecosystem. The issue involves information disclosure in ssb-db. Remediation is available by upgrading affected packages to version 20.0.1.
pkg:npm/ssb-db
Vulnerability advisories affecting package pkg:npm/ssb-db. Select an advisory below to view technical details or fixes.
| Advisory ID | CVE / NVD | Severity | Summary |
|---|---|---|---|
| GHSA-mpgr-2cx9-327h | CVE-2020-4045 | HIGH | Information disclosure in SSB-DB |
CVE-2020-4045 at a Glance
Security Impact
CVSS: 7.5
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:N/A:N).
How to Fix CVE-2020-4045
To remediate this vulnerability, upgrade all affected Ssb db dependencies to a patched release. Both direct and transitive dependencies should be checked, as frameworks or security libraries may pull in vulnerable versions transitively.
npm install ssb-db@20.0.1
Run the following command in your project directory to verify that all resolved dependencies use the patched release:
npm ls ssb-db
How to Check if You Are Affected
To determine whether your Node.js application is affected by CVE-2020-4045, inspect your project dependencies using npm:
npm ls ssb-db
Analyze the terminal output to locate any version of Ssb db in your dependency tree. If any resolved version matches the vulnerable ranges listed in the table below (for example, versions earlier than 20.0.1), your application is affected.
Note: The npm ls ssb-db 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-200: Exposure of Sensitive Information to an Unauthorized Actor, where the product exposes sensitive information to an actor that is not explicitly authorized to have access to that information. In Ssb db, 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
CVE-2020-4045 Affected Ssb db Versions
1 component(s)| Product / Package | Ecosystem | Affected Versions | Fixed Version |
|---|---|---|---|
|
ssb-db
|
npm |
≥ 20.0.0
< 20.0.1
All 1 versions
20.0.0
|
20.0.1
|
References
Frequently Asked Questions
What is CVE-2020-4045?
Which Ssb db versions are affected?
What version fixes CVE-2020-4045?
Is ssb-db affected?
What is the CVSS score of CVE-2020-4045?
What CWE is associated with CVE-2020-4045?
How can I check npm dependencies for CVE-2020-4045?
Machine-readable OSV JSON
OSV v1.5 Schema
{
"schema_version" : "1.4.0",
"id" : "GHSA-mpgr-2cx9-327h",
"modified" : "2021-01-08T20:12:11Z",
"published" : "2020-06-11T21:09:04Z",
"aliases" : [ "CVE-2020-4045" ],
"summary" : "Information disclosure in SSB-DB",
"details" : "### Impact\n_What kind of vulnerability is it? Who is impacted?_\n\nServers running SSB-DB 20.0.0 (which is packaged with SSB-Server 16.0.0) must upgrade immediately.\n\n**There is no evidence that other SSB apps are vulnerable or that this problem has been exploited in the wild.**\n\nThe `get()` method is supposed to only decrypt messages when you explicitly ask it to, but there's a bug where it's decrypting any message that it can. This means that it's returning the decrypted content of private messages, which a malicious peer could use to get access to private data. This only affects peers running SSB-DB@20.0.0 who also have private messages, and is only known to be exploitable if you're also running SSB-OOO (default in SSB-Server), which exposes a thin wrapper around `get()` to anonymous peers.\n\n### Patches\n_Has the problem been patched? What versions should users upgrade to?_\n\nYes, please upgrade to SSB-DB 20.0.1 (or SSB-Server 16.0.1) immediately.\n\n### Workarounds\n_Is there a way for users to fix or remediate the vulnerability without upgrading?_\n\nYou may be able to disable the most obvious attack vector, SSB-OOO, by disabling the plugin, but you should upgrade immediately anyway.\n\n### For more information\n\nIf you have any questions or comments about this advisory, open an issue in [SSB-DB](https://github.com/ssbc/ssb-db/)",
"severity" : [ {
"type" : "CVSS_V3",
"score" : "CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:N/A:N"
} ],
"affected" : [ {
"package" : {
"ecosystem" : "npm",
"name" : "ssb-db"
},
"ranges" : [ {
"type" : "ECOSYSTEM",
"events" : [ {
"introduced" : "20.0.0"
}, {
"fixed" : "20.0.1"
} ]
} ],
"versions" : [ "20.0.0" ]
} ],
"references" : [ {
"type" : "WEB",
"url" : "https://github.com/ssbc/ssb-db/security/advisories/GHSA-mpgr-2cx9-327h"
}, {
"type" : "ADVISORY",
"url" : "https://nvd.nist.gov/vuln/detail/CVE-2020-4045"
}, {
"type" : "WEB",
"url" : "https://github.com/ssbc/ssb-db/commit/43334d0871c9cc6220e0f6d6338499060f7761d4"
} ],
"database_specific" : {
"cwe_ids" : [ "CWE-200" ],
"severity" : "HIGH",
"github_reviewed" : true,
"github_reviewed_at" : "2020-06-11T21:08:42Z",
"nvd_published_at" : null
}
}