Skip to main content

Flags picoCTF 2019 Solution

Decode a message encoded using a visual flag-based alphabet system to recover the hidden text.

Published: April 2, 2026Updated: August 13, 2026

Description

What do the flags mean? The image shows signal flags - decode them using the US Navy signal flag alphabet.

Download the image file.

bash
wget <url>/flag.png

Solution

Want to try it yourself first?

The guided walkthrough reveals hints one step at a time.

Walk me through it
  1. Step 1Open the image and identify the flag system
    Observation
    The description mentions signal flags and points at the US Navy alphabet. So this is a lookup exercise: open the image, identify the flag system, and read it off a chart. No analysis tools needed.
    Open flag.png. The image shows a series of maritime signal flags - the international code of signals used by the US Navy and merchant vessels. Each flag design corresponds to a letter. Search for a 'US Navy signal flags alphabet' reference chart.
    bash
    xdg-open flag.png
    What didn't work first

    Tried: Try to decode the flags using semaphore charts instead of maritime signal flags.

    Semaphore encodes letters by the angle of two handheld flags, not by the color pattern printed on a rectangular one. The two systems are unrelated, so a semaphore chart applied here just produces nonsense. The right reference is the International Code of Signals / US Navy signal flag alphabet, which maps each flag design to a letter or digit.

    Tried: Run strings or exiftool on flag.png looking for hidden text or metadata instead of decoding the visual flags.

    strings and exiftool read metadata and raw bytes, not the picture itself. The message is drawn in the image pixels, so there is no hidden ASCII or EXIF field to find. You have to open the image, identify each flag by eye, and match it against the chart.

    Learn more

    The International Code of Signals (ICS) uses a set of 26 lettered flags, 10 numeral pennants, and special flags. Each letter flag has a unique color pattern. The US Navy uses this system for visual ship-to-ship communication. This is distinct from semaphore (which uses a person holding two handheld flags at different angles).

    Note that the number flags in the US Navy system differ from the national/NATO version - the number flags differ from the international standard, so the US Navy chart must be used specifically.

  2. Step 2Look up the US Navy signal flag alphabet
    Observation
    Two details narrow down the reference: semaphore charts produce nonsense here, and the number flags match the US Navy version rather than the international standard. Getting the right chart is the whole step; decoding after that is mechanical.
    Search for 'US Navy signal flags' or 'Navy signal flag alphabet' to find a reference chart showing the color pattern for each letter and number. Match each flag in the image to its corresponding character.
    Learn more

    Each flag in the ICS has a specific design: for example, Alpha is white and blue, Bravo is all red, Charlie is horizontal red-white-blue stripes. The numeric flags (0-9) are pendants (triangular) with different color patterns. Pay attention to whether the flags in the image are letter flags or number flags.

  3. Step 3Decode and submit the flag
    Observation
    Each flag in the image maps one-to-one to a letter or digit on the chart. Read them left to right, concatenate the results, and wrap that in picoCTF{}.
    Read each flag from left to right (or in sequence as shown). Concatenate the decoded letters/numbers. Wrap in picoCTF{...} to submit.
    Learn more

    Maritime signal flags are still used today by the US Navy and international shipping for visual communication when radio silence is required. The full ICS defines single-flag signals (letters) with standardized meanings (e.g., Alpha = diver down, Bravo = dangerous cargo), as well as multi-flag signals for longer messages.

Interactive tools
  • Cipher Identifier & Auto-DecoderPaste any ciphertext and the tool auto-runs every common decoder (base64, hex, Morse, ROT, Atbash, Bacon, binary, decimal, URL) and ranks the results by English-likeness.

Flag

Reveal flag

picoCTF{F1AG5AND5TUFF}

Decode using the US Navy signal flag alphabet (not semaphore) - each flag design represents a letter or number that spells the flag.

Key takeaway

Visual encodings like maritime signal flags, semaphore, and Morse are substitution ciphers where each symbol maps to a letter by a published standard. Recognizing which system is in use and finding the right chart is the entire challenge, because the mapping is public and mechanical once identified. CTFs lean on obscure but real standards (flag alphabets, Braille, NATO phonetic, barcodes) to test whether you can identify and look up a system instead of trying to cryptanalyze it.

Related reading

Tools used in this challenge

Where to go next