분류 전체보기

    11월 초에 쓰는 일기.

    자체평가 : ★★★★☆ 일단 최근에 제일 짜증나는게 google adsense 승인이 안됨. 다른 이유도 아니고 사이트가 다운되었거나 사용할 수 없음 이라고 뜬다. 별짓을 다 해도 안됨 ㅋㅋㅋㅋㅋ 한번 해보고 싶었는데... 대충 포기하자 ㅋ Root me 문제는 잘 도전 중이긴 한데, 또 다시 특정 문제에서 멈췄닼ㅋㅋ 이건 어찌 풀어야될지 사실 감도 안잡힘... 다른 문제로 바꿔서 계속 도전하자 우연히 살짝 도전하게된 중부 CTF. 주말 약속으로 인해 마지막 한문제는 풀다 말았지만 시나리오는 작성된 상태였기에 pwnable all clear가 가능했다고 판단했다. 사실 문제가 너~~~~무 쉬웠기에 마지막 문제를 제외하고 30분컷이었다. all clear 수준이었기에 자신감이 상승함과 동시에 너무 쉬웠기에..

    [App system] ELF x64 - Stack buffer overflow - advanced

    1. intro 2. code 및 분석 2.1. code #include #include /* gcc -o ch34 ch34.c -fno-stack-protector -Wl,-z,relro,-z,now,-z,noexecstack -static */ int main(int argc, char **argv){ char buffer[256]; int len, i; gets(buffer); len = strlen(buffer); printf("Hex result: "); for (i=0; i pwnlib.shellcraft.amd64 — Shellcode for AMD64 — pwntools 2.2.1 documentation Shellcraft module containing generic Intel x86_..

    [App system] ELF x86 - Stack buffer overflow basic 5

    1. intro 2. code 및 분석 2.1. code #include #include #include #include #include #include #define BUFFER 512 struct Init { char username[128]; uid_t uid; pid_t pid; }; void cpstr(char *dst, const char *src) { for(; *src; src++, dst++) { *dst = *src; } *dst = 0; } void chomp(char *buff) { for(; *buff; buff++) { if(*buff == '\n' || *buff == '\r' || *buff == '\t') { *buff = 0; break; } } } struct Init ..

    [App-system] ELF x86 - Stack buffer and integer overflow

    1. intro 2. code 및 분석 2.1. code #include #include #include #include #include #define BUFFER 128 void read_data(char *data, int fd, int size) { while(read(fd, data, 1) == 1 && *data && size) { size--; data++; } } void read_file(int fd) { char path[BUFFER+1] = {0}; int size; if(read(fd, &size, sizeof(int)) != sizeof(int)) { printf("[-] File too short.\n"); exit(0); } if(size >= BUFFER) { printf("[..

    [App-system] ELF x86 - Stack buffer overflow - C++ vtables

    1. intro 2. code 및 분석 2.1. code #include #include #include #include #include class formatter { public : virtual int RTTI( ) =0 ; virtual void displayName( ) =0 ; virtual void format( const char * ptr ) =0 ; }; class UpperFormatter: public formatter { public : virtual int RTTI( ) { return 1; }; virtual void displayName( ) { printf ("UpperFormatter"); } virtual void format( const char * ptr ) { co..

    10월의 막바지에 쓰는 일기.

    자체평가 : ★★★★☆ 카카오 화재 사건으로 블로그가 거의 죽어있었다. 글을 제대로 못쓰니 의욕도 살짝 사라졌었... 무엇보다 회사에서 공부하는게 살짝 눈치 보이기 시작했다 ㅋㅋㅋ 지금은 거의 복구 됐으니 다행이긴 하지만, tistory가 backup을 지원하지 않기에 대비는 해둬야겠다. python으로 backup 코드를 짜긴 했지만, 이미지 저장 부분을 추가해야한다. 다만... 복구되었기에 귀찮아서 안만들 것 같긴하다.... ㅋ 목표는 생각했던대로 잘 달성하고 있다. 다만, exploit education Fusion의 경우 풀다가 말았었다;;; 그래서 목표에서 일단 삭제하였고, 연말까지 fusion 문제를 풀까 하다가 공부 환경 상 remote 접속이 안되는 경우가 많으니 내년 목표로 변경해서 틈틈..

    [Phoenix] Final two

    1. intro 2. code 및 분석 2.1. C code /* * phoenix/final-two, by https://exploit.education * * This level is linked against ftp://gee.cs.oswego.edu/pub/misc/malloc.c * version 2.7.2, with a SHA1 sum of 407329d164e4989b59b9a828760acb720dc5c7db * * Can you get a shell via heap corruption? * * A man drives train for a living in Bulgaria. He absolutely loved his job, * and it had been his dream job ever..

    [Phoenix] Final zero

    1. intro 2. code 및 분석 2.1. C code /* * phoenix/final-zero, by https://exploit.education * * The aim is to change the contents of the changeme variable. * * A woman has twins and gives them up for adoption. * * One of them goes to a family in Egypt and is named Amal. The other goes to a * family in Spain. They name him Juan. * * Years later, Juan sends a picture of himself to his birth mother. Up..

    [Phoenix] Net two

    1. intro 2. code 및 분석 2.1. C code /* * phoenix/net-two, by https://exploit.education * * Shout out to anyone who doesn't know what the opposite of in is. * */ #include #include #include #include #include #include #include #define BANNER \ "Welcome to " LEVELNAME ", brought to you by https://exploit.education" int main(int argc, char **argv) { int i; unsigned long quad[sizeof(long)], result, want..

    [Phoenix] Net one

    1. intro 2. code 및 분석 2.1. C code /* * phoenix/net-one, by https://exploit.education * * Why aren't octal jokes funny? * Because 7 10 11 */ #include #include #include #include #include #include #include #include #define BANNER \ "Welcome to " LEVELNAME ", brought to you by https://exploit.education" int main(int argc, char **argv) { uint32_t i; char buf[12], fub[12], *q; setvbuf(stdout, NULL, _I..