7.2
CVSSv3

CVE-2022-24734

Published: 09/03/2022 Updated: 30/09/2022
CVSS v2 Base Score: 6.5 | Impact Score: 6.4 | Exploitability Score: 8
CVSS v3 Base Score: 7.2 | Impact Score: 5.9 | Exploitability Score: 1.2
VMScore: 691
Vector: AV:N/AC:L/Au:S/C:P/I:P/A:P

Vulnerability Summary

This vulnerability allows remote malicious users to execute arbitrary code on affected installations of MyBB. Authentication is required to exploit this vulnerability. The specific flaw exists within the Control Panel. The issue results from the lack of proper validation of a user-supplied string before using it to construct server-side code. An attacker can leverage this vulnerability to execute code in the context of the www-data user.

Vulnerability Trend

Vulnerable Product Search on Vulmon Subscribe to Product

mybb mybb

Exploits

MyBB version 1829 suffers from a remote code execution vulnerability ...
This Metasploit module exploits an improper input validation vulnerability in MyBB versions prior to 1830 to execute arbitrary code in the context of the user running the application The MyBB Admin Control setting page calls the PHP eval function with unsanitized user input The exploit adds a new setting, injecting the payload in the vulnerable ...
This exploit module leverages an improper input validation vulnerability in MyBB prior to `1830` to execute arbitrary code in the context of the user running the application MyBB Admin Control setting page calls PHP `eval` function with an unsanitized user input The exploit adds a new setting, injecting ...

Metasploit Modules

MyBB Admin Control Code Injection RCE

This exploit module leverages an improper input validation vulnerability in MyBB prior to `1.8.30` to execute arbitrary code in the context of the user running the application. MyBB Admin Control setting page calls PHP `eval` function with an unsanitized user input. The exploit adds a new setting, injecting the payload in the vulnerable field, and triggers its execution with a second request. Finally, it takes care of cleaning up and removes the setting. Note that authentication is required for this exploit to work and the account must have rights to add or update settings (typically, myBB administrator role).

msf > use exploit/multi/http/mybb_rce_cve_2022_24734
msf exploit(mybb_rce_cve_2022_24734) > show targets
    ...targets...
msf exploit(mybb_rce_cve_2022_24734) > set TARGET < target-id >
msf exploit(mybb_rce_cve_2022_24734) > show options
    ...show and set options...
msf exploit(mybb_rce_cve_2022_24734) > exploit

Github Repositories

CVE-2022-24734 PoC

CVE-2022-24734 PoC An RCE can be obtained on MyBB's Admin CP in Configuration -&gt; Add New Setting The user must have a rights to add or update setting This is tested on MyBB 1829

MyBB 1.8.29 - Remote Code Execution

mybb-CVE-2022-24734 MyBB 1829 - Remote Code Execution git clone githubcom/lavclash75/mybb-CVE-2022-24734git cd "mybb-CVE-2022-24734" docker-compose down docker system prune -a docker rm -f $(docker ps -a -q) docker volume rm $(docker volume ls -q) docker-compose up -d