In cryptography, a message authentication code (MAC), sometimes known as a "tag", is a short piece of information used to authenticate a message—in other words, to confirm that the message came from the stated sender (its authenticity) and has not been changed.