Alice uses a hash function to create a MAC from the concatenation of the key and
the message, h(K + M). She sends the message and the MAC to Bob over the insecure
channel. Bob separates the message from the MAC. He then makes a new MAC from
the concatenation of the message and the secret key. Bob then compares the newly created
MAC with the one received. If the two MACs match, the message is authentic and
has not been modified by an adversary.