I've posted a related question on Stack Overflow, but I have a more general question about HMAC and SHA256.
Let's say I want to generate an HMAC hash for a blank key and a blank message. The Wikipedia page shows "
b613679a0814d9ec772f95d778c35fc5ff1697c493715653c6c712144292c5ad" as the example hash. However, if I take 64 of the opad 0x5c characters ("\") and append to it the SHA256 of 64 of the ipad 0x36 characters ("6"), then take the SHA256 of that whole string and I get "
6c64aeadc27db5d98c91a8789d59c2ebed85c860072929b06b361fff434e00c2" as the answer.
Shouldn't this be the same as the answer to the blank HMAC? I think understanding the difference here is what's holding me back from getting my algorithm right.
Any help or guidance (even badmouthing at this point) would be much appreciated!