CVE-2019-10787 OS Command Injection in im-resize
Remote attackers can execute arbitrary commands via the unsanitized exec argument in the im-resize library.
- Exploited in the wild
- Not known
- Login needed
- Not needed
- Attackable
- Over the internet
- Victim action needed
- Not needed
- Fix
- None listed
What is CVE-2019-10787?
CVE-2019-10787 is a critical command injection vulnerability in im-resize, published on 4 Feb 2020. An attacker can exploit it over the internet without logging in, with no action from the victim.
Official description
im-resize through 2.3.2 allows remote attackers to execute arbitrary commands via the "exec" argument. The cmd argument used within index.js, can be controlled by user without any sanitization.
Weakness: CWE-78
Which versions are affected by CVE-2019-10787?
2 open source packages ship an affected version, including im-resize. It affects 1 product.
| Package | Affected | Fixed in |
|---|---|---|
im-resize npm | All versions to 2.3.2 | None |
im-resize npm | All versions to 2.3.2 | None |
Products include Dnt Im-Resize.
How do I fix CVE-2019-10787?
No fix has been published for CVE-2019-10787 yet. Limit exposure of the affected software until one is available.
Upgrade, and pass arguments to programs as a list instead of through a shell. More about Command injection.
Is CVE-2019-10787 being exploited?
There is no known exploitation of CVE-2019-10787 in the wild and no public exploit code.
Sources
Also known as GHSA-r9vm-rhmf-7hxx, SNYK-JS-IMRESIZE-544183.