Vulnerabilities in pkg:npm/@hapi/boom
PACKAGEGHSA-2ggq-vfcp-gwhj is a MODERATE (CVSS 6.5) cross-site scripting vulnerability (CWE-79: Improper Neutralization of Input During Web Page Generation ('Cross-site Scripting')) affecting @hapi/boom libraries in the npm ecosystem. The issue involves cross-site scripting in @hapi/boom. Remediation is available by upgrading affected packages to version 0.3.8.
pkg:npm/@hapi/boom
Vulnerability advisories affecting package pkg:npm/@hapi/boom. Select an advisory below to view technical details or fixes.
| Advisory ID | CVE / NVD | Severity | Summary |
|---|---|---|---|
| GHSA-2ggq-vfcp-gwhj | - | MODERATE | Cross-Site Scripting in @hapi/boom |
GHSA-2ggq-vfcp-gwhj at a Glance
Security Impact
CVSS: 6.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:R/S:U/C:H/I:N/A:N).
How to Fix GHSA-2ggq-vfcp-gwhj
To remediate this vulnerability, upgrade all affected @hapi/boom 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 @hapi/boom@0.3.8
Run the following command in your project directory to verify that all resolved dependencies use the patched release:
npm ls @hapi/boom
How to Check if You Are Affected
To determine whether your Node.js application is affected by GHSA-2ggq-vfcp-gwhj, inspect your project dependencies using npm:
npm ls @hapi/boom
Analyze the terminal output to locate any version of @hapi/boom in your dependency tree. If any resolved version matches the vulnerable ranges listed in the table below (for example, versions earlier than 0.3.8), your application is affected.
Note: The npm ls @hapi/boom 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 @hapi/boom, 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
GHSA-2ggq-vfcp-gwhj Affected @hapi/boom Versions
1 component(s)| Product / Package | Ecosystem | Affected Versions | Fixed Version |
|---|---|---|---|
|
@hapi/boom
|
npm |
< 0.3.8
|
0.3.8
|
References
Frequently Asked Questions
What is GHSA-2ggq-vfcp-gwhj?
Which @hapi/boom versions are affected?
What version fixes GHSA-2ggq-vfcp-gwhj?
Is @hapi/boom affected?
What is the CVSS score of GHSA-2ggq-vfcp-gwhj?
What CWE is associated with GHSA-2ggq-vfcp-gwhj?
How can I check npm dependencies for GHSA-2ggq-vfcp-gwhj?
Machine-readable OSV JSON
OSV v1.5 Schema
{
"schema_version" : "1.4.0",
"id" : "GHSA-2ggq-vfcp-gwhj",
"modified" : "2023-10-02T18:43:16Z",
"published" : "2020-09-04T17:33:53Z",
"aliases" : [ ],
"summary" : "Cross-Site Scripting in @hapi/boom",
"details" : "Versions of `@hapi/boom` prior to 0.3.8 are vulnerable to Cross-Site Scripting (XSS). The package fails to properly escape error messages, which may allow attackers to execute arbitrary JavaScript in a victim's browser.\n\n\n## Recommendation\n\nUpgrade to version 0.3.8 or later.",
"severity" : [ {
"type" : "CVSS_V3",
"score" : "CVSS:3.1/AV:N/AC:L/PR:N/UI:R/S:U/C:H/I:N/A:N"
} ],
"affected" : [ {
"package" : {
"ecosystem" : "npm",
"name" : "@hapi/boom"
},
"ranges" : [ {
"type" : "ECOSYSTEM",
"events" : [ {
"introduced" : "0"
}, {
"fixed" : "0.3.8"
} ]
} ]
} ],
"references" : [ {
"type" : "WEB",
"url" : "https://github.com/hapijs/boom/commit/0f8640bdba65aec6e6799bfc16ff5753150bfcaf"
}, {
"type" : "PACKAGE",
"url" : "https://github.com/hapijs/boom"
}, {
"type" : "WEB",
"url" : "https://snyk.io/vuln/SNYK-JS-HAPIBOOM-541183"
} ],
"database_specific" : {
"cwe_ids" : [ "CWE-79" ],
"severity" : "MODERATE",
"github_reviewed" : true,
"github_reviewed_at" : "2020-08-31T19:00:02Z",
"nvd_published_at" : null
}
}