top of page

Pico CTF: Time Machine

  • Cody
  • Dec 9, 2024
  • 2 min read

Challenge: Time Machine

Difficulty: Easy

Description: Walkthrough and Learning


Challenge: Help this person find what they were working on (and hopefully the flag!).



We have a zip file with a git repository.


I think I went the easy way by just opening it in the GUI file browser (because I was eating dinner at the same time and had one hand free). But then I did it through the terminal to see the challenge that way.


After making a folder for the challenge, I changed directory to the folder. This was a good reminder to use the backslash behind the first word if there is a space. I forgot about that. ls command to list. Only option shown is directory "drop-in"; change directory to "drop-in" (cd drop-in). ls command again to list contents. We have "message.txt." Cat message.txt to show the contents inside message.txt. It's a note, but not what we are looking for. I don't believe that that is all that is in that directory. So I modify the ls (list) command to include -a which stands for "list all". Now we have some options. If I cd (change directory) to "." or "..", I'm going either to the directory I am in ("cd ."); or I am going to go to the previous directory ("cd .."). That doesn't get me anywhere. So that leaves .git.



I change directory to .git ("cd .git") and then ls again to list the contents of the directory. From the previous note, the person mentioned needing to look at their commit history. In the .git directory, we find a "COMMIT_EDITMSG" file. Cat COMMIT_EDITMSG to reveal its contents. And there is the flag!


Thanks for reading!

Comentários


bottom of page