Hear the Words
Task 3 of 5 · Stage 1 · Read files · Next: Task 4 · Find the Gate
A program carries several possible watchwords. Inspect its strings, locate the bytes behind one lead, then test which input it accepts.
- ~30 min
- 4 checked steps
- HxD · Detect It Easy
- You will use this when
- you get an unknown program: in the first minutes, its readable text shows web addresses, file names, error messages and commands without running anything. Reviewers do the same to find passwords left inside programs.
- Later in this path
- task 4 follows one of these strings into the code that decides; the Stage 1 checkpoint asks you to find a word the forger planted among real ones.
- After this task you can
- list a program’s strings, tell its own words from the file format’s, and test a lead by running the program safely.

Keeper: Here it is — a page that is also a program. It will not open until you speak its watchword. The Overwrite reached it before you did and wrote false words beside the true one, in the same hand. A plain program like this one carries its words inside it. Listen to all of them before you speak one.
You will learn
- find readable strings reported by the tool
- set the program's own words apart from the file format's
- treat a string as a lead, and confirm it by what the program does
- You need
- Task 2: offsets and text in a hex dump · HxD and Detect It Easy from the lab setup · PowerShell
- Time
- ~30 minutes; the Ghidra bonus adds ~10
- Tools
- Detect It Easy, HxD, a notes file. Ghidra only for the bonus
Where this is used
Strings can provide early leads before you read instructions: addresses, file names, error messages and commands may be stored as readable text. A candidate found this way still needs checking; its presence does not tell you whether or how the program uses it.
Get the page
Archive page 3
watchword.exe
A tiny console program written for this task. It reads one line you type and prints one line back. It borrows four functions from Windows and nothing else — step 1 shows you how to check that yourself.
SHA-256: bae7ca8566afb2773708c3c1cbca1815ec1eeced8cec7a0165b1479f06ed46de
VirusTotal: 0 / 60 engines reported a detection (scanned 26 November 2026). See the report.
Save it in C:\b2f\samples. Before you run anything, read Downloads and safety: why Windows may warn you about a new, unsigned program, and how to compare its SHA-256 fingerprint.
Step 1 · ~6 min
Is it a program?
Before you listen to a file, inspect its format and look for clues about its behaviour. Detect It Easy reads the content, not the name, and reports the format. Its import list names functions declared for use from Windows libraries. These names are leads, not an exhaustive behaviour report: code can resolve functions while it runs, and packing can hide information from this view. For this exercise, record what the import table shows. It is not a complete account of every action the program could take.
- Drag
watchword.exeinto Detect It Easy. Read the file type on the first line. - Open the import list. Write every DLL and function name under Observed.
- Before you check: which listed functions read or write through an existing handle? Do you see a function for opening a new file? Record the names and the limits of that observation.
A Windows program for 64-bit processors. Its four listed imports obtain a standard handle, read or write through a handle, and end the process. None is a file-opening function. That describes the table, not every possible action of the program.
H1 · Direction
The answer is on the first lines of Detect It Easy's main window, before any button.
H2 · Method
The type is the name of the Windows program format followed by its width: 32 or 64.
H3 · Check
Two letters and two digits. If it shows a different width, you dragged in another file.
Step 2 · ~8 min
Hear every word
In the ASCII view used here, look for runs of four or more printable bytes: 0x20–0x7E, which covers the letters you used in task 2 plus space (0x20), digits 0–9 (0x30–0x39) and punctuation such as the hyphen (0x2D). Windows programs also store text as UTF-16: the ASCII-range characters used here appear as two bytes in UTF-16LE, with 00 second (A is 41 00). Other characters can have different byte patterns. Detect It Easy lists both kinds. The tool does not know what the program means by them. Most strings in a small program are not its own words: they belong to the file format (the old DOS message, section names such as .text), to the import list (DLL and function names), or to the version information. Set those aside first; what is left gives you candidates to investigate, not a list of confirmed behaviour.
- In Detect It Easy, open Strings.
- Cross out, in your notes, every string you can explain as format, import or version text.
- Copy the rest in the order they appear. Mark the ones shaped like a watchword: two words and four digits, joined by hyphens.
- Before you check: which candidate would someone pick who reads only the line after the prompt? Write it down — step 4 tests that habit.
Several candidates, one shape. The strings list cannot tell you which one is true — step 4 does.
H1 · Direction
Ignore anything starting with a dot, anything ending in .dll, the four function names from step 1 and the sentence about DOS.
H2 · Method
Type a hyphen into the strings filter. Count only entries of the shape word-word-digits.
H3 · Check
More than two, fewer than six. All of them sit between the prompt and the first full sentence of the program's replies.
Step 3 · ~6 min
Two tools agree
A strings list is a report about the bytes. Before you trust it, go to the bytes. Detect It Easy gives each string an offset — where in the file it starts, a position, not a value. Jump there in HxD and read it yourself. Agreement confirms the string at that file offset; it does not show that the program uses it as the watchword.
- In the strings list, read the offset of the first watchword-shaped string.
- Open the file in HxD. Choose Search → Go To, choose hex, and type that offset.
- Read the bytes at the cursor and compare with the text column. Lowercase ASCII
a–zoccupy0x61–0x7A, so lowercasecis0x63. - Before you check: the candidate starts with a lowercase
c. Which byte value do you expect at the cursor?
Two tools, one answer: write it under Verified, with the offset beside it.
H1 · Direction
The offset is a column in Detect It Easy's strings list, on the same row as the string.
H2 · Method
HxD's Go To accepts the offset in hex. If the cursor lands in the middle of other text, check that hex, not decimal, is selected.
H3 · Check
The byte at the cursor is 0x63. If it is not, the offset was copied from another row or read in the wrong base.
Step 4 · ~8 min · flag
Which word does the door hear?

