CVE-2024-45195: Apache OFBiz Unauthenticated Remote Code Execution (Fixed)
Apache OFBiz before 18.12.16 allows unauthenticated remote code execution because view authorization checks can be bypassed by desynchronising the controller and view map state. An attacker can access admin-only views such as XmlDsDump to dump database contents or execute arbitrary Groovy code.
Published on rapid7.com
Apache OFBiz below 18.12.16 is vulnerable to unauthenticated remote code execution on Linux and Windows. An attacker with no valid credentials can exploit missing view authorization checks in the web application to execute arbitrary code on the server.
The full write-up lives on its author's site
It belongs to its author, so we link to it rather than copy it. The other two tabs are our own rewrites, checked against it.
Not written yet. The AI write-up for this write-up has not been written yet. The Original tab links to the source.
How it worked
Root cause
The application uses different parsing methods for the controller and view map parts of the URL, allowing them to be desynchronised so that an unauthenticated controller is paired with an authenticated view map.
Impact
An unauthenticated attacker could execute arbitrary code on the server or access sensitive data such as password hashes and credit card numbers.
What the attacker needed
No credentials required; Network access to the OFBiz instance
How it was found
- Send a request to an unauthenticated endpoint with a path that includes an authenticated view name, such as /webtools/control/forgotPassword/xmldsdump.
- Include parameters to specify the output file path, filename, and entity names to dump (e.g., UserLogin, CreditCard).
- The server processes the request, writing the dumped data to a file in a web-accessible directory.
- Retrieve the dumped file via a second unauthenticated request to confirm success.
Explained by bugbounty.wiki with AI from the original and checked against quotes from it; it can still be wrong. Read the original before relying on a detail.
Not written yet. The AI write-up for this write-up has not been written yet. The Original tab links to the source.
Apache OFBiz is a business application. It has some admin-only pages that can run code or export data. The software mistakenly lets a visitor reach those pages without logging in by confusing how it works out which page to show. This means an attacker can run commands on the server or steal data.
What is RCE?
Running the attacker's code on the target's servers: through command or code injection, unsafe deserialisation or template injection.