Compfest 12 2020 CTF quals
Gambling Problem 2
Description
dek depe menemukan service judi onlen dari forum redacted. Karena service judi online ini baru buka, pengguna diberikan uang untuk memulai karir perjudian. Setelah diberi bin file lewat orang dalem, dek depe menyadari ternyata terdapat bug mematikan dalam program tersebut. Bantulah dek depe memanfaatkan exploit tersebut!
nc 128.199.157.172 25880
Solve
to solve this challenge we need to have money at least 0xdeadbeef or 3735928559 in decimal. we can
get more money on gameTime()
function.
to get more money, we have to place our bet on gameTime()
function if we can guess a random number
we can get 5 times from our stake, there is also format string bug on input bet
but I prefer to use another bug, which can easy to exploit lol.
there is an integer overflow in -5 * taruhan
we can still increase our money even we guess the wrong number.
my exploit:
FLAG: COMPFEST12{laptop_pembuat_soalnya_BSOD_so_this_is_Zafirr_again_lol_39cbc5}
Binary Exploitation is Ez
Description
Take a break, here’s an easy problem
nc 128.199.157.172 23170
Solve
this is an easy challenge, there is buffer overflow in edit_mem()
.
and my_print()
is stored on the heap that close to our input
in print_meme()
function, my_print()
is being called to print our
content from heap
so, we can use buffer overflow in edit_mem()
to overwrite my_print()
with EZ_WIN()
function
and then call print_mem()
, so that we can get a shell
my exploit:
FLAG: COMPFEST12{C_i_told_u_its_ez_loooooooool_257505}
Sandbox King
Description
You have to get a shell. The seccomp is easy to bypass right?
nc 128.199.104.41 25171
Solve
according to the pseudocode
we can just send a shellcode to get a shell.
my exploit:
FLAG: COMPFEST12{C0nGr4TTSSS_U_r_D_SssssssssAnd60X_K111ng9g99_1c7dbf}