CRACK Solution
SUM CHECK
CRACK byte-sum checksum

Prerequisites
DUMP
Techniquebyte-sum checksum
Rulenonzero
SampleDUMP
Walkthrough
Four bytes. The check just adds them all up and wants the low byte of the total to be 0x36. Any four chars that sum right will pass; the clean read is a real word.
Byte-sum checksum: the check compares the sum of all bytes (mod 256) to a target, so pick bytes whose total lands on it.
Hints
- HINT 1: Four bytes. There is no per-byte transform, only one final compare against 0x36.
- HINT 2: The loop accumulates a running sum. You need the low byte of the total to equal 0x36 (decimal 54).
- HINT 3: D U M P sums to 310 and 310 & 0xFF is 0x36.
Reject Samples
- DUM
- DUMPS
- AAAA
Verifier Listing
; g12_easy5: byte-sum checksum. All four input bytes are added together and the
; running total (mod 256) is matched against a stored target. Technique: additive
; checksum (sum of bytes). Many inputs share a sum, so this is not an exact-match
; cipher. r0 = 1 on accept. Accept rule: nonzero. Four bytes long.
;
; target = 0x36 (310 & 0xFF). A clean sample is "DUMP":
; 'D'(68)+'U'(85)+'M'(77)+'P'(80) = 310; 310 & 0xFF = 0x36.
len r2
cmp r2, 4
jnz bad ; exactly 4 bytes
mov r3, 0 ; r3 = running sum
mov r7, 0 ; r7 = index
loop: cmp r7, r2
jge tally ; summed all four -> compare
ldb r0, [r7]
add r3, r0 ; sum += input[r7] (mod 256)
inc r7
jmp loop
tally: mov r0, r3
cmp r0, 0x36 ; 310 & 0xFF
jnz bad
mov r0, 1
ret
bad: mov r0, 0
ret