The Apache CloudStack project has announced an advisory against CVE-2024-38346 and CVE-2024-39864, both of severity rating ‘important’, explained below.
CVE-2024-38346: Unauthenticated cluster service port leads to remote execution
The CloudStack cluster service runs on unauthenticated port (default 9090) that can be misused to run arbitrary commands on targeted hypervisors and CloudStack management server hosts. Some of these commands were found to have command injection vulnerabilities that can result in arbitrary code execution via agents on the hosts that may run as a privileged user. An attacker that can reach the cluster service on the unauthenticated port (default 9090), can exploit this to perform remote code execution on CloudStack managed hosts and result in complete compromise of the confidentiality, integrity, and availability of CloudStack managed infrastructure.
CVE-2024-39864: Integration API service uses dynamic port when disabled
The CloudStack integration API service allows running its unauthenticated API server (usually on port 8096 when configured and enabled via integration.api.port global setting) for internal portal integrations and for testing purposes. By default, the integration API service port is disabled and is considered disabled when integration.api.port is set to 0 or negative. Due to an improper initialisation logic, the integration API service would listen on a random port when its port value is set to 0 (default value). An attacker that can access the CloudStack management network could scan and find the randomised integration API service port and exploit it to perform unauthorised administrative actions and perform remote code execution on CloudStack managed hosts and result in complete compromise of the confidentiality, integrity, and availability of CloudStack managed infrastructure.
Credit
Both the CVEs are credited to the following reporters from the Apple Services Engineering Security team:
- Adam Pond (finder)
- Terry Thibault (finder)
- Damon Smith (finder)
Affected Versions
- Apache CloudStack 4.0.0 through 4.18.2.0
- Apache CloudStack 4.19.0.0 through 4.19.0.1
Resolution
ShapeBlue, along with the Apache CloudStack community have released security releases 4.18.2.1 and 4.19.0.2 to address the CVEs listed above. Users are recommended to upgrade their CloudStack installations to version 4.18.2.1, 4.19.0.2 or later, which addresses these issues.
Please refer to https://www.shapeblue.com/cloudstack-packages/ for usage of ShapeBlue provided 4.18-based and 4.19-based LTS security patch releases. To apply these patches, use the ShapeBlue CloudStack 4.18 or 4.19 repositories to upgrade packages on the management server hosts and KVM hosts.
We recommend the following, especially to users who aren’t able to upgrade:
- Restrict the network access to the cluster service port (default 9090) on a CloudStack management server host to only its peer CloudStack management server hosts.
- Restrict the network access on the CloudStack management server hosts to only essential ports.
Further information
For ShapeBlue support customers, please get in touch with the support team for further information. For other CloudStack users, please use the community mailing lists.
Rohit Yadav oversees the Software Engineering function at ShapeBlue, providing leadership and mentorship to our ever-growing Engineering Team. He has been a PMC member of the project since 2015. Rohit is the author & maintainer of the CloudStack CloudMonkey project and has been instrumental in the development of many of CloudStack’s flagship features. Rohit regularly speaks at events, focussing on developer access to the project, and has also mentored Google Summer of Code students.