Challenges
Hash chain
Cryptography
Medium
Hash chain
Solves: 6
Hash chain
Author: CyberSamSU
Points
45
A hash chain is a sequence generated by repeatedly hashing a value: v0, v1 = H(v0), v2 = H(v1), ... Such a chain is one-way: calculating v(i+1) from v(i) is easy, but recovering v(i) from v(i+1) (preimage) is generally hard. One-time password systems like S/KEY are based on this idea.
The chain in this challenge is constructed as follows:
seed— an unknown 4-digit PIN (0000..9999), with leading zeros,v0 = sha256(seed_matn).hexdigest(),v(i+1) = sha256(v(i)_matn).hexdigest()— meaning we hash the previous hex string.
The 10th element of the chain (v10) is given:
5923c8b2948de6ff58823d8695f7fa894537850ccd8c38badf21f4e020acd462
Find the previous value in the chain — v9. Flag: BAYROQ{H4SH_zanjir_<v9_ning_birinchi_16_hex_belgisi>}
The preimage cannot be found directly. However, the seed is only 4 digits long — 10,000 variants. Try all of them and find the PIN that leads to v10.
To submit a flag, log in.