[HITCON] LAB12 포스팅 썸네일 이미지

War Games/HITCON Training

[HITCON] LAB12

문제소스 #include #include #include #include #include #include #include #include #define TIMEOUT 60 struct flower{ int vaild ; char *name ; char color[24] ; }; struct flower* flowerlist[100] ; unsigned int flowercount = 0 ; void menu(){ puts(""); puts("☆ ☆ ☆ ☆ ☆ ☆ ☆ ☆ ☆ ☆ ☆ ☆ ☆ ☆ ☆ ☆ ☆ ☆ "); puts("☆ Baby Secret Garden ☆ "); puts("☆ ☆ ☆ ☆ ☆ ☆ ☆ ☆ ☆ ☆ ☆ ☆ ☆ ☆ ☆ ☆ ☆ ☆ "); puts(""); puts(" 1 . Raise a f..

2021.05.07 게시됨

[HITCON] LAB6 포스팅 썸네일 이미지

War Games/HITCON Training

[HITCON] LAB6

문제 소스 #include int count = 1337 ; int main(){ if(count != 1337) _exit(1); count++; char buf[40]; setvbuf(stdout,0,2,0); puts("Try your best :"); read(0,buf,64); return ; } 보호기법 gdb-peda$ checksec CANARY : disabled FORTIFY : disabled NX : ENABLED PIE : disabled RELRO : FULL 문제 분석 및 페이로드 1. ROP를 한번에 진행하려고 하니 길이가 부족하다. -->ret까지 거리는 44인데 입력값을 64만큼 받으면 남은건 20이기 때문 2. 이것을 해결하기 위해 Stack Pivoting(Fake E..

2021.05.05 게시됨

[HITCON] LAB5 포스팅 썸네일 이미지

War Games/HITCON Training

[HITCON] LAB5

문제 소스 #include int main(){ char buf[20]; puts("ROP is easy is'nt it ?"); printf("Your input :"); fflush(stdout); read(0,buf,100); } 보호기법 gdb-peda$ checksec CANARY : disabled FORTIFY : disabled NX : ENABLED PIE : disabled RELRO : Partial 문제 분석 및 페이로드 ROP인데 libc가 주어지지 않아 file ./simplerop로 static linked를 확인함 static linked일 때 쓸 수 있는 2가지 방법 1. syscall을 이용해 exploit 2. mprotect 함수를 이용해 exploit 난 첫번째 방법..

2021.05.05 게시됨