Saturday, 29 July 2017

[ CVE-2017-11749 ] FTP Commander 8.02 - Unsafe DLL Loading Vulnerability

1. OVERVIEW

The FTP Commander is vulnerable to Insecure DLL Hijacking
Vulnerability. Similar terms that describe this vulnerability
have been come up with Remote Binary Planting, and Insecure DLL
Loading/Injection/Hijacking/Preloading.

2. PRODUCT DESCRIPTION

FTP Commander is an FTP client for Windows. The program is developed by InternetSoft Corporation. Features include multiple connections, SSH, SSL, scheduler and backup tool, proxy and firewall support, chmod features, and localization for over 20 languages

3. VULNERABILITY DESCRIPTION

The FTP Commander application passes an insufficiently qualified path in
loading an external library when a user launch the application

Affected Library List
---------------------
# dwmapi.dll

4. VERSIONS AFFECTED

8.02 and prior

Tested Platform: Windows 7 x64 (Fresh Windows)

6. IMPACT

This occurs when an application fails to resolve a DLL because the DLL does not exist in the specified path or search directories. If this happens, a malicious Dll with the same name can be placed in the specified path directory leading to remote code execution.


7. SOLUTION

For application developers:
    Require set paths for DLLs in applications

For system administrators:
    Disable write permissions to relative application folders
    Utilize least privilege access to prevent users (and applications) from having too much access to the system

For both groups:
    Microsoft has a great article explaining the DLL-related registry keys and how they can be used to protect applications -
 http://blogs.technet.com/b/srd/archive/2010/08/23/more-information-about-dll-preloading-remote-attack-vector.aspx


8. VENDOR

 InternetSoft Corporation
www.internet-soft.com/ftpcomm.htm

9. CREDIT

This vulnerability was discovered by Ye Yint Min Thu htut, http://pentest.space

10. DISCLOSURE TIME-LINE

07-26-2017: vulnerability discovered
07-26-2017: notified vendor
08-29-2017: vulnerability disclosed

11. REFERENCES
https://support.microsoft.com/en-us/help/2389418/secure-loading-of-libraries-to-prevent-dll-preloading-attacks
https://cwe.mitre.org/data/definitions/427.html