분류 전체보기(64)
-
[CTF write up] WACon CTF 2022 qual - Yalkp : Kernel mmap handler exploitation
#include // 리눅스 디바이스 관련 헤더파일을 포함 #include // 파일 시스템 관련 헤더파일을 포함 #include // 커널 관련 헤더파일을 포함 #include // 연결 리스트 관련 헤더파일을 포함 #include // 모듈 관련 헤더파일을 포함 #include // 뮤텍스 관련 헤더파일을 포함 #include // 난수 관련 헤더파일을 포함 #include // 슬랩 할당자 관련 헤더파일을 포함 #include // 사용자 공간 접근 관련 헤더파일을 포함 #include // 메모리 관리 관련 헤더파일을 포함 #define DEVICE_NAME "chall" // 디바이스 이름을 "chall"로 설정 #define CLASS_NAME "chall" // 클래스 이름을 "chall"로..
2023.05.16 -
[CTF write up] m0lecon CTF 2023 - NoRegVM : FSB VM exploit
취약점은 여러가지인데 전부 이런저런 이유로 익스하기가 힘들다. fmt 문자열이 덮히는 걸 이용해서 FSB를 이용해 Exploit 하였다. There are many vulnerabilities, but all of them are difficult to exploit for one reason or another. Exploited using FSB by using that the fmt string can be overwritten. from pwn import * pay = p32(7) + p32(0) + p32((464+8)) #popin pay += p32(8) + p32(464) + p32(8) #popout pay += p32(0xa) + p32(1) #write pay += p32(5) + ..
2023.05.14 -
[CTF write up] Ricerca CTF 2023 - Challenges : I want to study crypto~
Pwnable 빼고 쉬운 문제 몇개를 풀어보았다. 처음으로 풀어보는 Crypto인 Rotated Secret analysis는 꽤 재밌었고, Web에서는 딱히 적당히 재밌는 문제가 없었다. 리버싱은 warm-up 문제를 빼고는 최소 7솔브부터 시작이라 딱히 건드릴 수 있는게 없었다. welcome RicSec{do_U_know_wh4t_Ricerca_means_btw?} crackme 그냥 디컴파일하면 나온다. RicSec{U_R_h1y0k0_cr4ck3r!} Reveolving Latters 반대로 하면 나온다. LOWER_ALPHABET = "abcdefghijklmnopqrstuvwxyz" def decrypt(secret, key): assert len(secret) > l*3) - ((n >> ..
2023.04.26 -
[CTF write up] LINE CTF 2023 - Hackatris : ncusre.h Tetris pwn
Dice CTF 2023의 zelda와 마찬가지로 ncurse.h 라이브러리로 제작된 테트리스 게임이다. zelda 처럼 ncusre.h FSOP Exploit이 필요한 문제는 아니었고, 단순 버퍼오버플로우 취약점이었지만 ncurse.h 라이브러리로 짜여진 프로그램들 특유의 괴상한 인풋 / 아웃풋 때문에 고생했다. Like zelda in Dice CTF 2023, it is a Tetris game made with the ncurse.h library. It was not a problem that required ncusre.h FSOP Exploit like zelda, it was a simple buffer overflow vulnerability, but I suffered from stra..
2023.03.26 -
[CTF write up] b01lers CTF 2023 - Transcendental : It is a misc not pwn :(
__int64 __fastcall main(int a1, char **a2, char **a3) { char op; // al char i; // dl int idx; // eax double reg[11]; // [rsp+0h] [rbp-78h] BYREF unsigned __int64 v8; // [rsp+58h] [rbp-20h] v8 = __readfsqword(0x28u); puts( "==============================================================\n" "== B01lers Calculator - Transcendental Figures edition 2023 ==\n" "=========================================..
2023.03.20 -
[CTF write up] WACon CTF 2022 Final - islands : Easy matrix multiplication rev
리버싱 공부하려고 처음으로 제대로 푼 리버싱 문제다. ida로 까보면 함수가 매우 여러게 있고 함수당 어셈블리가 들어있다. 별로 길지 않아서 하나씩 확인해서 로직을 분석하면 된다. array1 = [246, 0, 58, 0, 217, 0, 173, 0, 210, 0, 224, 0, 7, 0, 116, 0, 199, 0, 18, 0, 117, 0, 160, 0, 27, 0, 191, 0, 158, 0, 238, 0, 243, 0, 211, 0, 116, 0, 147, 0, 195, 0, 39, 0, 185, 0, 154, 0, 181, 0, 215, 0, 33, 0, 184, 0, 231, 0, 42, 0, 78, 0, 65, 0, 137, 0, 188, 0, 52, 0, 136, 0, 154, 0, 23..
2023.03.11