A person can make a key out of numbers. This key has two parts, a private part that should not be shared and a public part that should be. These parts are mathematically related to each. To send a message to a computer, the message is encrypted with the sender's private key and the receiver's public key. This is done in such a way that the message can only be read if the receiver has their private key and the sender's public key. This means that an attacker cannot read the messages without both keys. 