Secret of the Polyglot
- Description: The Network Operations Center (NOC) of your local institution picked up a suspicious file, they're getting conflicting information on what type of file it is. They've brought you in as an external expert to examine the file. Can you extract all the information from this strange file?
- Difficulty: Easy
🔎 Solution
When opening the PDF file, part of the flag is revealed: 1n_pn9_&_pdf_724b1287}
.
Using the file
command to identify the true file type shows that it is actually a PNG image.
This technique suggests the use of a polyglot file - a single file crafted to be valid in multiple formats simultaneously.
┌──(kali㉿kali)-[~/Desktop]
└─$ file flag2of2-final.pdf
flag2of2-final.pdf: PNG image data, 50 x 50, 8-bit/color RGBA, non-interlaced
By renaming the file's extension to .png
, we obtain a new PNG file that contains the beginning portion of the flag: picoCTF{f1u3n7_
🚩Flag
picoCTF{f1u3n7_1n_pn9_&_pdf_724b1287}