edit

DEADFACE CTF 2024: Cogs in the Machine

We intercepted this internal communcation between DEADFACE members, but all of our attempts to decipher the message have failed. Use your skills in cryptanalysis to decipher the hidden message.

Submit the flag as flag{flag-text}.

528B File, SHA1: 3414deba9788a60c04927cc30ef2606bfb4d66c9

We obtain a text file:

ciphertext.txt
Fsqp: rbkrkqqe
Ie: zb0oq404

Vygplkc: Fus Tfgkm Woc Oqgq

mo0bd,
Gvt mwbf ep shjpqmsm njceqe ixrf C aundcugg. Cl'eo sbh q obhykt, bvv my'z wkcdbk. Kzx jpecqs cuis'a bopuau yk ryo, ztt vki ypowkw vg scwtl kk ly gqh. Mwuvzi hwu mlovh nzti, fzz bjup n auwl uo qfd dtrwxxvim etvg jzex.
Pec gbvhojkwmac ibb'j fhndyb shf vanzjp... lsi.

Mbz cjzmf kex imnx xvh, rfw nkll tig wmgkwfc ivza dgoy. Yss sgpirhlz, etvg yjf'n frqs bprxmky yvlk. Iydaga ep dvftbxmouo.
Oaa'i cwm odbk sokij evc yff.

Vcsz: biyf{7j3_Kr4u3_Y3i3g_Ua3m}

At first glance, we notice two things:

Looking at our plaintext and our (guessed) plaintext, the pattern emerges:

Ciphertext F r o m
Plaintext? F s p q
Difference 0 1 2 3

Looks like every character is simply rotated by its position. And so, to decipher, a simple variation on the usual rotation code works:

from string import ascii_letters, ascii_lowercase, ascii_uppercase

with open("citm.txt") as f:
	s = f.read().strip()

k = 0

res = ""
for c in s:
	if c in ascii_letters:
		if (l := ascii_lowercase.find(c)) != -1:
			res += ascii_lowercase[(l-k)%len(ascii_lowercase)]
		elif (l := ascii_uppercase.find(c)) != -1:
			res += ascii_uppercase[(l-k)%len(ascii_uppercase)]
	else:
		res += c
	k += 1

print(res)
Output: deciphered result
From: luciafer
To: gh0st404

Subject: The Doors Are Open

gh0st,
The veil is thinning faster than I expected. We've got a window, but it's narrow. The others aren't seeing it yet, but the signal is clear on my end. Follow the usual path, but take a left at the crossroad this time.
The gatekeepers won't notice the switch... yet.

The flame has been lit, and soon the shadows will move. But remember, this isn't just another play. Timing is everything.
Don't let them sniff you out.

Flag: flag{7h3_Fl4m3_N3v3r_Di3s}

HomeAboutContact