Two more things are desired for secure communication: The recipient wants to know if the sender is really the one he seems to be and the message is really the one the sender sent originally. Ensuring this is called a ``signature''.
For prooving his identity, the sender uses his secret key. Without knowing it, the recipient can check it by using the well-known public key of the refered person. However, he still does not know, whether the message is the one originally sent.
In order to achieve this, Hashes are used. A hash is a sort of a checksum, which is being computed over the text. The algorithm used for this checksum (hash value), however, needs to make sure, that changing a bit can not easily be compensated with changing another one. The hash value itself is protected by mangling it with the secret key. Ideally, no two different texts would result in the same hash value. In practice, the hash values used are much shorter than the text itself and therefore it is in theory possible to find different texts with the same hash value. The better the algorithm the more difficult to find it. Commonly used algorithms include MD5, SHA1, RIPEMD160.