Codefest CTF 2018 - Write-ups - Part 2

Information#

CTF#

  • Name : Codefest CTF 2018
  • Website : hackerrank.com
  • Type : Online
  • Format : Jeopardy
  • CTF Time : link

100 - Prodigy - Pwn#

Self proclaimed prodigy Gourav, has just learnt about binaries and compiler. He believes he can hide anything in the binary unless he doesn't print it. Show him that he is wrong.

Lets fire-up gdb.

The main function didn't give much information. It just showed the puts() function called.

The puts() function didn't show promise.

This means the flag is somewhere else. Objdump revealed an interesting function getFlag().

getflag

Setting breakpoint at the start of the program and going into the getFlag() function, the flag is present on the stack.

flag

Flag : CodefestCTF{`cZNjbcipTKZgHL}

Share