How to create a message digest?
Creating a digest of a string message can be easily done using the general digester class
Digester. First we need to get an instance of
Digester, we call the class constructor and pass
SHA-1 as the algorithm.
After having a
Digester instance we create the message digest by executing or calling the
Digester.digest(byte binary) method of this class.