In order for an extension attack, wouldn't the blocks have to align perfectly?
Like suppose I hash
[abcd][efgh][k]
How would you extend that?
How would you extend that?
Your hash construction will pad out your data to be multiples of the right size. That padding can be verified in some way - often it is all nulls, or encodes the length of the message. http://en.wikipedia.org/wiki/Merkle%E2%80%93Damg%C3%A5rd_con...