8.8high
HashBrown CMS - OS Command Injection in Media Upload Thumbnail Generation
- Severity
- 8.8high CVSS:3.1 by TuranSec
- Exploit likelihood
- 1.87% (higher than 80% of CVEs)
- Published
- Last changed
- Assigned by
- TuranSec
Description
HashBrown CMS through 1.4.6 contains an OS Command Injection vulnerability (CWE-78) in the media upload thumbnail generation routine. Media.generateThumbnail in src/Server/Entity/Resource/Media.js builds a temporary file path as 'thumbnail' + Path.extname(filename) and passes it, unescaped, into a shell command executed via AppService.exec ('convert ' + tempFile + ...).
Affected
| Product or package | Versions | Reported by |
|---|---|---|
| HashBrownCMS hashbrown-cms | up to 1.4.6 | CVE List |
Classification
SSVC (CISA-ADP): exploitation none, automatable no, technical impact total.
What each source says
CVE List
HashBrown CMS through 1.4.6 contains an OS Command Injection vulnerability (CWE-78) in the media upload thumbnail generation routine. Media.generateThumbnail in src/Server/Entity/Resource/Media.js builds a temporary file path as 'thumbnail' + Path.extname(filename) and passes it, unescaped, into a shell command executed via AppService.exec ('convert ' + tempFile + ...).
NVD (es)
HashBrown CMS hasta la versión 1.4.6 contiene una vulnerabilidad de inyección de comandos del sistema operativo (CWE-78) en la rutina de generación de miniaturas de carga de medios. Media.generateThumbnail() en src/Server/Entity/Resource/Media.js construye una ruta de archivo temporal como ’thumbnail’ + Path.extname(filename) y la pasa, sin escapar, a un comando de shell ejecutado a través de AppService.exec() (’convert ’ + tempFile + ...). El filtro de tipo MIME en getMIMEType() (src/Common/utilities.js) trunca la extensión extraída en el primer carácter ’?’, mientras que Path.extname() no lo hace, permitiendo que un nombre de archivo como ’x.jpg?$(command)’ pase la verificación de tipo de imagen mientras sigue inyectando una sustitución de comando de shell en la llamada a exec(). Un usuario autenticado que posee el ámbito de recurso de medios puede lograr la ejecución arbitraria de comandos del sistema operativo en el contexto del proceso de Node.js a través de POST /api/{project}/{environment}/media/new.
References
| https://github.com/HashBrownCMS/hashbrown-cms | third-party-advisory | |
| https://cve.turansec.uz/advisories/TRN-11FC0D88 | third-party-advisory | |
Sources
| Source | Record | Licence |
|---|---|---|
| CVE List | CVE-2026-70374 changed 2026-08-10 | CVE Terms of Use |
| NVD | CVE-2026-70374 changed 2026-10-24 | Public domain |