Synopsis
While researching CVE-2017-6640, Tenable discovered an unauthenticated path traversal vulnerability in Cisco Prime Data Center Network Manager. The vulnerability is present in the XmpFileUploadServlet class in dcnmweb.war. As the name suggests, XmpFileUploadServlet handles file uploads over HTTP. As such, the path traversal can be used to write a file to any location on the server. An unauthenticated remote attacker can achieve remote code execution by uploading a war file that contains a JSP webshell.
Proof of concept:
curl -k -F 'data=@/tmp/webshell.war' "https://172.26.24.15/Upload?svc=upload&maxFileSize=100000&tacCaseID=../../../../Program%20Files/Cisco%20Systems/dcm/jboss-as-7.2.0.Final/standalone/sandeployments"
Cisco reports that this vulnerability also affects Cisco Prime Infrastructure. However, for that case an attacker first needs to be authenticated before they can reach the vulnerability.
Solution
Cisco has released fixes for both Data Center Network Manager and Prime Infrastructure. Read their advisory for patching information.Additional References
https://tools.cisco.com/security/center/content/CiscoSecurityAdvisory/cisco-sa-20180502-prime-uploadDisclosure Timeline
All information within TRA advisories is provided “as is”, without warranty of any kind, including the implied warranties of merchantability and fitness for a particular purpose, and with no guarantee of completeness, accuracy, or timeliness. Individuals and organizations are responsible for assessing the impact of any actual or potential security vulnerability.
Tenable takes product security very seriously. If you believe you have found a vulnerability in one of our products, we ask that you please work with us to quickly resolve it in order to protect customers. Tenable believes in responding quickly to such reports, maintaining communication with researchers, and providing a solution in short order.
For more details on submitting vulnerability information, please see our Vulnerability Reporting Guidelines page.
If you have questions or corrections about this advisory, please email [email protected]