일 | 월 | 화 | 수 | 목 | 금 | 토 |
---|---|---|---|---|---|---|
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 |
- anti
- Toddler's Bottle
- Read
- FSB
- shellcode
- TUCTF
- ASM
- rev
- CTF
- practicalmalwareanalysis
- Bug
- writeup
- PMA
- pico
- pwnable
- 2018
- toddler
- Reverse
- pwnable.kr
- picoCTF
- shellcraft
- format
- pwn
- string
- Bottle
- CANARY
- Rookiss
- Leak
- reversing
- BOF
- Today
- Total
목록writeup (7)
제리의 블로그
![](http://i1.daumcdn.net/thumb/C150x150/?fname=https://blog.kakaocdn.net/dn/dWAWkg/btrtk0LygTu/BtdMSJ4S8y755pqOunsOg0/img.png)
하임시큐리티 CTF에 pwnable 의 Warmup 을 풀이해본다. // warmup.c #include #include #include void init() { setvbuf(stdin, NULL, _IONBF, 0); setvbuf(stdout, NULL, _IONBF, 0); setvbuf(stderr, NULL, _IONBF, 0); } void vuln() { char buf[0x30]; memset(buf, 0, 0x30); write(1, "> ", 2); read(0, buf, 0xc0); // Stack Overflow!! } int main(void) { init(); vuln(); exit(0); } vuln 함수를 보면, buf 크기 0x30 만큼 할당한 후 0xc0 만큼 덮어쓰는 ..
요약이 문제는 c 언어 라이브러리의 srand, rand 에 대한 문제로seed 값을 알아낼 수 있다면 풀 수 있습니다. 바이너리를 리버싱해보면현재 시간을 이용하여 seed 를 넣고 있다는 것을 알 수 있으므로같은 seed 값을 넣고 난수 생성을 100번 해주면 되는 문제입니다. writeup evenMoreLucky_exploit# nc 167.99.143.206 65032 Hello, there! What is your name? j3rrry I am glad to know you, j3rrry! Server time: 153761 If you guess the next 100 random numbers I shall give you the flag! What number am I thinking o..
요약이 문제는 c 라이브러리의 rand() 함수의 seed 값을 BOF 를 이용하여 덮어씌우고100개의 rand() 값을 맞추는 문제입니다. 입력받은 name 을 strcpy 로 스택영역에 복사하는데입력 길이 제한이 없기 때문에 overflow 하여 seed 값으로 이용되는 지역변수를 덮어씌워줍니다. 그 후부터는 seed 값을 알게된 셈이므로rand() 값을 100번 인증하면 됩니다. writeup lucky_exploit# nc 167.99.143.206 65031 Hello, there! What is your name? j3rrry I am glad to know you, j3rrry! If you guess the next 100 random numbers I shall give you the f..
passcode - 10 pt요약문제의 지문에서 컴파일의 경고를 무시했다는 정보를 토대로 소스코드를 직접 컴파일을 통해 어떠한 경고가 떴는지 확인한 결과 그 경고는 함수에 전달되는 인자의 자료형에 대한 것이었습니다. 프로그램을 직접 실행해서 passcode1 에 10진수를 넣었을 때 Segmentation fault 발생하는 이유를 알아보면 이를 통해 임의의 주소에 4 bytes 만큼 덮어쓸 수 있다는 것을 알게됩니다. welcome 함수에서 사용했던 스택의 데이터가 login 함수에서도 쓰레기값으로 데이터가 그대로 남기 때문에 지역변수 passcode1 를 공격자가 특정 값(주소)을 넣을 수 있습니다. checksec 로 바이너리의 보호기법을 검사해보니 GOT에 write 권한이 있었고 공격 시나리오를..
horcruxes - 7 pt Voldemort concealed his splitted soul inside 7 horcruxes. Find all horcruxes, and ROP it! author: jiwon choi ssh horcruxes@pwnable.kr -p2222 (pw:guest) horcruxes@ubuntu:~$ ls -l total 20 -rwxr-xr-x 1 root root 12424 Aug 8 07:16 horcruxes -rw-r--r-- 1 root root 131 Aug 8 07:16 readme horcruxes@ubuntu:~$ cat readme connect to port 9032 (nc 0 9032). the 'horcruxes' binary will be e..
blukat - 3 pt Sometimes, pwnable is strange... hint: if this challenge is hard, you are a skilled player. ssh blukat@pwnable.kr -p2222 (pw: guest) blukat@ubuntu:~$ ls -l total 20 -r-xr-sr-x 1 root blukat_pwn 9144 Aug 8 06:44 blukat -rw-r--r-- 1 root root 645 Aug 8 06:43 blukat.c -rw-r----- 1 root blukat_pwn 33 Jan 6 2017 password password 파일의 그룹 권한은 blukat_pwn blukat@ubuntu:~$ cat password cat: ..
dingJMax (106pts)94 Solvers난이도: Easy분야: Reversing I prepared the Rhythm game "dingJMax" for you.This is really hard... Can you get prefect score for flag? dingJMax md5sum: 0a55a302e2da26f2e4cd327f056f8219 목차실행 화면분석gdb_command- 실행 화면 실행해보면 4키 리듬게임으로 note 의 모양은 소문자 o 입니다.그리고 299개의 모든 note 를 PERFECT! 를 해서 max SCORE 1000000점을 얻는게 목표란 것을 알 수가 있습니다. - 분석 76 key = wgetch(stdscr); 77 if ( key == 'f' ) 7..