Question:
What is the ip of the victim?
Falg is: md5(ip)
Solution:
Scrolling down the code in IDA two funtions pop out:
there is a "system" call in the attack function which tries to run this command:
wget http://ctf.sharif.edu/{code}/target.txtby more inspection one must notice the binary MD5 must not change and the generated {code} is time-dependent.
in check time function
Calculates 52c35a80 = 1388534400
--> UNIX time --> Wednesday 1st January 2014 12:00:00 AMSet time, and got correct file:
http://ctf.sharif.edu:2048/7266de4447eba9a354622271cff2dde5/target.txttarget.txt contain an IP address which was 95.211.102.203 and the flag becomes 5cfed0f91a2b71a5d79aa681eaf10adb
happy hunting!
how did you find the key ? guessing ?
ReplyDeletein the attack function the hash is generated. one can follow the calculations but not really necessary since it's the argument passed to _system function and can be retrieved by setting a breakpoint before _system function call.
Delete