Longjing Technology BEMS API 1.21 Remote Arbitrary File Download

Title: Longjing Technology BEMS API 1.21 Remote Arbitrary File Download
Advisory ID: ZSL-2021-5657
Type: Local/Remote
Impact: Exposure of System Information, Exposure of Sensitive Information
Risk: (4/5)
Release Date: 28.07.2021
Summary
Battery Energy Management System.
Description
The application suffers from an unauthenticated arbitrary file download vulnerability. Input passed through the fileName parameter through downloads endpoint is not properly verified before being used to download files. This can be exploited to disclose the contents of arbitrary and sensitive files through directory traversal attacks.
Vendor
Longjing Technology - http://www.ljkj2012.com
Affected Version
1.21
Tested On
nginx/1.19.1
Vendor Status
N/A
PoC
longjingbems_fd.txt
Credits
Vulnerability discovered by Gjoko Krstic - <gjoko@zeroscience.mk>
References
[1] https://www.exploit-db.com/exploits/50163
[2] https://packetstormsecurity.com/files/163702
[3] https://cxsecurity.com/issue/WLB-2021070173
[4] https://exchange.xforce.ibmcloud.com/vulnerabilities/206477
Changelog
[28.07.2021] - Initial release
[30.07.2021] - Added reference [1] and [2]
[02.08.2021] - Added reference [3] and [4]
Contact
Zero Science Lab

Web: https://www.zeroscience.mk
e-mail: lab@zeroscience.mk