N
niv
Guest
Trying to build a standard HASh256 function based on some web articles I've read.
Generally it takes 64 steps per message slice, & I have a sample printout-out of the 8 intermediate register (a to h) values for the 64 steps for the simple (hex) message X"61626380"
I don't get the expected intermediate value(s).
I thought the8 regs were initialised to '0's, then apply the first 16 words with the K(i) constant, then the remaining 48 words from the message expander.
Finally, the 8 regs are then added to the 8 pre-initialised Hash regs (H0 to H7)
I thought the first a reg value would just be thesum of K(0) & the first message word, but it isn't.
Anyone tell me where I'm going wrong please?
Generally it takes 64 steps per message slice, & I have a sample printout-out of the 8 intermediate register (a to h) values for the 64 steps for the simple (hex) message X"61626380"
I don't get the expected intermediate value(s).
I thought the8 regs were initialised to '0's, then apply the first 16 words with the K(i) constant, then the remaining 48 words from the message expander.
Finally, the 8 regs are then added to the 8 pre-initialised Hash regs (H0 to H7)
I thought the first a reg value would just be thesum of K(0) & the first message word, but it isn't.
Anyone tell me where I'm going wrong please?