Authenticated encryption 2026-11-05
Authenticated encryption combines message confidentiality with protection against unauthorized alteration. Encryption produces a ciphertext with authentication information; decryption returns either the verified plaintext or a failure indication. Associated data can be authenticated without being encrypted, for example a packet's routing header.[ref]
An Interface and Algorithms for Authenticated Encryption by D. McGrew. RFC 5116, §2, authenticated encryption with associated data
For example, a receiver should reject a modified payment amount instead of releasing a plausible but corrupted plaintext. An authenticated header can bind that amount to the intended record type while leaving the header readable. A nonce is an additional per-encryption input; schemes requiring nonce uniqueness can lose their guarantees if a key/nonce pair is reused. The exact rule belongs to the selected construction. Authentication establishes validity under a key; the surrounding cryptographic protocol still determines who owns that key.[ref]
An Interface and Algorithms for Authenticated Encryption by D. McGrew. §§2.1–2.3 and §3.1, nonce requirements
Chosen-plaintext attack 2026-10-31
An attack in which an adversary selects plaintexts and obtains their encryptions, possibly choosing later requests adaptively.
Cipher Created 2026-09-29 Updated 2026-10-14
A cipher is a pair of keyed algorithms that maps a plaintext to a ciphertext and recovers the plaintext from the ciphertext when supplied with the appropriate key.
Ciphertext-only attack 2026-10-31
An attack using observed ciphertexts without supplied corresponding plaintexts. Recognisable message redundancy or publicly testable relations can sometimes provide key-testing predicates.
Cryptographic key 2026-11-05
A cryptographic key is a parameter selecting a particular transformation from a family of algorithms in cryptography. For an encryption family, correctness requiresfor every allowed plaintext and appropriate encryption/decryption keys. In symmetric-key cryptography, the communicating parties share a secret key. In public-key cryptography, the public encryption or verification key is paired with a private decryption or signing key.
For a one-bit example, and recover the message because applying exclusive or twice with the same bit cancels it. The one-time pad extends this to a uniformly random independent key as long as the message. Its secrecy depends on the key distribution and use, not on hiding the XOR algorithm. The number of possible keys gives a brute-force search space, but key length alone does not establish the security of a cryptographic construction.
Cryptographic security game 2026-11-05
A cryptographic security game is a precisely specified experiment defining what an adversary may observe and do, and what counts as success. Its rules include key generation, random choices, permitted queries, resource limits and a winning condition. Security statements bound the winning probability or a specified cryptographic distinguishing advantage, often as a function of a cryptographic security parameter. A reduction proves a result about that defined experiment, not every informal meaning of the word secure.[ref]
Practice-Oriented Provable-Security by Mihir Bellare. §§2.2 and 3.2, reductions and concrete security; §4.3, proofs and definitions
For an original one-challenge confidentiality game, an adversary chooses two equal-length plaintexts . A challenger samples an independent uniform bit , encrypts , and gives the ciphertext to the adversary, which returns a guess . In this simplified game there are no additional encryption or decryption queries. DefineRandom guessing has advantage zero. A success probability gives advantage . Another convention doubles this value; stating the normalization avoids a factor-of-two ambiguity when comparing bounds.
The one-time pad supplies a complete worked example. Let messages and the independently uniform key contain bits, and set . For any fixed -bit string and either challenge bit,since exactly one key gives that ciphertext. The ciphertext distribution is identical for and , so no function of it and the chosen messages can outperform guessing. The advantage is zero in this game.
Changing the rules can change the result. Reusing the pad for another message supplies the relation . A chosen-plaintext attack game grants access to encryptions selected by the adversary; a chosen-ciphertext attack game grants additional decryption access with carefully stated restrictions. The proof for the one-challenge experiment does not establish security under those extra observations.
A forgery game for a message authentication code instead asks for an accepted message/tag pair meeting its freshness condition. That is a different winning event from guessing an encrypted message. The cryptographic security game makes these distinctions inspectable and provides the exact target for a security reduction.
Decryption 2026-10-31
Recovery of a plaintext from a ciphertext using an appropriate key. Correctness requires the decryption operation to invert the specified encryption operation on supported messages.
Exhaustive key search Created 2026-10-31 Updated 2026-11-05
Trying candidate keys and testing them against known plaintext–ciphertext pairs or another available verification condition. A uniformly selected key in a space of size appears at average position in a fixed enumeration.
Known-plaintext attack 2026-10-31
An attack using one or more known plaintext–ciphertext pairs, without necessarily controlling the plaintexts.
The essential exponent condition isOtherwise the modular multiplicative inverse defining does not exist. For large prime numbers greater than three, this is equivalent toIf, for example, , the multiplicative group modulo has order divisible by three, and cubing is not a bijection; distinct plaintexts can have the same ciphertext. Unique decryption of all messages would then be impossible.
The prime numbers must also be distinct for the displayed totient formula, and selected sufficiently large and independently that integer factorization of is infeasible. A small factor, equal factors, or an exceptionally small difference between and gives an avoidable factorisation weakness. These size and generation conditions address security; the congruence condition addresses invertibility of cubing.
For distinct prime numbers , compute the Euler totient functionThe RSA cryptosystem private exponent is a modular multiplicative inverse of the public exponent:Use the extended Euclidean algorithm on and . It produces integers with , and reducing modulo gives a suitable positive . Searching through possible exponents is unnecessary.
To see correctness even for a plaintext sharing a factor with , write . Modulo , either or Fermat's little theorem gives ; the same holds modulo . The Chinese remainder theorem then gives . One may alternatively invert modulo , but inversion modulo is sufficient for this paper.
For each candidate nonzero offset , expansion givesConsequently, if is invertible, the candidate isCompute the modular multiplicative inverse using the extended Euclidean algorithm, then verify both and . The RSA cryptosystem cubing map is a bijection, so an accepted candidate cannot be a different plaintext with the same first ciphertext. This costs fewer than trials, each involving polynomially many operations in the bit length of .
There is a useful way to handle every denominator exception for a correct nonzero . Compute . If , this greatest common divisor factors , allowing ordinary RSA cryptosystem decryption. If , then . The permitted prime numbers are and much larger than , so is invertible modulo each. The equation would make a nontrivial cube root of one, impossible in a group of order coprime to three. Thus cannot occur for the correct nonzero offset under these hypotheses.
If the bound in the question is read as also allowing , then and there is no additional information: the problem reduces to inverting a single ordinary RSA cryptosystem ciphertext. The small-offset attack requires a nonzero difference; that is the natural reading of distinct related messages.
All calculations are in modular arithmetic modulo . Expand the two expressions appearing in the proposed quotient:The first is exactly times the second. Multiplication by the assumed modular multiplicative inverse therefore givesThe representative in is the plaintext. This RSA related-message attack uses a relation between messages to turn two cubic equations into a linear equation; it does not recover the private key or factor in the invertible case.
In case (1), the nontrivial greatest common divisor is one of the prime factors . Divide by it, compute with the extended Euclidean algorithm, and return .
In case (2), . The preceding value satisfies . Cubing is a bijection on the residue classes modulo , so there is only one such cube root, namely the original plaintext . ThereforeFor , the preceding value is ; a fixed point is its own plaintext. Keeping the previous iterate makes the recovery immediate once the RSA cycling attack succeeds.
In the Dolev-Yao model, an adversary controls the network: it can intercept, suppress, delay, replay and redirect messages, impersonate network senders, and construct messages from values it knows. In particular, it can concatenate or split unprotected tuples, and can apply encryption using any known public key or known symmetric key.
Cryptography is idealised. Without the required private key or symmetric key, the adversary cannot recover a protected plaintext or construct an otherwise unavailable protected value. It cannot invent an unknown long-term secret merely because the containing ciphertext is visible. Protocol failures arise from the arrangement of messages even when these cryptographic primitives behave perfectly.
In a ciphertext-only attack, the adversary sees ciphertexts but has no supplied corresponding plaintexts. In a known-plaintext attack, it also knows one or more matching plaintext–ciphertext pairs. In a chosen-plaintext attack, it can select plaintexts and obtain their encryptions, possibly choosing later inputs from earlier results.
The ordinary exhaustive key search is a known-plaintext attack: given and , try candidate keys and compare with . A uniformly selected -bit key has average position in any fixed search order, so
This counts testing until the actual key is reached. One known pair may leave false candidate keys when is large relative to the block length ; additional pairs distinguish them. If a plaintext has recognisable redundancy, a ciphertext-only attack can sometimes test keys by that redundancy instead, but this is an additional assumption rather than the standard supplied-pair setting.
Let be the effective mask. For each position ,Thus the mask is always a palindrome, even though itself is uniformly random. The exclusive or of the ciphertext bits in a mirror pair isbecause the equal mask bits cancel. The observer learns the corresponding plaintext parity exactly. If is odd, the middle mask bit is also zero, so the middle plaintext bit is exposed directly.
An explicit failure of perfect secrecy works for every . Choose uniformly from and . For , the ciphertext is a palindrome with probability one. For and , toggling just the first bit breaks the mirror equality, so the ciphertext is a palindrome with probability zero. For , the effective mask is zero and . Observing therefore distinguishes these two messages perfectly.
There are only possible effective masks, each equally likely. Hence even a fresh -bit key supplies at most independent masking bits in this construction. Choosing a long, uniform, one-use key is insufficient if the encryption transformation collapses its randomness.
Perfect secrecy means that observing the ciphertext changes no probability concerning the plaintext. For every distribution of the message , and every with ,Equivalently, for every pair the conditional probability distributions of the ciphertext are identical:The randomness here comes from independent key generation and any encryption randomness. The claim is information theoretic: unlimited computation cannot extract information about from beyond what was known beforehand.
For encrypt-and-authenticate, the transmitted pair is with . The recovery map is public, so any observer computesNo symmetric key, exhaustive key search or oracle is needed. Publishing this message-recovery digital signature reveals the entire plaintext and breaks cryptographic confidentiality outright. A digital signature of a suitable digest would have different leakage properties, but the printed construction signs the raw block.
For encrypt-then-authenticate, choose any -bit string and computeSend . The receiver's correct check for this composition is before decryption, so it passes by construction. The receiver obtains a plaintext , although the adversary may not know it.
The finite domains justify the signature relation: is the identity on messages, so is injective and therefore bijective. Hence and also is the identity. The chosen is therefore exactly , without the adversary ever evaluating .
This is a key-only signature attack against raw unrestricted trapdoor signing. It does not invert at a chosen target and does not contradict the assumption that signing an independently specified new message is hard. It exploits choosing the digital signature first. The observation concerns the paper's raw construction, rather than every encrypt-then-authenticate scheme.
