News for hackers. Stuff that matters.
Re:How Hash Algorithms Work (2007) by koolba on Friday January 13, 2017 @04:31PM (#13394867)
> It's the arbitrary length that causes you to have more pigeons than pigeonholes.

No you can have a fixed length and arbitrary text. Say the input could be 32 hex characters representing a UUID. The key distinction is whether there is a finite / known list of the possible inputs. If so, then it's possible to create a hash function the perfectly hashes them.

Re:How Hash Algorithms Work (2007) by smallnamespace on Friday January 13, 2017 @06:18PM (#13395656)
Um, a fixed set of inputs cannot be of arbitrary length, since you by definition know the size of the longest possible input string.

The point is that a function cannot bijectively compress arbitrary input into fixed output. Of course if you make the function itself depend on the input itself, then you can pull all sorts of tricks, but normally we do not call a simple lookup table a 'hash function', because they are very different things.