-
Considering that the output of this function is 64 bits, does it means that if my input is exactly 64 bits it can still be considered collision resistant? I'm wondering if I could use it as some kind of format-preserving encryption to hash 64 bits BigInts used as primary keys from a database, was inspired by this interesting blog post. Thank you for the help! |
Beta Was this translation helpful? Give feedback.
Replies: 1 comment
-
It is not. SipHash is a pseudorandom function. Which means that for a given key, with a sequence of distinct inputs, the output will look like a random sequence. Looking like a random sequence implies that outputs may repeat. What you're looking for is a 64-bit block cipher, and this is only safe with a small number of inputs. |
Beta Was this translation helpful? Give feedback.
It is not.
SipHash is a pseudorandom function. Which means that for a given key, with a sequence of distinct inputs, the output will look like a random sequence.
Looking like a random sequence implies that outputs may repeat.
What you're looking for is a 64-bit block cipher, and this is only safe with a small number of inputs.