$ cat writeup.md…
$ cat writeup.md…
tjctf
Task: PNG image with glitched color bands and noise overlay, description hints 'Do not resist the glitch'. Solution: identify horizontal bands as resistor color codes, read 28 bands in pairs to get two-digit decimal numbers, convert to ASCII.
Do not resist the g̵͕̗͑̅l̶̢̂̚ḭ̶̐͗t̴͔̞̒͐c̸̭͈̄h̷̨̞͊͠. Wrap flag in tjctf{}
A PNG image (1920×1080, 8-bit palette mode, 156 colors) showing a glitched test pattern with horizontal color bands and heavy noise/glitch artifacts overlaid. The goal is to extract the flag hidden in the color pattern.
The image contains horizontal color bands spanning the width of the image, overlaid with significant noise and glitch effects. Several rabbit holes exist:
The key breakthrough comes from the challenge description: "Do not resist" is a wordplay on "resistor". The horizontal color bands represent resistor color codes.
The standard resistor color code assigns digits 0-9 to colors:
| Color | Digit |
|---|---|
| Black | 0 |
| Brown | 1 |
| Red | 2 |
| Orange | 3 |
| Yellow | 4 |
| Green | 5 |
| Blue | 6 |
| Violet/Purple | 7 |
| Gray | 8 |
| White | 9 |
The image contains 28 horizontal color bands (not 13 as it appears at first glance — thin bands can be missed due to the noise overlay and aggressive denoising merging them with neighbors). These 28 bands are read in pairs, where each pair forms a two-digit decimal number that maps to an ASCII character.
Careful segmentation of the image (avoiding aggressive median filtering that merges thin bands) reveals 28 distinct horizontal color bands from top to bottom.
| Pair | Color 1 | Color 2 | Digits | Decimal | ASCII |
|---|---|---|---|---|---|
| 1 | Blue | Gray | 6, 8 | 68 | D |
| 2 | Green | Brown | 5, 1 | 51 | 3 |
| 3 | Gray | Orange | 8, 3 | 83 | S |
| 4 | Yellow | White | 4, 9 | 49 | 1 |
| 5 | Violet | Brown | 7, 1 | 71 | G |
| 6 | Violet | Gray | 7, 8 | 78 | N |
| 7 | Yellow | Orange | 4, 3 | 43 | + |
| 8 | Gray | Yellow | 8, 4 | 84 | T |
| 9 | Blue | White | 6, 9 | 69 | E |
| 10 | Blue | Violet | 6, 7 | 67 | C |
| 11 | Violet | Red | 7, 2 | 72 | H |
| 12 | White | Green | 9, 5 | 95 | _ |
| 13 | Green | Gray | 5, 8 | 58 | : |
| 14 | Yellow | Brown | 4, 1 | 41 | ) |
Result: REDACTED
#!/usr/bin/env python3 """ TJCTF 2026 - glitch Resistor color code decoding from horizontal color bands in a glitched PNG. """ # Standard resistor color code: color -> digit digits = { "black": "0", "brown": "1", "red": "2", "orange": "3", "yellow": "4", "green": "5", "blue": "6", "violet": "7", "gray": "8", "white": "9", } # 28 bands read top-to-bottom, grouped into 14 pairs pairs = [ ("blue", "gray"), # 68 -> D ("green", "brown"), # 51 -> 3 ("gray", "orange"), # 83 -> S ("yellow", "white"), # 49 -> 1 ("violet", "brown"), # 71 -> G ("violet", "gray"), # 78 -> N ("yellow", "orange"), # 43 -> + ("gray", "yellow"), # 84 -> T ("blue", "white"), # 69 -> E ("blue", "violet"), # 67 -> C ("violet", "red"), # 72 -> H ("white", "green"), # 95 -> _ ("green", "gray"), # 58 -> : ("yellow", "brown"), # 41 -> ) ] message = "".join(chr(int(digits[a] + digits[b])) for a, b in pairs) flag = f"tjctf{{{message}}}" print(flag) # tjctf{REDACTED}
$ cat /etc/motd
Liked this one?
Pro unlocks every writeup, every flag, and API access. $9/mo.
$ cat pricing.md$ grep --similar