OS Command Injection in bestzip - #VU46703

 

OS Command Injection in bestzip - #VU46703

Published: September 14, 2020 / Updated: September 15, 2020


Vulnerability identifier: #VU46703
CSH Severity: High
CVSSv4.0: CVSS:4.0/AV:N/AC:L/AT:N/PR:N/UI:N/VC:H/VI:H/VA:H/SC:N/SI:N/SA:N/E:U/U:Amber
CVE-ID: N/A
CWE-ID: CWE-78
Exploitation vector: Remote access
Exploit availability: No public exploit available
Vulnerable software:
bestzip
Software vendor:
Nicehop

Description

The vulnerability allows a remote attacker to execute arbitrary shell commands on the target system.

The vulnerability exists due to sanitize input rules and passes it directly to an exec call on the zip function . attackers to execute arbitrary code in the system as long as the values of destination is user-controlled. This only affects users with a native zip command available. The following examples demonstrate the issue from the CLI and also programatically:

bestzip test.zip 'sourcefile; mkdir folder'
zip({ source: 'sourcefile', destination: './test.zip; mkdir folder' })

Successful exploitation of this vulnerability may result in complete compromise of vulnerable system.


Remediation

Update to version 2.1.7.

External links