Well hidden message - Standard Code Encryption

Flag: HACKDAY{8rUmE_NOIR3_H!DD3N_Ch@mb3R}

Challenge

Description


The notes you have discovered hold a secret. They contain a text coded using a process that the monk seems to have devised himself. However, the Black Mist hackers have introduced a subtlety: they have adapted this method to the basic language of machines.


Format: HACKDAY{flag} Note: File found at step 1 have an error, use the one here. SHA256: 2f1efc5b0672a938ed5b6e284681eeb0f4c292ef8040dc8a4157065bb7642b2d

Solution

Ce challenge fait suite à Well hidden message - Campsite. On parle notamment de Johannes Trithemius. Dans la première version du challenge, le secret.txt était mal fait (c'est toujours le cas, mais au moins, on peut récupérer le flag plus facilement).

En se renseignant sur le chiffrement de Johannes Trithemius, on apprend que la première étape est d'ajouter 1, puis 2, puis 3 à tous les caractères. En l'adaptant à la table ASCII, on va retirer (pour déchiffrer) et faire un module 128.

En python :

with open('secret.txt', 'rb') as f:
  data = bytearray(f.read())
  
for i in range(len(data)):
  data[i] = (data[i] - i) % 128

print(data)
bytearray(b'Nam vitae lacus at velit molestie dapibus a placerat risus. In in metus eget massa auctor HACKDAY{8rUmE_NOIR3_H!DD3N_Ch@mb3R} ornare quis cursus odio. Interdum et malesud`c`\x1fe`ldr\x1f`b\

Dernière mise à jour

Cet article vous a-t-il été utile ?