7.7high
Remote code execution and Reflected cross site scripting in haml-coffee
- Severity
- 7.7high CVSS:3.1 by GitHub_M
- Exploit likelihood
- 0.70% (higher than 54% of CVEs; EPSS, by FIRST)
- Published
- Last changed
- Assigned by
- GitHub_M
- Also known as
- GHSA-m7mf-vm62-7x3q
Description
haml-coffee is a JavaScript templating solution. haml-coffee mixes pure template data with engine configuration options through the Express render API. More specifically, haml-coffee supports overriding a series of HTML helper functions through its configuration options. A vulnerable application that passes user controlled request objects to the haml-coffee template engine may introduce RCE vulnerabilities. Additionally control over the escapeHtml parameter through template configuration pollution ensures that haml-coffee would not sanitize template inputs that may result in reflected Cross Site Scripting attacks against downstream applications. There is currently no fix for these issues as of the publication of this CVE. The latest version of haml-coffee is currently 1.14.1. For complete details refer to the referenced GHSL-2021-025.
Affected
| Product or package | Versions | Reported by |
|---|---|---|
| netzpirat haml-coffee | <= 1.14.1 | CVE List |
| haml-coffee (npm) | up to 1.14.1 | GitHub Advisory Database |
| haml-coffee_project haml-coffee | up to 1.14.1 | NVD |
All scores
| GitHub_M | 7.7high CVSS:3.1 | CVSS:3.1/AV:N/AC:H/PR:L/UI:R/S:C/C:H/I:H/A:N |
| GitHub | 7.7high CVSS:3.1 | CVSS:3.1/AV:N/AC:H/PR:L/UI:R/S:C/C:H/I:H/A:N |
| NVD | 5.4medium CVSS:3.1 | CVSS:3.1/AV:N/AC:L/PR:L/UI:R/S:C/C:L/I:L/A:N |
| NVD | 3.5low CVSS:2.0 | AV:N/AC:M/Au:S/C:N/I:P/A:N |
Classification
What each source says
CVE List
haml-coffee is a JavaScript templating solution. haml-coffee mixes pure template data with engine configuration options through the Express render API. More specifically, haml-coffee supports overriding a series of HTML helper functions through its configuration options. A vulnerable application that passes user controlled request objects to the haml-coffee template engine may introduce RCE vulnerabilities. Additionally control over the escapeHtml parameter through template configuration pollution ensures that haml-coffee would not sanitize template inputs that may result in reflected Cross Site Scripting attacks against downstream applications. There is currently no fix for these issues as of the publication of this CVE. The latest version of haml-coffee is currently 1.14.1. For complete details refer to the referenced GHSL-2021-025.
NVD (es)
haml-coffee es una solución de creación de plantillas de JavaScript. haml-coffee mezcla datos de plantilla puros con opciones de configuración del motor mediante la API de renderizado Express. Más específicamente, haml-coffee admite la incomprobación de una serie de funciones auxiliares de HTML mediante sus opciones de configuración. Una aplicación vulnerable que pasa objetos de petición controlados por el usuario al motor de plantilla haml-coffee puede introducir vulnerabilidades de RCE. Además, el control sobre el parámetro escapeHtml mediante la contaminación de la configuración de la plantilla asegura que haml-coffee no sanearía las entradas de la plantilla que pueden resultar en ataques de tipo Cross Site Scripting reflejado contra aplicaciones posteriores. Actualmente, no presenta una solución para estos problemas a partir de la publicación de este CVE. La última versión de haml-coffee es actualmente la versión 1.14.1. Para obtener detalles completos, consulte la referencia GHSL-2021-025
References
| https://securitylab.github.com/advisories/GHSL-2021-025-haml-coffee/ | third-party-advisory | |
| https://www.npmjs.com/package/haml-coffee | exploit, product, web | |
| https://nvd.nist.gov/vuln/detail/CVE-2021-32818 | advisory | |
| https://securitylab.github.com/advisories/GHSL-2021-025-haml-coffee | advisory | |
Sources
| Source | Record | Licence |
|---|---|---|
| CVE List | CVE-2021-32818 changed 2024-08-03 | CVE Terms of Use |
| GitHub Advisory Database | GHSA-m7mf-vm62-7x3q changed 2023-11-08 | CC-BY-4.0 |
| NVD | CVE-2021-32818 changed 2026-06-17 | Public domain |