A public key is a cryptographic key meant to be shared openly. It belongs to a pair of mathematically related keys. The matching private key must stay confidential. Anyone can use the public key to encrypt a message for its owner or verify a digital signature made with the private key. section 14.2
Sending a confidential message
Suppose Alice wants to send Bob a confidential message. She encrypts it with Bob’s public key; Bob decrypts it with his private key. Alice does not need a copy of Bob’s private key. But this alone does not prove Alice sent the message: anyone could use Bob’s public key to encrypt one. section 14.2.2
A public key also helps check who signed a document. The signer creates a digital signature using their private key and a hash of the document. A recipient uses the signer’s public key to verify the signature and compares hashes to check whether the document changed. This supports integrity and non-repudiation, provided the private key remains under the signer’s control. section 14.2.5
|
Property
|
Method
|
|
Confidentiality
|
• Sender
encrypts with the receiver's public key
• Receiver
decrypts with their own private key
|
|
Non-repudiation
|
• Sender signs
with their own private key
• Receiver
verifies with the sender's public key
|
Use the comparison to keep the two directions straight: encrypt with the recipient’s public key for confidentiality; verify with the sender’s public key for a signature. section 14.2.2
A freely shared key still needs a trustworthy owner. An attacker who substitutes their own public key could impersonate someone else. Public key infrastructure (PKI) addresses this problem with digital certificates that link public keys to verified identities. The protection depends on sound management of the keys and the entities that verify them. section 14.2.6
Public distribution avoids the need to share a secret key directly. It also scales differently from symmetric encryption: a 100-person company would need 100 public–private key pairs rather than 4,950 distinct shared keys for every pair of employees. Asymmetric encryption is slower, however, and is less practical for bulk data encryption. section 14.2.3








