FreeBSD VuXML: Documenting security issues in FreeBSD and the FreeBSD Ports Collection

libssh -- Unsanitized location in scp could lead to unwanted command execution

Affected packages
0.4.0 <= libssh < 0.8.8
0.9.0 <= libssh < 0.9.3

Details

VuXML ID 1e7fa41b-f6ca-4fe8-bd46-0e176b42b14f
Discovery 2019-11-14
Entry 2020-02-02

The libssh team reports:

In an environment where a user is only allowed to copy files and not to execute applications, it would be possible to pass a location which contains commands to be executed in additon.

When the libssh SCP client connects to a server, the scp command, which includes a user-provided path, is executed on the server-side. In case the library is used in a way where users can influence the third parameter of ssh_scp_new(), it would become possible for an attacker to inject arbitrary commands, leading to a compromise of the remote target.

References

CVE Name CVE-2019-14889
URL https://nvd.nist.gov/vuln/detail/CVE-2019-14889
URL https://www.libssh.org/security/advisories/CVE-2019-14889.txt