Decryption is the recovery of original, usable data—called plaintext—from encrypted data, called ciphertext, using the appropriate cryptographic algorithm and decryption key. Encryption turns plaintext into ciphertext—the opposite direction. Plaintext means unencrypted data, which may be a document, image or other binary file rather than readable words. Ciphertext is defined by its encrypted state, not by whether it looks like garbled writing.
How Decryption Works
Cryptographic software applies the corresponding algorithm to the ciphertext using the matching key and any accompanying parameters required by the scheme. The algorithm specifies the transformation, while the key supplies the value needed to reverse it. For example, some schemes also require a nonce, a nonsecret input that may be stored with the ciphertext or reconstructed before recovery. Any additional required values must be available or reconstructible. With correct inputs and successful operation, the software recovers the original data bytes.
In a public-key encryption scheme, a sender's software applies the chosen algorithm to plaintext with the recipient's public key and any required parameters to produce ciphertext. The recipient's software uses the corresponding private key, matching algorithm and required parameters to recover the original plaintext on success. Not every operation using a public/private key pair performs encryption. Signing creates a digital signature and verification checks it; signing is not “private-key encryption.” Key agreement establishes shared keys for later cryptographic operations rather than recovering plaintext.
Keys by Encryption Scheme
| Feature | Symmetric encryption | Public-key encryption |
|---|---|---|
| Key type | Symmetric encryptionOne shared secret key | Public-key encryptionRelated public/private key pair |
| Encryption key | Symmetric encryptionShared secret key | Public-key encryptionRecipient's public key |
| Decryption key | Symmetric encryptionSame shared secret key | Public-key encryptionRecipient's corresponding private key |
| Key access | Symmetric encryptionEncrypting and decrypting parties need secure access to the shared secret; publishing it with the ciphertext defeats its secrecy. | Public-key encryptionPublic key may be distributed; private key must remain protected. |
| Key exposure | Symmetric encryptionExposure of the usable secret key or usable access to it can let an attacker recover plaintext from available ciphertext protected by that key, including existing messages. | Public-key encryptionExposure of the usable private key or usable access to it can let an attacker recover plaintext from available ciphertext recoverable with that key, including existing messages. |
Looking for liquidity, exploring on-ramp/off-ramp services, or seeking expert guidance?
Get startedA Hypothetical File Example
In this hypothetical, conceptual example, a file named notes.txt contains “Meet at noon” in plaintext. Cryptographic software encrypts the file using a symmetric secret key K, the chosen algorithm and any required parameters, producing ciphertext represented by C. C is a placeholder, not a calculated cryptographic value. Assuming C is intact and all required inputs are available and correct, decryption with the matching algorithm, the same K and required parameters recovers “Meet at noon.”
What Recovery Does Not Prove
Encryption is intended to protect confidentiality: keeping information from unauthorized readers. Decryption makes the protected information usable again for a party able to use the appropriate key. Possessing or being able to use a key is a technical capability, not proof of authorization. Someone with stolen key access may therefore recover information without permission.
Recovery alone does not establish integrity or authenticity: it does not prove that data is unaltered or not forged. An appropriate authentication mechanism is needed. With a secure authenticated-encryption scheme used according to its requirements and a protected secret key, software checks authenticity and returns plaintext or rejects inputs that fail authentication. This does not, by itself, prove a particular person's identity.
Key Protection and Availability
Secret and private keys need protection against unauthorized access, including suitable storage; using cryptographic software does not by itself ensure secure storage.
Keys must also remain available for legitimate recovery. If necessary key material is permanently lost or destroyed and no usable copy or recovery path remains, encrypted data can become permanently inaccessible even when the ciphertext survives. Temporary inability to use a key is not the same as permanent loss.