O'Reilly logo

Android Application Security Essentials by Pragati Ogal Rai

Stay ahead with the world's most comprehensive technology and business learning platform.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, tutorials, and more.

Start Free Trial

No credit card required

Hashing functions

Hashing functions are algorithms that work on data of an arbitrary length to produce a fixed length output. Given the same input, the output is always the same and for different input values, the output is always different. These functions are one way, which means that the reverse operation on data is not possible.

In mathematical terms, a one-way hash function can be defined as follows:

Given a message M, and a one-way hash function H, it is easy to compute x such that H(M) = x. But given x and H, it is infeasible to get the message M. This can be shown mathematically as follows:

H(M) = x

H(x) ≠ M

Another property of hash functions is low collision probability. This means that given a message M, it is hard to find another message ...

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, interactive tutorials, and more.

Start Free Trial

No credit card required