Keeper: Four words in one hand, and three of them are lies. Do not choose by the look of them. Speak each one to the door and listen to what it says back.
A strings list tells you what is in a file, not what the program does with it. This exercise uses our task-specific sample. Before running it, follow the download and fingerprint checks in Downloads and safety; the import list alone is not a safety check. Our rule: run a program on your own system only when its SHA-256 matches the one printed on this site. A sample you found, were sent or cannot check goes into a virtual machine or Windows Sandbox (Windows Pro, Enterprise or Education), never onto your own system. Run it and let its answers decide. Each run is an observation: write the word you typed, the reply and the exit code.
- Open PowerShell in
C:\b2f\samples. Run the program, type one candidate, press Enter. - Read the reply, then the exit code:
0accepted,1refused,2nothing typed. - Repeat for each candidate. Type the one the door accepts below.
.\watchword.exe
$LASTEXITCODE
Flag captured
Keeper: The door heard you. Notice what decided it — not the words, you had four of those; the door's own answers. The next page is a gate that says only open or shut, and the Overwrite has painted a word across it. You will have to read how it decides.
Task 4 · Find the Gate → Explain your findingH1 · Direction
You do not need to guess: you have a short list from step 2, and the program answers for every word on it.
H2 · Method
One run per candidate. Copy the word from your notes, not from memory — one wrong character is a different word. Keep a table: word · reply · exit code.
H3 · Check
There are two kinds of refusal, and one names the Overwrite. Only the watchword gives exit code 0. It is neither the first nor the last candidate in the list.
Walkthrough
Stuck after the hints? Show the walkthrough — it shows every answer
- 1. Detect It Easy: PE64, console; imports
GetStdHandle,ReadFile,WriteFile,ExitProcess. No file-opening function appears in this import table; that alone does not prove the program cannot open files. - 2. After the prompt: 4 candidates of one shape, then three replies.
- 3. The first candidate's offset, where HxD shows
63: 0x877. - 4. Candidates 1, 2 and 4 get the reply that names the Overwrite, exit code 1. Candidate 3 gets the acceptance line, exit code 0: type candidate 3.
Bonus
Explain your finding
Four lines in your notes: Observed (format, imports, the candidates and their offsets, the runs) · Hypothesis (which word you expected before running, and why) · Verified (what two tools or a run confirmed) · Unknown (what you still have not seen).
Without running it. If Ghidra is set up (lab setup, Ghidra), import the file, let it analyse and open Window → Defined Strings. The cross-reference column shows which code uses each string. Follow the watchword's reference: what does that code print next? That is the doorway to task 4.
I have written my note — show the model note
- Observed
- Detect It Easy: PE64, console. Imports from
KERNEL32.dllonly:GetStdHandle,ReadFile,WriteFile,ExitProcess. Strings: a prompt, then four candidates of one shape; the first starts at the offset found in step 3, where HxD shows63(c). Runs: candidates 1, 2 and 4 → "forged by the Overwrite", exit 1; candidate 3 → accepted, exit 0. - Hypothesis
- Before running: the strings list alone gave no reason to choose — all four share one shape, and a place in the list proves nothing. The first candidate was only the tempting one.
- Verified
- Detect It Easy reports PE64. The first candidate starts at file offset
0x877, where the hex view shows63(c). The tested watchword is candidate 3: the program accepts it with exit code 0. These checks do not establish every possible behaviour of the program. - Unknown
- How the program compares the input — whole word, case, length. I saw its answers, not its check. That is task 4.
Check yours: does each claim name a tool, an offset or a run? Did you keep the tempting guess apart from what the program confirmed? Each “no” is what to add.
This is guided practice. After task 5, use the Stage 1 checkpoint, The Forged Ledger, to test your work without hints. A separate no-hints version of this task is planned.
Your progress in this browser
Read further
- Microsoft Sysinternals — Strings — the classic command-line strings tool for Windows: step 2 for whole folders.
- FLARE FLOSS — a malware-analysis tool that finds plain strings and also the ones a program builds or hides: where this task leads.
- CWE-798 — Use of Hard-coded Credentials — why a password inside a program is a security weakness.
Outside sites, not ByteToFlag. Links checked on 26 November 2026.
Take your method to the next task
Before you move on
- Can you separate format and import text from candidate watchwords?
- Can you locate a reported string at its file offset and explain what the second tool confirms?
- Can you record each tested input, reply and exit code without treating an import list as a safety guarantee?
If one is unclear, revisit that step or compare your explanation with the model note. The final watchword check records this one task as guided practice when browser progress is on.
In Task 4, Find the Gate, move from observing replies to reading the code that makes a decision. Prepare Ghidra using the lab setup guide.
Task 4 · Find the Gate → Prepare Ghidra Back to Module 3