← Back to Writeups
CUSTOMEasyMisc

No Laughing Matter

XESXOR9/10/20262 min read
#misc#custom#easy#ah_to_binary_substitution#eight_bit_ascii_decoding

No Laughing Matter

Platform: broncoctf2026 | Category: Misc | Type: Challenge | Difficulty: Easy | OS: NA | Author: XESXOR | Date: 2026-07-11 | Status: Solved Techniques: ah_to_binary_substitution, eight_bit_ascii_decoding

Summary

Task: aha.txt holds 36 space-separated 8-char tokens using only letters A and H. Solution: recognize the two-symbol alphabet as binary, map A=0/H=1, read each 8-symbol group as a big-endian ASCII byte to recover the flag.

No Laughing Matter — broncoctf2026

Description

You see, that's not funny.

A single file aha.txt was provided containing 36 space-separated 8-character tokens made up of only the letters A and H:

AHHAAAHA AHHHAAHA AHHAHHHH AHHAHHHA AHHAAAHH AHHAHHHH AHHHHAHH AHAHAHAH AHAAAHHA AHAHAHAH AHAAHHHA AHAAHHHA AHAHHAAH AHAAHHAA AHAAHHAH AHAAAAAH AHAAHHHH AHAAHHAA AHAAHHHH AHAAHHAA AHAHHAAA AHAAAHAA AHAAHAAH AHAAHAHA AHAAAAHA AHAAHHHH AHAAHHAA AHAHAAHA AHAAHHHH AHAAAHHA AHAAHHAA AHAAHAAA AHAAAAAH AHAAHAAA AHAAAAAH AHHHHHAH

Goal: decode the two-symbol stream into the flag.

Analysis

Semantic clues drive the whole task:

  • The title "No Laughing Matter", the prompt "that's not funny", and the filename aha.txt all evoke laughter (aha / haha). The two-symbol alphabet is A and H — the building blocks of a laugh.
  • A two-symbol alphabet is the classic disguise for binary.

Why 8-bit ASCII and not Bacon cipher:

  • Bacon uses 5-symbol groups (32 combinations, one per letter).
  • Here every token is exactly 8 symbols long, and the groups are already space-delimited. Eight bits = one byte, so each token is one ASCII character. This is straightforward 8-bit ASCII, not a 5-bit Bacon mapping.

Choosing the bit polarity:

  • Map A=0, H=1. The first token AHHAAAHA → 01100010 = 0x62 = b, and the run AHHAAAHA AHHHAAHA AHHAHHHH AHHAHHHA AHHAAAHH AHHAHHHH decodes to bronco{ — an immediate confirmation of the correct polarity.
  • The reverse mapping (A=1, H=0) produces high-bit / non-printable bytes, which rules it out.

Solution

  1. Read the file and split on whitespace into 8-symbol tokens.
  2. Translate A→0, H→1 in each token.
  3. Interpret each token as a big-endian binary byte and convert to its ASCII character.
  4. Join to get the flag.
python
#!/usr/bin/env python3
# No Laughing Matter — broncoctf2026
# A=0, H=1; each 8-symbol token is one big-endian ASCII byte.

with open("aha.txt") as f:
    tokens = f.read().split()

table = str.maketrans("AH", "01")
flag = "".join(chr(int(tok.translate(table), 2)) for tok in tokens)
print(flag)

Output:

bronco{REDACTED}

The decoded flag content is itself a string of laughter/joke abbreviations (UFUNNY LMAO LOL XD IJBOL ROFL HAHA), fitting the "not funny" theme.