Score:1

Is it safe or reasonable to use the key parameter in a cryptographic hash function as a counter?

il flag

Not all the cryptographic hash functions have the counter parameter for making messages be different for each counter value. But many accept a key parameter.

Is reasonable to use the key parameter as a counter?

Is it safe?

Score:1
vu flag

Hash functions don't have key as parameter. I assume you got that misconception from programming languages such as PHP where they allow you to set a key to turn them into HMAC, despite they're no longer plain hash anymore.

That counter is part of padding to make the message "Merkle-Damgaard-Compliant", and there are other ways to do that.

mangohost

Post an answer

Most people don’t grasp that asking a lot of questions unlocks learning and improves interpersonal bonding. In Alison’s studies, for example, though people could accurately recall how many questions had been asked in their conversations, they didn’t intuit the link between questions and liking. Across four studies, in which participants were engaged in conversations themselves or read transcripts of others’ conversations, people tended not to realize that question asking would influence—or had influenced—the level of amity between the conversationalists.