Attacking a binary with seccomp/libc leak/ROP open+read+write - DiceCTF 2023 - pwn/bop

preview_player
Показать описание
CTF Challenge Writeup
Buffer overflow into ROP to leak libc using gets/printf. Then stay within secomp and use open/read/write to print flag

00:00 Intro
00:17 Copy libc from docker container
00:56 Program Review
01:20 Ghidra Review
01:50 SECCOMP
02:21 checksec
02:50 Solution Discussion
05:03 Solution Script
Рекомендации по теме
Комментарии
Автор

DiceCTF was my 2nd CTF ever and I solved .... 0 challenges 😅. I spent a lot of time trying to figure out what to do for bop, but I never imagined it was this involved. How do you even learn this stuff?

imakappa
Автор

I have a newbie question that you might answer (maybe by saying why it doesn't work :D): Couldn't you just call the libc open read and puts functions once you leak the libc base address with rop.call("open", ...) and so on without messing with further rop gadgets?

nopenope