Played with my CTF team fr334aks. The challenges were lots of fun and i learnt a thing or two from it.
We're given a zipfile. Unzipping it, extracts a pcap file. Using wireshark, you'll notice that there's interesting data from the telnet protocol. Following the tcp stream of any of the packets after filtering for telnet will land you the flag which is base64 encoded.
Decoding it will give you the flag.
We're given a zipfile. Unzipping it, extracts a .git folder. Interesting. What i usually do when i get such a chall, is i change my directory to the repo, then run rgrep
.
One of these should potentially have the flag. You can then run git show <commit>
.
Easy.
We're given a zipfile. Unzipping it, extracts a .mp3 file. Playing it, you'll notice dial tones. I quickly went to dialabc. But you'll notice that it doesn't really like the mp3 file, and so, i had to convert it to a more suitable file format which is wav. And for this i used mpg321
which you can install by just running sudo apt install mpg321
.
Now i can upload the file. Got a few digits.44422226684433277788
. Using dcode-cipher-identifier, i was able to tell that it was a Multi-tap Phone (SMS). I used dcode-multiple-abc-cipher to decode it and got the flag as ICANTHEARU
.
This was a fun web chall. Visiting the website, there was nothing really interesting on the webpage, but there a was a link to login that required you to enter the username and password. If you try like admin:admin, it does nothing and reloads the login page. If you look at the web developer tools, you'll notice that the request made to admin.php is a 302 which redirects you back to login.php. Okay, i can use python to login anyways.
Seems we are in. Now, there's this interesting part from the response. It seems there's a submit button in admin.php that allows one to print the flag. But unlike the login part, you must send a get request to admin.php for this to work. We could do this with python very easily.
Easy.
Another fun web chall. Visiting the website, there's an interesting note that says, If you see this the new method of getting files is working!
. Checking the cookies, there's a session cookie: Tzo3OiJHZXRQYWdlIjoxOntzOjQ6ImZpbGUiO3M6MTA6ImluZGV4Lmh0bWwiO30%3D
. Decoding this with base64, you'll get O:7:"GetPage":1:{s:4:"file";s:10:"index.html";}
.
So, this is a serialized object with the class GetPage. From the object, i tried to change index.html to /etc/passwd and see if it was an easy win.
But, using this didn't work.
There's a php script that is using include() to read the file but also maintaining the web root directory. So, using path traversal, you could potentially read /etc/passwd right?
Tried this as the session cookie, but it still didn't work. It still loads the default page, but then says that You should not be doing that
. Most likely the periods and backslashes are being filtered out. So, how my good friend lvmalware went around this, was urlencoding the backslashes.
This should now do the trick.
And indeed, we get the /etc/passwd file.
Now to easen the work.