DUCTF5 Yawa [PWN]
This challenge involves exploiting buffer overflow and format string vulnerabilities. The buffer overflow allows us to leverage the format string %s to leak addresses. Additionally, this challenge includes a return-to-libc (ret2libc) attack. Intial Analysis In this challenge we were given 4 different files. yawa (challenge executable) yawa.c (challenge source code) ld-2.35.so (dynamic linker/loader for the GNU C Library version 2.35) libc.so.6 (main shared library for the GNU C Library) When initially received executable, yawa cannot be run due the executable requirements using specific linker and main shared library. Using pwninit (https://github.com/io12/pwninit), the patching process becomes much easier. Now with the patched binary, it can now be run. ...