News for hackers. Stuff that matters.
Re:BlurHash: Algorithm to generate compact representation of... by tantalor on Thursday February 20, 2020 @09:28AM (#22375266)
> Your client then takes the string, and decodes it into an image that it shows while the real image is loading over the network.

That's not a "hash", that's an encoding. Hashes are one-way.

Re:BlurHash: Algorithm to generate compact representation of... by lvh on Thursday February 20, 2020 @09:34AM (#22375319)
This /is/ one-way by virtue of throwing information away: you can't rebuild the original image. If you're thinking of preimage resistance (it must be hard to find an input that hashes to a given output) that's a property of cryptographic hashes, but not hashes in general (canonical example FNV).
Re:BlurHash: Algorithm to generate compact representation of... by dahart on Thursday February 20, 2020 @09:50AM (#22375416)
A hash is any function that produces a fixed size output. It’s not required to be one-way, or to even change the input. You might be thinking of a “good cryptographic” hash. For that, it’s desirable to be one-way and to scramble the input, but that’s a specific subset of hash functions.

Edit: to the downvoter, please have a look through https://en.wikipedia.org/wiki/Hash_function

Re:BlurHash: Algorithm to generate compact representation of... by bootloop on Thursday February 20, 2020 @09:30AM (#22375283)
Can you show me then how you decode this string to the original image?