Lookup for vulnerable packages by Package URL.

Purlpkg:npm/hfs@0.57.3-rc2
Typenpm
Namespace
Namehfs
Version0.57.3-rc2
Qualifiers
Subpath
Is_vulnerabletrue
Next_non_vulnerable_version0.57.10
Latest_non_vulnerable_version0.57.10
Affected_by_vulnerabilities
0
url VCID-1n5x-a7b4-mkhg
vulnerability_id VCID-1n5x-a7b4-mkhg
summary
HFS user adding a "web link" in HFS is vulnerable to "target=_blank" exploit
### Summary
When adding a "web link" to the HFS virtual filesystem, the frontend opens it with `target="_blank"` but without the `rel="noopener noreferrer"` attribute. This allows the opened page to use the `window.opener` property to change the location of the original HFS tab.

### Details
While most modern browsers have fixes already implemented for this `target="_blank"` exploit at the browser level, users on outdated browsers remain vulnerable. This means that if an admin of the HFS instance adds a link to an external third-party service (that they believe is safe at the time) and that service they added later becomes compromised, the malicious page could replace the original HFS tab's content with a phishing page. This does not require the admin account itself to be compromised, only that a legitimate linked site turns malicious.

### Impact
Affected users (people using old browsers without the browser level fix) could be misled into entering their HFS credentials or other sensitive information into a fake site controlled by an attacker. This vulnerability is fixed in most modern browsers, but adding `rel="noopener noreferrer"` remains a best practice to protect legacy environments.


### PoC

Firstly, in the HFS admin page, under the filesystem (/~/admin/#/fs) press "Add" then "web link" then set the link to take the user to to an HTML file that exploits this vulnerability, here is an example of a malicious HTML file's code:

```<html>
 <body>
  <script>
    window.opener.location = "https://example.org";
  </script>
<b>Error loading...</b>
 </body>
</html>
```

Now, in the HFS folder you placed this web link in, open HFS and click the web link, if you aren't on a modern browser that fixed this vulnerability on the browser level, then switch back to the HFS tab that opened it, and you should be taken to "https://example.org" if you tried the code I provided, or whatever other page you tried.
references
0
reference_url https://github.com/rejetto/hfs
reference_id
reference_type
scores
0
value 2.9
scoring_system cvssv4
scoring_elements CVSS:4.0/AV:N/AC:L/AT:P/PR:N/UI:N/VC:N/VI:L/VA:N/SC:N/SI:N/SA:N/E:P
1
value LOW
scoring_system generic_textual
scoring_elements
url https://github.com/rejetto/hfs
1
reference_url https://github.com/rejetto/hfs/commit/6531bcd2ab285af88f91831e30d8a03f5b9fe20d
reference_id
reference_type
scores
0
value 2.9
scoring_system cvssv4
scoring_elements CVSS:4.0/AV:N/AC:L/AT:P/PR:N/UI:N/VC:N/VI:L/VA:N/SC:N/SI:N/SA:N/E:P
1
value LOW
scoring_system generic_textual
scoring_elements
url https://github.com/rejetto/hfs/commit/6531bcd2ab285af88f91831e30d8a03f5b9fe20d
2
reference_url https://github.com/rejetto/hfs/security/advisories/GHSA-xcxh-6cv4-q8p8
reference_id
reference_type
scores
0
value LOW
scoring_system cvssv3.1_qr
scoring_elements
1
value 2.9
scoring_system cvssv4
scoring_elements CVSS:4.0/AV:N/AC:L/AT:P/PR:N/UI:N/VC:N/VI:L/VA:N/SC:N/SI:N/SA:N/E:P
2
value LOW
scoring_system generic_textual
scoring_elements
url https://github.com/rejetto/hfs/security/advisories/GHSA-xcxh-6cv4-q8p8
3
reference_url https://github.com/advisories/GHSA-xcxh-6cv4-q8p8
reference_id GHSA-xcxh-6cv4-q8p8
reference_type
scores
0
value LOW
scoring_system cvssv3.1_qr
scoring_elements
url https://github.com/advisories/GHSA-xcxh-6cv4-q8p8
fixed_packages
0
url pkg:npm/hfs@0.57.10
purl pkg:npm/hfs@0.57.10
is_vulnerable false
affected_by_vulnerabilities
resource_url http://public2.vulnerablecode.io/packages/pkg:npm/hfs@0.57.10
aliases GHSA-xcxh-6cv4-q8p8
risk_score 1.4
exploitability 0.5
weighted_severity 2.7
resource_url http://public2.vulnerablecode.io/vulnerabilities/VCID-1n5x-a7b4-mkhg
Fixing_vulnerabilities
Risk_score1.4
Resource_urlhttp://public2.vulnerablecode.io/packages/pkg:npm/hfs@0.57.3-rc2