System hacking training
-
[Toddler's Bottle] blukat write upSystem hacking training/pwnable.kr 2018. 11. 15. 23:34
오랜만에 머리도 식힐겸 pwnable.kr toddler 문제를 잡았습니다. 요로쿵 생긴 귀여운 친구에용 Sometimes, pwnable is strange... hint: if this challenge is hard, you are a skilled player. ssh blukat@pwnable.kr -p2222 (pw: guest) 많이 쉬운 문제였습니다. 어렵게 생각해서 문제지...ㅎ blukat@ubuntu:~$ cat blukat.c #include #include #include #include char flag[100]; char password[100]; char* key = "3\rG[S/%\x1c\x1d#0?\rIS\x0f\x1c\x1d\x18;,4\x1b\x00\x1bp;5\x0..
-
LOB All Clear!System hacking training/Hackerschool LOB 2018. 10. 4. 14:56
드디어 미루고 미루던 LOB를 올클 하였다. login: death_knight Password: Last login: Mon Apr 23 00:33:26 from 192.168.0.1 [death_knight@localhost death_knight]$ ls dropped_item.txt [death_knight@localhost death_knight]$ cat dropped_item.txt You're so great! This is a token to the next gate. ,. ,' `. ,' __ `. ,'.-'____`-.`. ,'_.-'' ``-._`. ,',' /\ `.`. ,' /.._ O / \ O _.,\ `. ,'/ / \ ``-;.--.:-'' / \ \`. ,' : : \ ..
-
LEVEL 20 death_knight write-upSystem hacking training/Hackerschool LOB 2018. 10. 4. 14:56
xavius -> death_knight [xavius@localhost xavius]$ cat death_knight.c /* The Lord of the BOF : The Fellowship of the BOF - dark knight - remote BOF */ #include #include #include #include #include #include #include #include #include main() { char buffer[40]; int server_fd, client_fd; struct sockaddr_in server_addr; struct sockaddr_in client_addr; int sin_size; if((server_fd = socket(AF_INET, SOCK_..
-
[Exploit tutorial] Corelan part 1 : Stack Based OverflowsSystem hacking training/Windows 2018. 10. 3. 10:15
윈도우 Exploit을 공부하던 중 Corelan 팀에서 작성한 문서를 발견했다. 이 글은 Corelan 팀의 문서를 토대로 작성하였다. Easy RM to MP3 Converter에 존재하는 취약점을 예로 exploit을 작성해본다. 해당 취약점은 .m3u 파일을 만든 후 파일을 로드하는 것으로 공격이 가능하다. (스택 기반 오버플로우) [구성환경] OS : Windows XP sp 3 (ENG) Language : python 2.7 Target : Easy RM to MP3 Converter [exploit db] CVE-2009-1330 : https://www.exploit-db.com/exploits/10602/ ETC(N/A) : https://goo.gl/Vc3kFF Ref : https:..
-
LEVEL 19 xavius write-upSystem hacking training/Hackerschool LOB 2018. 8. 12. 18:47
nightmare -> xavius 풀이를 하였습니다. [nightmare@localhost nightmare]$ cat xavius.c /* The Lord of the BOF : The Fellowship of the BOF - xavius - arg */ #include #include #include main() { char buffer[40]; char *ret_addr; // overflow! fgets(buffer, 256, stdin); printf("%s\n", buffer); if(*(buffer+47) == '\xbf') { printf("stack retbayed you!\n"); exit(0); } if(*(buffer+47) == '\x08') { printf("binary im..
-
[Toddler's Bottle] lotto write upSystem hacking training/pwnable.kr 2018. 8. 2. 02:55
toddler lotto 문제를 풀었습니다. 조금 삽질을 했는데 허탈하네요....ㅋㅋㅋ 2pt 문제이고, 문제 보시죠. Mommy! I made a lotto program for my homework. do you want to play? ssh lotto@pwnable.kr -p2222 (pw:guest) 별로 내용이 없어서 ssh연결하여 바로 c코드를 확인해보면 아래와 같이 나옵니다. lotto@ubuntu:~$ cat lotto.c #include #include #include #include unsigned char submit[6]; void play(){ int i; printf("Submit your 6 lotto bytes : "); fflush(stdout); int r; r = re..
-
[Toddler's Bottle] blackjack write upSystem hacking training/pwnable.kr 2018. 7. 31. 21:52
오늘을 pwnable.kr 의 blackjack - 1pt 문제를 풀이하였습니다. 문제 pt는 1pt 인데 소스코드의 양을 보고 조금 놀랐습니다. Hey! check out this C implementation of blackjack game! I found it online * http://cboard.cprogramming.com/c-programming/114023-simple-blackjack-program.html I like to give my flags to millionares. how much money you got? Running at : nc pwnable.kr 9009 flag는 백만장자가 되면 준다고 하네요. 사실 이 부분을 보지 않고 취약한 부분을 찾기 위해서 무작정 소스코드..
-
[Toddler's Bottle] cmd1 write upSystem hacking training/pwnable.kr 2018. 7. 27. 20:09
cmd1을 풀이하였습니다. Mommy! what is PATH environment in Linux? ssh cmd1@pwnable.kr -p2222 (pw:guest) 리눅스에서 환경변수에 관한 문제인듯 합니다. ssh 접속후 ls 로 파일명을 보면 cmd.c 파일이 있는데 아래와 같습니다. cmd1@ubuntu:~$ cat cmd1.c #include #include int filter(char* cmd){ int r=0; r += strstr(cmd, "flag")!=0; r += strstr(cmd, "sh")!=0; r += strstr(cmd, "tmp")!=0; return r; } int main(int argc, char* argv[], char** envp){ putenv("PATH=/..