Advisory

GHSA-w3w8-37jv-2c58

Also known as: CVE-2015-8862

Summary

Cross-Site Scripting in mustache

Details

Versions of mustache prior to 2.2.1 are affected by a cross-site scripting vulnerability when attributes in mustache templates are not quoted.

Example
Template:


Input:
```{ 'foo' : 'test.com onload=alert(1)'}```

Rendered result:
```<a href=test.com onload=alert(1)/>```


## Recommendation

Update to version 2.2.1 or later.
Alternatively, ensure that all attributes in hmustache templates are encapsulated with quotes.

Severity

High Basis: The source's own band: HIGH

Dates

Published
2017-10-24 18:33 UTC
Modified
2023-11-08 03:58 UTC

Affected packages and fixes

mustache

npm · All systems

Affected

  • introduced 0, fixed 2.2.1 (semver)

Fixed versions

2.2.1

Fix

Fix commands are the export's own generic commands. Ojuju never runs them. Check them against your setup first.

Check your own computer: guard packages check

View this record on OSV.dev

Source

Source: GitHub Advisory Database (reviewed advisories) · CC BY 4.0

Sources & licences