Digital signatures provide message authentication, non-repudiation, and data integrity by using a combination of public-key cryptography and hash functions. The sender calculates a hash of the message and encrypts it with their private key to generate a digital signature. This signature is appended to the message before sending. The receiver decrypts the signature using the sender's public key and compares it to a hash of the received message. If they match, the signature is validated and message integrity and authentication are verified. Digital signatures do not provide privacy, but encryption of the signed message can be added for confidentiality.