Trustwave and Cybereason Merge to Form Global MDR Powerhouse for Unparalleled Cybersecurity Value. Learn More
Get access to immediate incident response assistance.
Get access to immediate incident response assistance.
Trustwave and Cybereason Merge to Form Global MDR Powerhouse for Unparalleled Cybersecurity Value. Learn More
During a recent penetration test, Trustwave SpiderLabs researchers discovered a weak input validation vulnerability in the CrushFTP application which caused the deletion of all users. CrushFTP is a secure high- speed file transfer server that runs on almost any OS. It handles a wide array of protocols, and security options. It gives the server administrator the ability to customize, monitor, and control every aspect of the server’s operations: https://www.crushftp.com/.
CrushFTP stores details of registered users within the filesystem in the users/MainUsers directory.
The contents of this directory are shown below, with the default users crushadmin, default, and TempAccount, each having their own directory.
Figure 1: MainUsers directory content
Admin users have privileges to create additional accounts on the web interface. While testing for weak input validation, researchers tried various special characters in the username and realized that quotes and periods were not being blocked. As a result, it became possible to create a user named ““.” When this particular user was selected to be deleted the “.” was parsed directly to the filesystem without sanitization and was taken to mean part of the path which resulted in all users being removed.
The below screenshot shows the user manager page on the web interface.
Figure 2: User manager page on the web interface
A new directory containing details for the user ““.” was created on the file system.
Figure 3: New directory details for user “”.”
The user ““.” was selected to be deleted.
Figure 4: Deleting user “”.”
The below log lines show commands sent to the server when the user ““.” was deleted.
SERVER|10/26/2022 01:50:39.523|SETTINGS:users/MainUsers/" delete
SERVER|10/26/2022 01:50:39.532|SETTINGS:users/MainUsers/. Delete
The “.” was parsed directly to the filesystem without sanitization and all folders under MainUsers were deleted.
Figure 5: All folders under MainUsers deleted
On the web interface, researchers saw that the user list was empty.
Figure 6: Empty user list
As a result, users were not able to login.
Figure 7: Failed login
As a part of Trustwave’s Responsible Disclosure policy, we reached out to the vendor to ensure that a patch was released prior to public disclosure. CrushFTP was responsive and easy to work with throughout this process. The vendor fixed this issue in version 10.3.0_44: https://www.crushftp.com/version10_build.html.
Post-authentication vulnerabilities are often overlooked. However, when the post-authentication vulnerability exposes an administrator to attack, these issues deserve a closer look due to the risk associated with a successful attack. Given the right circumstances, a successful exploit can produce disastrous results.
TWSL2023-002: Input validation Vulnerability in CRUSHFTP
Trustwave is a globally recognized cybersecurity leader that reduces cyber risk and fortifies organizations against disruptive and damaging cyber threats. Our comprehensive offensive and defensive cybersecurity portfolio detects what others cannot, responds with greater speed and effectiveness, optimizes client investment, and improves security resilience. Learn more about us.
Copyright © 2024 Trustwave Holdings, Inc. All rights reserved.