Another day, another challenge…
Today’s blog post we will solve the, “Yarn” challenge from PicoCTF.
Let’s get started.
Clicking on the challenge we see:
OK, we need to find a flag inside of a file, but we do not know what the file is.
Let’s look at the hints and see if that provides any clues.
Looking at the hints we’re provided with two questions. Possibly answering these questions will leads us to the flag.
Answer question #1 – “what does the string command use to determine if something is a string?” We decide to do a Google search to answer just that.
Doing this Google search we’re provided with the following link.
Reading the article we determine that the strings command prints the printable characters from a file.
Doing that we’re provided with the following screenshot:
We’ve answered question #1. Let’s answer question #2.
Question #2 – is there a way to change the length that the strings command look for?
Going back to the link we see that there is a way we can specify that there is a way to determine the length of strings we want to print.
How do we use this?
By adding the “-n <length you want to use>”
Doing this we get the following:
Scrolling down we see:
Hmm… I think we found the flag! “Submit_me_for_I_am_the_flag”
Putting this string as the flag we have acquired 55 points!