Description
Milk... Slap... Do the words make sense to you? Download milkslap.png.
Setup
Open the challenge URL in a browser to find the embedded image.
# Open the challenge URL and view source / Network tabSolution
Walk me through it- Step 1Discover the embedded image from the pageOpen the page and either view source or open DevTools Network tab. The image URL appears as an <img src="..."> reference (or as a background-image in CSS). Pull it down with wget so you can run tools on the file directly.bash
curl -s <CHALLENGE_URL> | grep -Eo 'src="[^"]+\.png"' | sort -ubashwget <DISCOVERED_PNG_URL> -O milkslap.pngbashfile milkslap.pngLearn more
Why scan the page first. picoCTF stego challenges often hide the actual image one or two levels into the HTML rather than in a download link.
view-source:in the browser address bar, orcurl <url>piped throughgrep, reveals every resource the page loads. CSS background-images and lazy-loadeddata-srcattributes are common tricks - check both. - Step 2Run zsteg to detect LSB steganographyUse zsteg on the image to automatically detect and extract data hidden in the least significant bits of the image pixels. The flag is hidden using LSB steganography.bash
zsteg milkslap.pngbashzsteg -a milkslap.png # exhaustiveLearn more
LSB steganography (Least Significant Bit) hides data by replacing the lowest bit of each pixel color channel with a bit of the secret message. Because the change is only 1 out of 255 possible values for each channel, it is virtually invisible to the human eye but detectable with the right tools.
zsteg is a Ruby-based tool specifically designed to detect various steganographic methods in PNG and BMP files. It tries multiple combinations: different bit planes (LSB, bit 1, bit 2...), different color channels (R, G, B, A), different byte orderings, and both row and column scans. Its output shows detected data along with the method used to extract it.
If zsteg is not available, you can use stegsolve (a Java application) to manually examine different bit planes visually. Alternatively,
steghidehandles JPEG and BMP files. For a purely manual approach, a Python script using PIL can extract LSB values:pixel[0] & 1gives the red channel LSB of each pixel.
Flag
picoCTF{...}
The flag was hidden in the least significant bits of the image's pixel data - a classic LSB steganography technique that is imperceptible to the naked eye.