Abstract
How much information does a message carry, how fast can it cross a noisy wire reliably, and what does protection against errors cost? Between 1924 and 1952 Nyquist, Hartley, Shannon, Hamming and Huffman supplied measurable answers. Hartley took the logarithm of the number of possible sequences; Shannon took the average of minus the log probability and called it entropy. Under his source models, lossless compression can approach the entropy rate, and over a discrete memoryless channel there are block codes with vanishing error at every fixed rate below capacity, a result proved by existence and not by construction. Hamming described a single-error-correcting code and Huffman an optimal binary prefix code; LDPC, turbo and polar codes later came close to capacity in their own benchmarks. The same quantities appear in security, with different metrics for different questions: min-entropy for first-guess success against random sources, guesswork and partial-guessing measures for passwords, equivocation in Wyner’s degraded wiretap channel, and mutual information for side-channel leakage. Massey showed that Shannon entropy can mislead about guessing. The calculations are small enough to check by hand.
The question
Three questions made information theory. How is information measured? How fast can it be sent reliably through a channel that corrupts it? What does error protection cost in redundancy? Shannon’s 1948 paper answered all three in one framework, and his 1949 paper on secrecy systems, which defines equivocation of the key and perfect secrecy, applied the same measures to secrecy.1
Shannon stated the engineering problem narrowly: “The fundamental problem of communication is that of reproducing at one point either exactly or approximately a message selected at another point.” The meaning of a message is irrelevant to that problem. What matters is that the message is one selected from a set of possible messages, and the system must work for every possible selection.2
The unit is the bit, a word Shannon credits to J. W. Tukey: a device with two stable positions, such as a relay, stores one bit, and N such devices store N bits because log2 of 2^N is N.2 Everything below is arithmetic in bits.
Security enters because an attacker’s uncertainty is a quantity of this kind. A key the attacker knows nothing about is a secret of so many bits, a password from a skewed distribution is a secret of fewer bits than its length suggests, and a timing measurement that reveals whether the first byte of a guess was right moves some fraction of a bit from the secret to the attacker. Perfect secrecy in Shannon’s 1949 sense belongs to a separate cryptography reader and is not developed here.
Before Shannon
Nyquist, 1924
Harry Nyquist’s “Certain Factors Affecting Telegraph Speed” (Bell System Technical Journal, April 1924) considers signal shaping and the choice of codes as the two factors limiting telegraph speed.3 On codes he gave the approximate formula W = K log m, where W is the speed of transmission of intelligence, m is the number of current values the line can take and K is a constant. By speed he means the number of characters that can be sent in a given time for a given rate of signal elements.3
His table of relative speed against number of current values runs: 2 values give 100, 3 give 158, 4 give 200, 5 give 230, 8 give 300 and 16 give 400.3 The entries follow the logarithm. Nothing in the formula involves probabilities or noise: it counts distinguishable symbols per signal element.
Hartley, 1928
R. V. L. Hartley presented “Transmission of Information” at the International Congress of Telegraphy and Telephony at Lake Como in September 1927, and the Bell System Technical Journal printed it in July 1928.4 He wanted a measure of information based on physical rather than psychological considerations. A sender makes n successive selections, each from s available symbols, so s^n different sequences are possible. The count itself is a poor measure, because it grows exponentially with the number of selections. Requiring two systems that can produce the same number of sequences to carry the same information, he arrived at
H = n log s
and summarised it in his own words: “What we have done then is to take as our practical measure of information the logarithm of the number of possible symbol sequences.”4
In his Baudot example one selection carries log 2, a five-selection character 5 log 2 and one hundred characters 500 log 2; the base of the logarithm fixes the unit. Raising the number of current values from 2 to 10 multiplies the information of a given number of selections by log 10 over log 2, which he gives as 3.3.4
The measure has two limits that Shannon removed. It counts possibilities and does not weight symbols by probability. And it has no probabilistic model of symbol errors: Hartley does analyse intersymbol interference and when it makes symbols indistinguishable, but as a physical limit on how many symbols can be told apart, not as a statistical channel.4 Shannon’s introduction says he extends the theory to include “the effect of noise in the channel, and the savings possible due to the statistical structure of the original message and due to the nature of the final destination of the information.”2
Shannon, 1948
The communication model
Shannon’s “A Mathematical Theory of Communication” appeared in the Bell System Technical Journal in July and October 1948.2 Its schematic system has an information source that selects a message, a transmitter that turns it into a signal, a channel with a source of noise, a receiver that reconstructs the message, and a destination. Discrete sources are modelled as finite-state Markov processes, and the theorems below assume the source is ergodic.2 Source coding removes statistical redundancy; channel coding adds redundancy of a chosen kind to resist noise.
Entropy
Suppose n events have probabilities p1 to pn. Shannon asks for a measure H of how much “choice” is involved in the selection, or how uncertain the outcome is, and requires three properties: H should be continuous in the probabilities; if all n probabilities are equal, H should increase with n; and if a choice is broken into two successive choices, the original H should be the weighted sum of the individual values of H.2 His example of the third property uses probabilities 1/2, 1/3, 1/6, which can be produced by first choosing between two equal halves and then, in the second half, choosing between 2/3 and 1/3:
H(1/2, 1/3, 1/6) = H(1/2, 1/2) + (1/2) H(2/3, 1/3)
His Theorem 2 states that the only H satisfying the three assumptions has the form H = -K sum p_i log p_i with K a positive constant, which fixes the unit.2 He says the theorem is “in no way necessary for the present theory” and lends plausibility, and notes that the form is that of entropy in statistical mechanics.2
Worked examples, in base-2 logarithms:
- A fair coin:
H = -(1/2 log2 1/2 + 1/2 log2 1/2) = 1bit. - A coin that lands heads with probability 0.9:
H = -(0.9 log2 0.9 + 0.1 log2 0.1) = 0.469bits. The outcome is usually heads, so on average the toss resolves less than half a bit of uncertainty. - Shannon’s four-letter source A, B, C, D with probabilities 1/2, 1/4, 1/8, 1/8:
H = 1/2(1) + 1/4(2) + 1/8(3) + 1/8(3) = 7/4bits per symbol. The maximum for four symbols is log2 4 = 2 bits, reached when each has probability 1/4, so Shannon calls the ratio 7/8 the relative entropy of this source.2
Shannon’s “relative entropy”, the ratio of entropy to its maximum, is a different quantity from the Kullback-Leibler relative entropy discussed later.
The source coding theorem
Entropy matters because it is the rate at which a source can be compressed. For an ergodic source with entropy H per symbol (the entropy rate when symbols depend on one another), Theorem 3 states that for any small positive numbers epsilon and delta, sequences of N symbols with N large enough fall into two classes: a set of total probability less than epsilon, and the rest, all of whose members have probability p satisfying |(log 1/p)/N - H| < delta.2 The typical sequences are therefore close in per-symbol log probability, which is a statement about exponents: their probabilities need not be close in ratio. Shannon’s practical reading is that for most purposes long sequences can be treated as though there were just 2^(HN) of them, each of probability 2^(-HN).2
Theorem 9 turns this into a statement about channels. Let a source have entropy H bits per symbol and a noiseless channel have capacity C bits per second. Then the source output can be encoded to transmit at an average rate of C/H minus epsilon symbols per second, for any positive epsilon, and no encoding can exceed an average rate of C/H.2 In the limit of long blocks and for average rate, compression to the entropy is achievable and compression below it is not.
The four-letter source shows the bound being met exactly. Shannon gives the code A = 0, B = 10, C = 110, D = 111. The average length is 1/2(1) + 1/4(2) + 1/8(3) + 1/8(3) = 7/4 binary digits per symbol, equal to H, and the coded sequence has the digits 0 and 1 each with probability 1/2, so its own entropy is one bit per digit.2 This is the sense in which compressed data looks random, taken up again below.
The redundancy of English
Shannon defines redundancy as one minus the relative entropy. For ordinary English, “not considering statistical structure over greater distances than about eight letters”, he put the redundancy at roughly 50 percent: “when we write English half of what we write is determined by the structure of the language and half is chosen freely.”2 That is an estimate from a statistical model of letter sequences, and not a statement that particular characters of a text are redundant.
His 1951 paper “Prediction and Entropy of Printed English” (Bell System Technical Journal, January 1951) estimated the same quantities with a new method: people guess the next letter of a text given the preceding letters, and the number of guesses needed bounds the entropy.5 The paper reports series of approximations F0 to F3 and a word-based estimate. For a 26-letter alphabet they are 4.70, 4.14, 3.56, 3.3 and 2.62 bits per letter, where F0 = log2 26 is the case of independent equiprobable letters and F1 uses letter frequencies.5
In the prediction experiment a subject guessed each letter of passages from a book given the preceding letters. For 100 preceding letters, with the 27-symbol alphabet, the bounds computed from the data were an upper bound of 1.3 and a lower bound of 0.6 bits per letter, and the abstract summarises: “in ordinary literary English, the long range statistical effects (up to 100 letters) reduce the entropy to something of the order of one bit per letter, with a corresponding redundancy of roughly 75%.”5 The lower bound was proved only for an ideal predictor that ranks its guesses perfectly, so the 0.6 is a sample-based estimate under that assumption, and Shannon warns that the figures still carry considerable sampling error.5 The maximum for that alphabet is log2 27 = 4.76 bits per symbol (4.7 for 26 letters), so the useful claim is the order of magnitude: about one bit per letter against 4.76.
The noisy channel
When the channel is noisy, the received symbol y does not determine the transmitted symbol x. Shannon calls the conditional entropy Hy(x) the equivocation, the average uncertainty about what was sent after what was received is known. The rate of transmission is then R = H(x) - Hy(x), equivalently H(x) + H(y) - H(x,y), the amount sent less the uncertainty about what was sent.2 The capacity is the largest rate over all input sources:
C = Max ( H(x) - Hy(x) )
One might expect that driving the error probability to zero requires a rate that falls to zero. Shannon’s answer: “it is possible to send information at the rate C through the channel with as small a frequency of errors or equivocation as desired by proper encoding. This statement is not true for any rate greater than C.”2 His Theorem 11 states it. If the source entropy H per second is at most C, there is a coding system that transmits the source output with arbitrarily small frequency of errors. If H exceeds C, the source can be encoded so that the equivocation is less than H minus C plus epsilon, and no encoding gives an equivocation below H minus C.2 Of rates above C he says: “Nature takes payment by requiring just that much uncertainty.”2 The modern form of the forward half, for a discrete memoryless channel, is that for every fixed rate strictly below capacity there are block codes whose decoding error probability goes to zero as the block length grows.
What the theorem proves and what it does not matters for everything that follows. Shannon proves the first part “not by exhibiting a coding method having the desired properties, but by showing that such a code must exist in a certain group of codes”, an averaging argument over randomly chosen codes. In his discussion he adds that apart from trivial cases and limiting situations, “no explicit description of a series of approximation to the ideal has been found.”2 The rest of coding theory is the search for explicit, efficiently decodable codes.
For the binary symmetric channel, which flips each bit independently with probability p, the capacity is C = 1 - H(p) bits per use, where H(p) is the binary entropy; for a discrete memoryless channel the single-letter capacity is the maximum of the mutual information over input distributions, and MacKay’s textbook gives this expression.6 At p = 0.11, H(0.11) = 0.4999, so C = 0.500084, essentially half a bit per transmitted bit. The theorem then says that any rate below 0.500084 can be made arbitrarily reliable by long enough codes, and that a rate of 0.51 cannot, whatever the code.
Codes at this p put numbers on it. Sending each bit once has error rate 0.11 at rate 1. Three repetitions with a majority vote give 3p^2(1-p) + p^3 = 0.0336 at rate 1/3, and five give 0.0112 at rate 1/5. Repetition buys reliability by spending rate. Shannon’s theorem says that arbitrarily good reliability is available at any rate up to 0.5. Hamming’s seven-bit code, which sends 4 information bits in 7, has rate 4/7 = 0.571, above the capacity at this p, so no code of that rate can drive the error to zero here. Under standard single-error decoding its block of seven is decoded wrongly if two or more bits flip, which at p = 0.11 happens with probability 1 - (0.89^7 + 7 x 0.11 x 0.89^6) = 0.175.
The Gaussian channel
For a channel of bandwidth W perturbed by white thermal noise of power N, with average transmitter power limited to P, Shannon’s Theorem 17 gives
C = W log2((P + N) / N)
which is W log2(1 + P/N). He interprets it: by sufficiently involved encoding, binary digits can be transmitted at that rate with arbitrarily small frequency of errors, and it is not possible to transmit faster without a definite positive frequency of errors. To approach the limit the transmitted signals must approximate white noise in their statistical properties.2
A signal-to-noise ratio P/N of 15 gives W log2 16 = 4W bits per second, four bits per second per hertz. A ratio of 1 gives W log2 2 = W, one bit per second per hertz. At high signal-to-noise ratio, doubling the power adds only about W bits per second. Doubling the bandwidth doubles capacity if P/N is held fixed; with fixed transmit power and a fixed white-noise spectral density, the noise power N grows with W as well, so capacity does not double.
Source coding in practice
Prefix codes and the Kraft inequality
A symbol code assigns a binary string to each source symbol. A code is a prefix code if no codeword is the beginning of another, which lets a decoder read a stream without separators. MacKay states the Kraft inequality: the codeword lengths l_i of any uniquely decodable binary code satisfy sum 2^(-l_i) <= 1, and for any lengths satisfying it there exists a prefix code with those lengths.6 For Shannon’s code, lengths 1, 2, 3, 3 give 1/2 + 1/4 + 1/8 + 1/8 = 1, so the code is complete: no codeword can be added or shortened. MacKay’s Theorem 5.1 says that for any source there is a prefix code with expected length L satisfying H <= L < H + 1.6
Huffman, 1952
Shannon’s and Fano’s procedures can meet the entropy exactly only in special cases such as the dyadic source below; for a general source they approach it only for long blocks. Huffman’s paper, received 6 December 1951 and printed in the Proceedings of the IRE in September 1952, says of those procedures that they “are not optimum, but approach the optimum behavior when N approaches infinity”, and that no definite procedure had been suggested for the best code for a finite ensemble.7 Huffman supplied one. His summary: “An optimum method of coding an ensemble of messages consisting of a finite number of members is developed. A minimum-redundancy code is one constructed in such a way that the average number of coding digits per message is minimized.”7 He imposes two restrictions, that no two messages have identical codes and that the code needs no punctuation, so that no message code is the first part of a longer one.7
The construction rests on the observation that an optimal binary prefix code can be chosen so that the two least probable messages are deepest siblings, with codes differing only in their last digit. Merge them into one composite message whose probability is the sum, giving a smaller ensemble. Assign 0 and 1 as final digits to the two members of each merged pair. Repeat, in Huffman’s words, “again and again until the number of members in the most recently formed auxiliary message ensemble is reduced to two.”7
For the source 1/2, 1/4, 1/8, 1/8:
- Merge the two 1/8 symbols C and D into one of probability 1/4. The ensemble is now A at 1/2, B at 1/4, CD at 1/4.
- Merge B and CD into one of probability 1/2, leaving A at 1/2 and BCD at 1/2.
- Give A the digit 0 and BCD the digit 1. Within BCD, give B the digit 0 and CD the digit 1. Within CD, give C the digit 0 and D the digit 1.
The codewords are A = 0, B = 10, C = 110 and D = 111, the same lengths as Shannon’s code, with an average of exactly 1.75 bits per symbol, equal to the entropy. When all probabilities are powers of 1/2 a prefix code reaches the entropy exactly. When they are not, the bound H <= L < H + 1 leaves up to a bit of slack per symbol, and the slack matters most for skewed sources. Take the coin with probabilities 0.9 and 0.1. Its entropy is 0.469 bits, but any prefix code must spend at least one digit per symbol. Coding pairs of symbols, with probabilities 0.81, 0.09, 0.09 and 0.01, Huffman’s procedure merges 0.09 and 0.01 into 0.10, then 0.09 and 0.10 into 0.19, then 0.81 and 0.19. The lengths are 1, 2, 3 and 3 and the average is 0.81 + 0.18 + 0.27 + 0.03 = 1.29 digits per pair, or 0.645 per symbol. Longer blocks approach 0.469.
MacKay notes the limits of ordinary symbol-by-symbol Huffman coding over an alphabet of two or more symbols. It spends at least one bit per symbol, which is wasteful when the next symbol is highly predictable from context: in the context “strings_of_ch” the next nine symbols could be predicted with probability 0.99 each, yet a Huffman code spends at least nine bits where virtually no information is conveyed. It also assumes a fixed ensemble, and real data changes its statistics.6
Lempel and Ziv, 1977
Jacob Ziv and Abraham Lempel’s “A Universal Algorithm for Sequential Data Compression” (IEEE Transactions on Information Theory, May 1977) addresses the case where “no a priori knowledge of the source characteristics is available.”8 Their scheme employs “maximum-length copying from a buffer containing the recent past output”; in the paper each codeword carries a pointer into the buffer, a length and one next symbol. The introduction names the main drawback: susceptibility to error propagation if a channel error occurs.8
A short LZ77-style parse, an illustration of the idea and not the paper’s exact encoding, uses the string abababcabababc (14 characters). The parser looks for the longest earlier match but keeps the last character of the remaining text back for the mandatory next-character field of the triple, so a match never covers that character. It emits an (offset, length, next character) triple and moves on.
- Position 0, no history: (0, 0, a). Position 1: (0, 0, b).
- At position 2 the text is
ababc.... The longest match starts two characters back and runs for 4 characters (abab), copying from text that overlaps the part being produced, followed by the new character c: (2, 4, c). Seven characters are now consumed. - At position 7 the remaining text is
abababc. The match starts seven back and runs 6 characters (ababab), followed by c: (7, 6, c).
Four triples describe the fourteen characters; whether that is shorter in bits depends on how wide the fields are. The decoder rebuilds the text by copying, so it needs no statistical model, only the rule. The overlapping copy in step 2 is why a match may be longer than its offset; the paper’s “reproducible extension” covers it.8 “Universal” has a specific meaning in the paper: its abstract investigates performance against a nonprobabilistic model of constrained sources, and states that the compression ratio of the universal code approaches the lower bounds attainable by block-to-variable and variable-to-block codes designed to match a completely specified source, with no prior knowledge of the source.8
Why compressed and encrypted data look random
In Shannon’s coded example the digits 0 and 1 each occur with probability 1/2, and the entropy of the coded sequence is one bit per digit.2 The general inference is narrower: an efficient code under a given source model removes the redundancy that the model describes. That does not make an arbitrary compressed file a sequence of independent fair bits, and balanced bit frequencies do not prove optimal coding. Kelsey describes the design goal of ciphers such as AES and triple-DES as output that “carries no information about that plaintext except its length.”9 Length is the point: when data are compressed before encryption, the observable length can correlate with content, depending on the protocol, the compression context and any padding. Kelsey calls this leak a property of the compression algorithm and not of an implementation, so the same compressor under the same conditions yields the same lengths, and he separates settings where leakage matters from, for example, bulk encryption applications, where he judges the impact small.9
Channel coding in practice
Hamming, 1950
Richard Hamming’s “Error Detecting and Error Correcting Codes” (Bell System Technical Journal, April 1950) begins with large-scale computing machines, in which a single error in a long computation invalidates the result. The two Model 5 relay computers built for the Aberdeen Proving Grounds had about two or three relay failures per day in 8,900 relays, one per two to three million relay operations. Self-checking detected them but the unattended machines then stopped, so “it appears desirable to examine the next step beyond error detection, namely error correction.”10
His definitions are geometric. A code symbol is a string of n binary digits, a point in a space of 2^n points, the vertices of a cube. The distance between two points is the number of coordinates in which they differ. With minimum distance 2 any single error produces a non-code point and is detectable; with minimum distance 3 a single error leaves the received point nearer to the correct code point than to any other, so it is correctable; distance 4 adds double-error detection.10
He defines a systematic code as one with m information digits and k = n - m check digits, and the redundancy as R = n/m, which “may be said to lower the effective channel capacity for sending information.”10 This is a ratio of lengths, and it differs from Shannon’s one minus the relative entropy, so the two uses of “redundancy” have to be kept apart. A Hamming ball of radius 1 (the code point plus its n neighbours; Hamming’s own “sphere” means the points at exactly the stated distance) holds n + 1 points, and for single-error correction the balls cannot overlap, so a code can have at most 2^n / (n+1) code points.10 For n = 7 that is 128/8 = 16 code points, and Hamming’s construction reaches the bound, with 16 code symbols and 112 meaningless symbols.10
The Hamming (7,4) code by hand
Hamming numbers the positions of a seven-digit word 1 to 7. The check digits sit at positions 1, 2 and 4, the powers of two, and the information digits at 3, 5, 6 and 7. Check 1 covers the positions whose binary representation has a 1 in the last place (1, 3, 5, 7), check 2 covers those with a 1 in the second place (2, 3, 6, 7), and check 4 covers those with a 1 in the third place (4, 5, 6, 7).10 Each check digit is chosen to make the sum of its positions even.
Encode the information bits 1 0 1 1 at positions 3, 5, 6, 7, so x3 = 1, x5 = 0, x6 = 1, x7 = 1.
x1makesx1 + x3 + x5 + x7even: 1 + 0 + 1 = 2, sox1 = 0.x2makesx2 + x3 + x6 + x7even: 1 + 1 + 1 = 3, sox2 = 1.x4makesx4 + x5 + x6 + x7even: 0 + 1 + 1 = 2, sox4 = 0.
The codeword is 0110011. Suppose the channel flips position 5, delivering 0110111. The receiver recomputes the three sums. Check 1 over positions 1, 3, 5, 7: 0 + 1 + 1 + 1 = 3, odd, so 1. Check 2 over 2, 3, 6, 7: 1 + 1 + 1 + 1 = 4, even, so 0. Check 4 over 4, 5, 6, 7: 0 + 1 + 1 + 1 = 3, odd, so 1. Read the results as a binary number with check 4 first: 101, which is 5. The syndrome names the position of the error, and flipping position 5 restores 0110011. Under the single-error assumption a syndrome of 000 means no error, although some multi-bit errors also give 000. Shannon’s 1948 appendix gives the same construction: the binary number from the checks “gives the subscript of the Xi that is incorrect (if 0 there was no error).”2
If two bits flip, the syndrome is still some nonzero number, the decoder “corrects” a third position, and the output is wrong. Distance 3 corrects one error and no more.
Algebraic codes and the long road to capacity
Costello and Forney’s survey “Channel Coding: The Road to Channel Capacity” describes the 1960s as dominated by algebraic block codes, which use finite-field algebra to guarantee a minimum distance and allow efficient bounded-distance decoding. It calls the invention of the Bose-Chaudhuri-Hocquenghem and Reed-Solomon codes, in three independent papers in 1959 and 1960, the “big bang” of the field, and says Reed-Solomon codes were quickly recognised as nonbinary BCH codes.11
A Reed-Solomon code over a field of q = 2^m elements can have block length up to q + 1 and dimension k = n - d + 1, which meets the Singleton bound, so these codes are optimum in that sense.11 Reed and Solomon’s paper appeared in the Journal of the Society for Industrial and Applied Mathematics in June 1960 (DOI 10.1137/0108018);12 the description here relies on Costello and Forney’s account, not on the paper. They report its first major applications as the 1977 Voyager mission, with a (255, 223, 33) code over a field of 256 elements as the outer code, and the 1980 compact disc standard.11
Gallager’s low-density parity-check codes, 1963
Robert Gallager’s low-density parity-check codes appear in his 1960 MIT doctoral thesis,13 in a paper in the IRE Transactions on Information Theory (IT-8, January 1962, pp. 21-28),14 and in the 1963 monograph, whose preface is dated July 1963. The monograph begins from the diagnosis that the primary obstacle to using Shannon’s theorem “has been the equipment complexity and the computation time required to decode the noisy received data.”15 Decoding long codes, he says, “appears to be much more difficult than the problem of encoding.”15
A parity-check code is defined by a matrix of 0s and 1s, each row a parity equation the codeword must satisfy modulo 2; Gallager’s Figure 1.2 shows a 3 by 7 example.15 The new idea of the low-density codes is that the matrix is sparse, with few 1s in each row and column. Gallager’s decoder works with the a posteriori probabilities of the digits and avoids hard decisions first, because an intermediate hard decision “destroys a considerable amount of information about the transmitted message.”15
MacKay writes that they “were invented by Gallager in 1962 but were promptly forgotten by most of the coding theory community” and rediscovered in 1995.6 Costello and Forney say the work was “largely forgotten for more than 30 years”, that it is easy to understand why it drew little interest in the 1960s and 1970s since the codes were too complex for the technology of the time, and that it is “not so easy to explain” why they were ignored up to the mid-1990s.11 They also report two rate-1/2 designs for the AWGN channel: one with a theoretical threshold within 0.0045 dB of the Shannon limit, and one simulated with block length 10^7 within 0.040 dB at a bit error rate of 10^-6.11
Turbo codes, 1993
Claude Berrou, Alain Glavieux and Punya Thitimajshima presented “Near Shannon Limit Error-Correcting Coding and Decoding: Turbo-Codes” at the IEEE International Conference on Communications in 1993.16 The code is a parallel concatenation of two recursive systematic convolutional codes with a feedback decoder. For a rate-1/2 code on the additive white Gaussian noise (AWGN) channel they take an Eb/N0 of 0 dB as the benchmark for binary modulation, with a bit error rate of 10^-5 as the reference, and report performance 0.7 dB from it.16 Costello and Forney give two distinct benchmarks for the same kind of turbo code: about 0.7 dB from the Shannon limit at spectral efficiency 1 b/s/Hz, and about 0.5 dB from the Shannon limit for binary codes at that efficiency. They add that turbo codes with randomly constructed interleavers show an error floor at error rates somewhat below 10^-5, because the minimum distance of turbo codes cannot grow linearly with block length.11 They report that, shortly after the turbo breakthrough, researchers rediscovered Gallager’s codes.11
Polar codes, 2009
Erdal Arikan’s “Channel polarization: A method for constructing capacity-achieving codes for symmetric binary-input memoryless channels” (arXiv 0807.3917, version of 20 July 2009) opens with Shannon’s own gap. Shannon’s random-coding method showed the existence of capacity-achieving code sequences “without exhibiting any specific such sequence”, and “explicit construction of provably capacity-achieving code sequences with low encoding and decoding complexities has since then been an elusive goal.”17 Channel polarization synthesises, from N copies of a binary-input channel, N channels, with the fraction of nearly perfect ones converging to I(W) and the fraction of nearly useless ones to 1 - I(W) (Theorem 1); data go through the good ones. The paper’s result for its construction is that, for a binary-input discrete memoryless channel W with symmetric capacity I(W) > 0 and any target rate R < I(W), there is a sequence of polar codes of block length N = 2^n and rate at least R whose block error probability under successive cancellation decoding is bounded by O(N^(-1/4)), with encoding and decoding complexity O(N log N).17
Where the codes are used
Costello and Forney, writing in 2006, list LDPC codes adopted for DVB-S2 and 10GBASE-T Ethernet.11 In 3GPP TS 38.212 V16.2.0, Table 5.3-1 assigns LDPC coding to the UL-SCH, DL-SCH and PCH transport channels and polar coding to the BCH, and Table 5.3-2 assigns polar coding to downlink control information, and polar or block coding to uplink control information, the choice depending on payload size (section 6.3).18 A review by Mody Sy of EURECOM (arXiv 2502.11053, first submitted 16 February 2025; version 4, 31 October 2026) follows Release 16 and gives high throughput, a range of block sizes and rates, and hybrid automatic repeat request as the rationale for LDPC on shared channels.19 Performance claims in this lineage are of different kinds: Arikan’s theorem is asymptotic, the 0.0045 dB LDPC figure is an asymptotic threshold, and the 0.040 dB LDPC and the turbo gaps are finite-block simulations at stated error rates, so the figures cannot be used to rank the code families directly.
Relative entropy and mutual information
The Kullback-Leibler measure
Solomon Kullback and Richard Leibler’s “On Information and Sufficiency” (Annals of Mathematical Statistics 22(1), 79-86, March 1951; DOI 10.1214/aoms/1177729694) asks how well observations discriminate between two hypotheses.20 If H1 says an observation x came from a population with density f1 and H2 says f2, they call log f1(x)/f2(x) “the information in x for discrimination between H1 and H2.” The mean information for discrimination per observation under H1 is
I(1:2) = integral f1(x) log( f1(x) / f2(x) ) dx
and they define the symmetric sum J(1,2) = I(1:2) + I(2:1), which they call the divergence.20 The one-directional quantity I(1:2) is the object now usually called the Kullback-Leibler divergence or relative entropy.
For distributions P and Q over a discrete alphabet, MacKay defines D(P||Q) = sum P(x) log2( P(x)/Q(x) ). It satisfies Gibbs’ inequality, D(P||Q) >= 0, with equality only if P = Q, and it is not symmetric, so “KL distance” is not strictly a distance.6
A small example shows the asymmetry. Let P be a fair coin (1/2, 1/2) and Q a biased one (3/4, 1/4). Then
D(P||Q) = 1/2 log2( (1/2)/(3/4) ) + 1/2 log2( (1/2)/(1/4) ) = 1/2(-0.585) + 1/2(1) = 0.2075bits.D(Q||P) = 3/4 log2( (3/4)/(1/2) ) + 1/4 log2( (1/4)/(1/2) ) = 3/4(0.585) + 1/4(-1) = 0.1887bits.
The two directions give different answers, and the symmetric divergence of Kullback and Leibler is their sum, 0.3962 bits.
MacKay’s coding interpretation makes the number concrete: D(p||q) measures how many bits per symbol are wasted by using a code whose implicit probabilities are q when the true distribution is p. Use the code with lengths 1, 2, 3, 3 for a source that is actually uniform over the four letters. The average length is (1 + 2 + 3 + 3)/4 = 2.25 bits, against an entropy of 2, and the excess of 0.25 bits equals D(uniform || (1/2, 1/4, 1/8, 1/8)) = 0.25.6 By the definition above, I(1:2) is also the mean of the log likelihood ratio when H1 is true, so it is the average evidence per observation in favour of the true hypothesis.
Mutual information and the data-processing inequality
The rate Shannon defined for the noisy channel, H(x) - Hy(x), is the mutual information between input and output, an average over the modelled joint distribution, and for a discrete memoryless channel capacity is its maximum over input distributions. MacKay writes C = max I(X;Y).6 It is the average number of bits of x revealed by observing y, symmetric in the two variables, equal to H(x) for a noiseless channel and zero when y is independent of x.
The data-processing inequality says that processing cannot add information. MacKay states it as an exercise: if the ensembles W, D and R form a Markov chain w to d to r, meaning r depends on w only through d, then the average information that R conveys about W is no more than the information D conveys about W, I(W;R) <= I(W;D).6 He adds that this “is as much a caution about our definition of ‘information’ as it is a caution about data processing!” In his treatment of channel coding the inequality supplies one step of the converse: for a source S coded into channel inputs X, received as Y over N uses of a discrete memoryless channel and decoded to an estimate S’, I(S;S') <= I(X;Y) <= NC.6 That display bounds mutual information only; the rest of the converse needs a further step (Fano’s inequality) connecting reliable decoding to the information about the message.
For security the inequality has a direct reading, offered as reasoning and not as a cited result: if an analysis uses only the modelled observation, or auxiliary information that is explicitly included in the model, it tells an attacker no more about the secret than that information did, so bounding the mutual information between the secret and the observation bounds what the analysis can extract on average.
Security in bits
Keys and uniform secrets
Assume a uniform prior and an attacker who can test one candidate at a time with a verifiable yes or no answer. A key drawn uniformly from 2^n possibilities has n bits of entropy and an attacker needs on average (2^n + 1)/2 guesses, which for n = 20 is 524,288.5; the base-2 logarithm of the expected guess count is about one bit below n. Shannon entropy and min-entropy coincide for a uniform distribution and diverge when it is skewed. The library’s post-quantum article, Harvest now, decrypt later, discusses quantum search against symmetric keys.
Passwords: three numbers that disagree
Let X be a secret with probabilities p1 >= p2 >= ... sorted from most to least likely. Three measures summarise it.
- Shannon entropy,
H = -sum p_i log2 p_i. - Guesswork, the expected number of guesses when the attacker tries values in order of decreasing probability,
G = sum i p_i. - Min-entropy,
H_min = -log2 p1, which depends only on the most likely value.
NIST SP 800-90B, the recommendation for entropy sources used to generate random bits, adopts min-entropy as “a very conservative measure” which “measures the effectiveness of the strategy of guessing the most likely output of the entropy source”, and notes that the probability of guessing a secret in the first trial is tied to the min-entropy: if X has min-entropy H, no value has probability above 2^(-H).21 The maximum min-entropy for k distinct values is log2 k, reached when they are uniform.21
Here is a distribution the reader can check by hand. Suppose a site’s users choose among eight very popular passwords, each by 5% of users, 40% in all, and the remaining 60% choose uniformly among 2^20 = 1,048,576 other passwords. The three measures are:
- Shannon entropy:
H = 8 x 0.05 x log2(20) + 0.6 x log2(2^20/0.6) = 1.73 + 12.44 = 14.17bits, so2^His about 18,445. - Guesswork: guess the eight popular passwords first, then the rest.
G = 0.05(1 + 2 + ... + 8) + (0.6/2^20)(9 + 10 + ... + (2^20 + 8)) = 1.8 + 314,577.9 = 314,579.7guesses, about 314,580, which is 18.26 bits. - Min-entropy:
-log2 0.05 = 4.32bits.
Which number describes the risk depends on the attacker. Min-entropy fixes the first-guess success probability, 5% in this example. The 40% that falls within eight guesses is the sum of the top eight probabilities, which min-entropy alone does not give. The 314,580 value is the expected number of guesses per sampled account under exhaustive ordered guessing. Shannon entropy at 14.17 bits corresponds to none of these attacks.
Massey’s guessing bound
James Massey’s 1994 paper “Guessing and Entropy” asks whether entropy determines interesting bounds on the expected number of guesses E[G] to find the value of a random variable X,, for instance a cryptanalyst trying keys one at a time. The optimum strategy guesses in decreasing order of probability.22 His result is a lower bound: E[G] >= (1/4) 2^H(X) + 1, provided H(X) is at least 2 bits. It is tight within a factor of 4/e when X is geometrically distributed, the maximum-entropy distribution for a given mean.22
For the password distribution above, Massey’s bound gives E[G] >= 18,445/4 + 1, approximately 4,612.28 guesses, about 68 times below the actual 314,580. A floor, and a loose one.
The second half of the paper is a warning. Massey shows that E[G] can be arbitrarily large while H(X) is an arbitrarily small positive number, so entropy gives no interesting upper bound on E[G].22 The author’s own illustration of that shape, not an example from the paper: let one password have probability 1 - 2^-10 and the remaining probability 2^-10 be spread uniformly over 2^40 others. The entropy is H = 0.0502 bits, about a twentieth of a bit. The guesswork is about 2^-10 x 2^39 = 2^29, roughly 5.4 x 10^8 guesses. Read as “easy to guess”, an entropy of 0.05 bits is right for 99.9% of the secrets and badly wrong for the expected effort. Read as “hard to guess”, the expectation misses that 99.9% of the secrets fall at the first guess. Neither number alone answers the question.
Min-entropy, guesswork and the practice that followed
SP 800-90B’s appendix on min-entropy and optimum guessing attack cost treats an adversary who wants to recover at least one of several independent secrets and may give up on a secret after k wrong guesses. It bounds the base-2 logarithm of the minimum expected work per success under that strategy, and shows that the min-entropy of the distribution “either corresponds to the exact expected work, measured in bits, needed to perform the optimum guessing attack or over-estimates this work by at most one bit.”21 So in that model min-entropy can overstate the attacker’s work by up to a bit, and never understates it. The appendix points to Cachin’s 1997 thesis on entropy measures in cryptography for more.21
Joseph Bonneau’s “The Science of Guessing” (IEEE Symposium on Security and Privacy, May 2012) examined anonymised password histograms from almost 70 million Yahoo! users. It says Shannon entropy and guessing entropy “cannot be estimated with any realistically sized sample”, and that Shannon entropy “has no direct correlation to guessing difficulty” for an attacker who guesses individual passwords, since it quantifies the average number of subset-membership queries.23 Guesswork has its own flaw on real data: in the RockYou leak more than twenty users appear to use 128-bit pseudorandom hexadecimal strings, which alone force the guesswork above 2^106.23 The paper introduces α-guesswork, parameterised by the fraction α of accounts an attacker wants to break, and estimates that, for that corpus and under its metrics, passwords provide fewer than 10 bits of security against an online trawling attack and about 20 bits against an optimal offline dictionary attack.23
The apparent disagreement among these sources is about the question each metric answers. NIST’s SP 800-90B rates random sources, Bonneau’s metrics describe human-chosen passwords sampled from a corpus, and SP 800-63B addresses password policy. NIST’s SP 800-63B (June 2017, updated 2020) says that user-chosen password complexity “has often been characterized using the information theory concept of entropy” and that “estimating the entropy for user-chosen passwords is difficult and past efforts to do so have not been particularly accurate”, so it presents a simpler approach built on password length. It tells verifiers to check candidates against a list of commonly used, expected or compromised values and not to impose composition rules.24 The current revision, SP 800-63B-4 (web edition dated 26 August 2025, superseding SP 800-63B), requires at least 15 characters for single-factor passwords and eight where the password is only part of multi-factor authentication, still checks candidates against a blocklist and forbids other composition requirements. Its glossary defines entropy as “the amount of uncertainty that an attacker faces to determine the value of a secret.”25 The library’s article on leaked credentials, Billions of leaked passwords, covers what protects an account in practice.
A related accounting appears in Where the data lives, and what it gives away, which reports the Netflix Prize re-identification study in these units. In Narayanan and Shmatikov’s experiment, two ratings and dates (with a 3-day error) sufficed to identify 68% of records; for the other 32%, “the additional information required for complete de-anonymization is only around 3 bits”, against 19 bits with no auxiliary information.26
Wyner’s wire-tap channel
Aaron Wyner’s “The Wire-Tap Channel” (Bell System Technical Journal, October 1975) asks what Shannon’s framework says about secrecy against a receiver who sees a corrupted copy of the signal. A transmitter sends digital data over a discrete memoryless channel, and a wire-tapper observes the channel output through a second noisy channel, and the code books are known to the wire-tapper. The designer wants to maximise both the rate R, measured in source bits per channel input symbol, and the equivocation d, the wire-tapper’s uncertainty about the data per source symbol. If d equals the source entropy H_S Wyner calls the transmission “in perfect secrecy”.27 Because d is normalised per symbol, this is what later work calls weak secrecy, which is weaker than a vanishing total mutual information between data and wire-tap output, or exact statistical independence at a finite block length.28
His introductory example has a noiseless main channel and a wire-tapper who sees each transmitted bit through a binary symmetric channel with crossover probability p0. Sending each bit directly gives rate 1 and wire-tapper equivocation h(p0). Alternatively, encode a source bit as a random N-bit vector of even parity for 0 or odd parity for 1. The receiver reads the parity of the noiseless vector. The wire-tapper sees it after N independent flips and learns the bit only through the parity of the number of errors, so given an even-parity observation the probability that the bit is 0 is 1/2 + 1/2 (1 - 2 p0)^N.27 The equivocation h(1/2 - 1/2 (1 - 2 p0)^N) approaches the full source entropy of 1 bit as N grows, at the cost that the rate K/N = 1/N goes to zero.27
With p0 = 0.11, so that 1 - 2 p0 = 0.78, the equivocation computed from Wyner’s formula is 0.4999 bits at N = 1, 0.899 at N = 4, 0.986 at N = 8 and 0.9997 at N = 16, at rate 1/N.
The main results settle the trade-off. Theorem 2 characterises the achievable (R, d) pairs, and for the special case of a noiseless main channel and a binary symmetric wire-tap channel with a fair source bit, the pair is achievable exactly when R and d lie between 0 and 1 and R d <= h(p0), a region that is not convex, which Wyner remarks differs from the convex regions usual in multi-user Shannon theory.27 Theorem 3 says that if the capacity C_M of the main channel exceeds the capacity C_MW of the cascade of the main and wire-tap channels, there is a “secrecy capacity” C_s with C_M - C_MW <= C_s <= C_M, the maximum rate at which data can be sent reliably in essentially perfect secrecy.27 In Wyner’s degraded-channel model, and as the author’s gloss, secrecy comes from the legitimate receiver having a better channel than the wire-tapper, with no shared key; the line of work now called physical-layer security starts from this model.
Side channels as unintended channels
A side channel is a communication channel nobody designed. The secret is the source, the implementation is the transmitter, and the attacker’s measurement is the received signal, which carries some part of the secret’s entropy. Shannon’s framework asks how much, and how fast.
Timing. Paul Kocher’s “Timing Attacks on Implementations of Diffie-Hellman, RSA, DSS, and Other Systems” (CRYPTO ‘96, pages 104 to 113, DOI 10.1007/3-540-68697-5_9)29 observes that cryptosystems “often take slightly different amounts of time to process different inputs”. His attacks “can exploit timing measurements from vulnerable systems to find the entire secret key.”30 Against a simple modular exponentiator the attacker works one exponent bit at a time: knowing the first b bits, the attacker can compute the first b iterations and predict the time of the next, which depends on the unknown bit. A wrong guess makes later predictions “essentially random”, so the attack has “an error-detection property”, and Kocher shows how to use that for error correction by keeping a ranked list of likely partial exponents.30 Kocher treats the attack as signal detection, with the number of measurements needed “proportional to the exponent size (w)”. In one RSAREF experiment (a 256-bit exponent processed two bits at a time, 250 measurements per comparison) he estimates a probability of about 0.84 that subtracting the correct iteration’s time reduces the variance more than an incorrect one, and reports 2,168 successes in 2,450 trials, 0.885. These are the author’s stated results for that setup, and his printed grouping and counts do not reconcile on their face, so they should not be extrapolated.30
David Brumley and Dan Boneh’s “Remote Timing Attacks are Practical” (12th USENIX Security Symposium, 2003)31 devised a different timing attack, because earlier attacks did not work against the optimised OpenSSL implementation, and demonstrated it across a network. In their experiment, they report that “using about a million queries we can remotely extract a 1024-bit RSA private key from an OpenSSL 0.9.7 server. The attack takes about two hours”, with the attacking machine and the server in different buildings. The figures are specific to that setup.32
Secret-dependent timing is a channel from the secret to the attacker. A comparison that returns at the first mismatching byte reveals something about how many leading bytes were right, and an attacker can combine many such measurements. They are correlated and noisy, so their information has to be analysed jointly or conditionally and not by adding single-measurement figures. The defence is a constant-time comparison; NIST’s SP 800-63B lists authenticator algorithms designed to maintain constant power consumption and timing regardless of secret values among its mitigations.24
Power. Kocher, Jaffe and Jun’s “Differential Power Analysis” (CRYPTO ‘99, pages 388 to 397, DOI 10.1007/3-540-48405-1_25)33 starts from the premise that “actual computers and microchips leak information about the operations they process” and examines methods for analysing power consumption measurements to find secret keys in tamper-resistant devices.34
Compression. John Kelsey’s “Compression and Information Leakage of Plaintext” (Fast Software Encryption 2002, pages 263 to 276) describes “a somewhat different kind of side-channel provided by data compression algorithms, yielding information about their inputs by the size of their outputs.” It reveals plaintext and not key material, and Kelsey calls it a property of the algorithm and not of the implementation: the same compressor under the same conditions gives the same lengths. A stateless channel uses the compression ratio of an unknown string; a stateful one uses a compressor that has adapted to earlier input, and the paper describes extracting a secret repeated in many compressed messages under partial chosen-plaintext assumptions.9 A guess that repeats text already in the compression window can cost fewer bits, and the observable ciphertext length can depend on the compressed plaintext length (Kelsey notes that some modes pad, which changes the transmitted length).9
Duong and Rizzo announced CRIME, a compression side-channel attack on HTTPS, at ekoparty in 2012. Gluck, Harris and Prado’s BREACH paper (12 July 2013) notes that the attack needs the ability to inject partial chosen plaintext into a victim’s requests and to measure the size of encrypted traffic, that disabling TLS-level compression mitigated CRIME as demonstrated, and that attacking HTTP responses works even with TLS compression off, because HTTP responses are commonly gzip-compressed and often contain secrets such as CSRF tokens next to user input.35 The CERT/CC note VU#987798, released 2 August 2013, reports the researcher’s description of the guessing procedure: “The correct guess will result in a smaller HTTPS response.”36 A pair of requests compares two sizes, which is evidence about one guessed character and not a guaranteed one-bit answer, and two channels with the same output alphabet size need not leak equally.
Leakage as mutual information. Standaert, Malkin and Yung’s “A Unified Framework for the Analysis of Side-Channel Key Recovery Attacks” (EUROCRYPT 2009, pages 443 to 461) proposes “a combination of information theoretic and security metrics, measuring the quality of an implementation and the strength of an adversary, respectively.” The information-theoretic metric is the conditional entropy of the key class S given the leakage L, which yields the mutual information I(S; L) = H[S] - H[S|L]. They write that mutual information is a relevant tool for comparing implementations, and they caution that conditional entropy “is not a stand-alone metric” because “there exists no general relation between information and security”, so it must be combined with a security analysis such as success rate.37 That repeats the lesson of Massey’s paper: one entropy figure does not settle how hard an attack is.
What a practitioner should take from it
- Measure secrets in bits only when the distribution is known. A uniformly random 128-bit key chosen with a uniform prior has 128 bits. A human-chosen password has no length-based entropy figure, and NIST’s guidance has moved from estimating one to checking against lists of known-bad values.24
- Name the attacker and the question before choosing a metric, and tie it to the decision. Estimating a random source: min-entropy, as in SP 800-90B. Setting an online guess budget: the success probability within the allowed guesses, which is the sum of the top k probabilities (min-entropy gives only the first-guess figure). Evaluating leakage: mutual information alongside attack success, since information alone does not fix security.212337
- SP 800-90B rates sources by min-entropy. In its many-independent-secrets model, min-entropy equals the base-2 logarithm of the optimal expected work per success or exceeds it by at most one bit, so it can overstate the work.21
- When compressed data are then encrypted, the observable length can correlate with content, depending on protocol, compression context and padding. Where an attacker can observe lengths and influence or know part of the input, treat length as a channel.935
- Whenever a secret influences something an attacker can observe, whether time, power, message length or response size, treat the observation as a channel. The questions are how much information each observation carries, how many observations the attacker can make and how correlated they are. Constant-time and constant-length designs reduce the first. For a service that can identify and constrain the queries, rate limiting reduces the second, as in the throttling requirements of SP 800-63B-4 for online authentication; it does nothing against measurements an attacker makes locally.303525
- Redundancy is the price of reliability. Shannon’s 1951 work estimates how well the next letter can be predicted from context; it does not itself establish cryptanalytic recovery of text, which depends on the cipher model of his 1949 paper.51
- A code with a rate above the capacity of its channel cannot be made reliable, and under the stated channel model codes below capacity exist with vanishing error.2
Annotated reference list
- Nyquist (April 1924).
W = K log mand the table of relative speeds; derivation in Appendix B.3 - Hartley (July 1928). The derivation of
H = n log s, and the section on intersymbol interference.4 - Shannon, “A Mathematical Theory of Communication” (1948). Theorems 2 (entropy), 3 and 4 (typical sequences), 9 (noiseless channel), 11 (noisy channel, an existence argument) and 17 (Gaussian channel).2
- Shannon, “Communication Theory of Secrecy Systems” (1949). Equivocation of the key and perfect secrecy; the subject of a separate reader.1
- Shannon, “Prediction and Entropy of Printed English” (January 1951). The table of F_N estimates and the experimental bounds (27 symbols, ideal predictor).5
- Hamming (April 1950). Distance, check positions 1, 2, 4 and the seven-position code; the sphere-packing bound.10
- Kullback and Leibler (March 1951; DOI 10.1214/aoms/1177729694). Printed pages 80 and 81: the log ratio,
I(1:2)andJ(1,2). Today “divergence” usually names the one-directional form.20 - Huffman (September 1952). The merge procedure and its restrictions; the limits of symbol-by-symbol coding are in MacKay.76
- Gallager (1960 thesis; January 1962 paper; 1963 monograph). Preface and chapter 1: parity-check matrix, Figure 1.2, probabilistic decoding.131514
- Reed and Solomon (June 1960; DOI 10.1137/0108018). Described here from Costello and Forney, not from the paper.1211
- Wyner (October 1975). The parity example in section I, Theorem 2 (rate and equivocation region) and Theorem 3 (secrecy capacity); the secrecy notion is normalised and asymptotic.27
- Ziv and Lempel (May 1977). The encoding process with its ternary example, and the compression-ratio bound for constrained sources.8
- Massey (1994). The lower bound
E[G] >= (1/4) 2^H + 1(section II) and no upper bound (section III).22 - Berrou, Glavieux and Thitimajshima (1993; DOI 10.1109/ICC.1993.397441). The encoder, the feedback decoder and the rate-1/2 results; Costello and Forney supply the two benchmarks.1611
- Arikan (arXiv 0807.3917, July 2009). The introduction and the theorems on
O(N^(-1/4))block error andO(N log N)complexity.17 - Costello and Forney (arXiv cs/0611112, November 2006). BCH, Reed-Solomon, LDPC and turbo sections (Figures 12 to 14).11
- MacKay (2003). Chapter 5 (Kraft, Huffman), section 2.6 (relative entropy), exercise 8.9 (data processing), chapter 13 (BSC capacity).6
- Kocher, timing attacks (CRYPTO ‘96; DOI 10.1007/3-540-68697-5_9). Sections 2 to 4 (the attack, error correction) and 6 (experiments).3029
- Brumley and Boneh (USENIX Security 2003). A different attack against optimised OpenSSL, demonstrated over a local network.3231
- Kocher, Jaffe and Jun, differential power analysis (CRYPTO ‘99; DOI 10.1007/3-540-48405-1_25). Power traces and statistical key recovery.3433
- Kelsey (FSE 2002; DOI 10.1007/3-540-45661-9_21). Sections 1 to 1.2: stateless and stateful channels, practical impact. CRIME and BREACH apply the idea to HTTPS.93536
- Standaert, Malkin and Yung (EUROCRYPT 2009; DOI 10.1007/978-3-642-01001-9_26). The conditional-entropy matrix, mutual information, and the caution that information is not security.37
- Bonneau (IEEE S&P, May 2012; DOI 10.1109/SP.2012.49). Argues that Shannon entropy and guessing entropy are poor, and not estimable from samples, for password guessing; section III defines the metrics including α-guesswork.23
- NIST SP 800-90B (January 2018) and SP 800-63B (June 2017; revision 4, 2025). 90B section 2.1 and Appendix D (min-entropy); 63B Appendix A (strength of passwords).212425
Conclusion
Information theory supplies three quantities that bound what is possible: entropy, which limits lossless compression of a source; capacity, which limits reliable transmission over a channel; and the redundancy that reliability costs. Shannon proved the limits exist by an existence argument, Hamming and Huffman gave a single-error-correcting code and an optimal binary prefix code, and later LDPC, turbo and polar codes approached capacity, in measurements and theorems that are of different kinds and cannot be ranked against one another directly. Security uses the same units with different metrics for different questions: min-entropy for first-guess success against random sources, guesswork and partial-guessing measures for passwords, equivocation for Wyner’s wiretap model, and mutual information, together with attack success, for side-channel leakage.
Footnotes
- C. E. Shannon, Communication Theory of Secrecy Systems, Bell System Technical Journal 28(4), 1949. https://archive.org/details/bstj28-4-656 (opens in a new tab) ↩1 ↩2 ↩3
- C. E. Shannon, A Mathematical Theory of Communication, Bell System Technical Journal 27, July and October 1948 (reprinted with corrections). https://people.math.harvard.edu/~ctm/home/text/others/shannon/entropy/entropy.pdf (opens in a new tab) ↩1 ↩2 ↩3 ↩4 ↩5 ↩6 ↩7 ↩8 ↩9 ↩10 ↩11 ↩12 ↩13 ↩14 ↩15 ↩16 ↩17 ↩18 ↩19 ↩20 ↩21 ↩22 ↩23 ↩24
- H. Nyquist, Certain Factors Affecting Telegraph Speed, Bell System Technical Journal 3(2), April 1924, starting p. 324. https://archive.org/details/bstj3-2-324 (opens in a new tab) ↩1 ↩2 ↩3 ↩4
- R. V. L. Hartley, Transmission of Information, Bell System Technical Journal 7(3), July 1928, p. 535. https://archive.org/details/bstj7-3-535 (opens in a new tab) ↩1 ↩2 ↩3 ↩4 ↩5
- C. E. Shannon, Prediction and Entropy of Printed English, Bell System Technical Journal 30(1), January 1951, starting p. 50. https://archive.org/details/bstj30-1-50 (opens in a new tab) ↩1 ↩2 ↩3 ↩4 ↩5 ↩6
- D. J. C. MacKay, Information Theory, Inference, and Learning Algorithms, Cambridge University Press, 2003, chapters 2, 4, 5, 8, 9, 11, 13 and 47. https://www.inference.org.uk/itprnn/book.pdf (opens in a new tab) ↩1 ↩2 ↩3 ↩4 ↩5 ↩6 ↩7 ↩8 ↩9 ↩10 ↩11 ↩12
- D. A. Huffman, A Method for the Construction of Minimum-Redundancy Codes, Proceedings of the IRE 40, pp. 1098-1101, September 1952 (manuscript received 6 December 1951); scan hosted by NYU. https://cs.nyu.edu/home/people/in_memoriam/roweis/csc310-2006/extras/huffman_1952_minimum-redundancy-codes.pdf (opens in a new tab) ↩1 ↩2 ↩3 ↩4 ↩5
- J. Ziv and A. Lempel, A Universal Algorithm for Sequential Data Compression, IEEE Transactions on Information Theory IT-23(3), pp. 337-343, May 1977. https://courses.cs.duke.edu/spring03/cps296.5/papers/ziv_lempel_1977_universal_algorithm.pdf (opens in a new tab) ↩1 ↩2 ↩3 ↩4 ↩5
- J. Kelsey, Compression and Information Leakage of Plaintext, Fast Software Encryption 2002, LNCS 2365, pp. 263-276, Springer, 2002, DOI 10.1007/3-540-45661-9_21 (author’s paper as hosted by gwern.net). https://gwern.net/doc/cs/cryptography/2002-kelsey.pdf (opens in a new tab) ↩1 ↩2 ↩3 ↩4 ↩5 ↩6
- R. W. Hamming, Error Detecting and Error Correcting Codes, Bell System Technical Journal 29(2), April 1950, starting p. 147. https://archive.org/details/bstj29-2-147 (opens in a new tab) ↩1 ↩2 ↩3 ↩4 ↩5 ↩6 ↩7
- D. J. Costello Jr. and G. D. Forney Jr., Channel Coding: The Road to Channel Capacity, arXiv cs/0611112, November 2006. https://arxiv.org/pdf/cs/0611112 (opens in a new tab) ↩1 ↩2 ↩3 ↩4 ↩5 ↩6 ↩7 ↩8 ↩9 ↩10 ↩11
- Crossref bibliographic record for DOI 10.1137/0108018 (I. S. Reed and G. Solomon, Polynomial Codes Over Certain Finite Fields, Journal of the Society for Industrial and Applied Mathematics 8, June 1960, pp. 300-304). https://api.crossref.org/works/10.1137/0108018 (opens in a new tab) ↩1 ↩2
- R. G. Gallager, Low density parity check codes, doctoral thesis, MIT, 1960 (advisor Peter Elias), MIT DSpace record. https://dspace.mit.edu/entities/publication/6efcd810-4862-40aa-b4e7-88dc677a413c (opens in a new tab) ↩1 ↩2
- R. G. Gallager, Low Density Parity Check Codes, IRE Transactions on Information Theory IT-8, January 1962, pp. 21-28, as listed in Gallager’s publication list. https://web.mit.edu/gallager/www/pages/pubsold.html (opens in a new tab) ↩1 ↩2
- R. G. Gallager, Low-Density Parity-Check Codes, MIT Press, 1963 (preface dated July 1963; preface and chapter 1). https://web.mit.edu/gallager/www/pages/ldpc.pdf (opens in a new tab) ↩1 ↩2 ↩3 ↩4 ↩5
- C. Berrou, A. Glavieux and P. Thitimajshima, Near Shannon Limit Error-Correcting Coding and Decoding: Turbo-Codes (1), Proceedings of ICC ‘93, IEEE, 1993, pp. 1064-1070, DOI 10.1109/ICC.1993.397441 (course-hosted copy). https://www.cp.eng.chula.ac.th/~piak/teaching/ice/intro2007/com-theory/turbo-code.pdf (opens in a new tab) ↩1 ↩2 ↩3
- E. Arikan, Channel polarization: A method for constructing capacity-achieving codes for symmetric binary-input memoryless channels, arXiv 0807.3917, version 5, 20 July 2009. https://arxiv.org/pdf/0807.3917 (opens in a new tab) ↩1 ↩2 ↩3
- ETSI TS 138 212 V16.2.0, 5G NR Multiplexing and channel coding (3GPP TS 38.212 Release 16), sections 5.3. https://www.etsi.org/deliver/etsi_ts/138200_138299/138212/16.02.00_60/ts_138212v160200p.pdf (opens in a new tab) ↩
- M. Sy, Demystifying 5G Polar and LDPC Codes: A Comprehensive Review and Foundations, EURECOM, arXiv 2502.11053, version 4 (31 October 2026; first submitted 16 February 2025; refers to 3GPP TS 38.212 V16.2.0). https://arxiv.org/pdf/2502.11053v4 (opens in a new tab) ↩
- S. Kullback and R. A. Leibler, On Information and Sufficiency, Annals of Mathematical Statistics 22(1), 79-86, March 1951, DOI 10.1214/aoms/1177729694 (Institute of Mathematical Statistics; archived copy). https://web.archive.org/web/2020/https://projecteuclid.org/download/pdf_1/euclid.aoms/1177729694 (opens in a new tab) ↩1 ↩2 ↩3
- NIST SP 800-90B, Recommendation for the Entropy Sources Used for Random Bit Generation, January 2018, section 2.1 and Appendix D. https://nvlpubs.nist.gov/nistpubs/SpecialPublications/NIST.SP.800-90B.pdf (opens in a new tab) ↩1 ↩2 ↩3 ↩4 ↩5 ↩6 ↩7
- J. L. Massey, Guessing and Entropy, Proceedings of the IEEE International Symposium on Information Theory, 1994, p. 204. https://www.isiweb.ee.ethz.ch/archive/massey_pub/pdf/BI633.pdf (opens in a new tab) ↩1 ↩2 ↩3 ↩4
- J. Bonneau, The Science of Guessing: Analyzing an Anonymized Corpus of 70 Million Passwords, IEEE Symposium on Security and Privacy, May 2012, pp. 538-552, DOI 10.1109/SP.2012.49 (course-hosted copy). https://www.cs.umd.edu/class/fall2022/cmsc614/papers/science-of-guessing.pdf (opens in a new tab) ↩1 ↩2 ↩3 ↩4 ↩5
- NIST SP 800-63B, Digital Identity Guidelines: Authentication and Lifecycle Management, June 2017, includes updates as of 03-02-2020; section 5.1.1, Appendix A and the table of threats and mitigations. https://pages.nist.gov/800-63-3/sp800-63b.html (opens in a new tab) ↩1 ↩2 ↩3 ↩4
- NIST SP 800-63B-4, Digital Identity Guidelines: Authentication and Authenticator Management, web edition dated 26 August 2025. https://pages.nist.gov/800-63-4/sp800-63b.html (opens in a new tab) ↩1 ↩2 ↩3
- A. Narayanan and V. Shmatikov, Robust De-anonymization of Large Datasets (How to Break Anonymity of the Netflix Prize Dataset), arXiv cs/0610105v2, 22 November 2007. https://arxiv.org/pdf/cs/0610105 (opens in a new tab) ↩
- A. D. Wyner, The Wire-Tap Channel, Bell System Technical Journal 54(8), October 1975, starting p. 1355. https://archive.org/details/bstj54-8-1355 (opens in a new tab) ↩1 ↩2 ↩3 ↩4 ↩5 ↩6
- M. R. Bloch and J. N. Laneman, Strong Secrecy from Channel Resolvability, arXiv 1105.5419 (IEEE Transactions on Information Theory, to appear, per the preprint). https://arxiv.org/pdf/1105.5419 (opens in a new tab) ↩
- Crossref bibliographic record for DOI 10.1007/3-540-68697-5_9 (Advances in Cryptology, CRYPTO ‘96, Springer, 1996, pp. 104-113). https://api.crossref.org/works/10.1007/3-540-68697-5_9 (opens in a new tab) ↩1 ↩2
- P. C. Kocher, Timing Attacks on Implementations of Diffie-Hellman, RSA, DSS, and Other Systems, Cryptography Research, Inc. (CRYPTO ‘96). https://paulkocher.com/doc/TimingAttacks.pdf (opens in a new tab) ↩1 ↩2 ↩3 ↩4 ↩5
- Boneh publications page for Remote timing attacks are practical: in proceedings of the 12th USENIX Security Symposium, 2003; first posted May 2003. https://crypto.stanford.edu/~dabo/abstracts/ssl-timing.html (opens in a new tab) ↩1 ↩2
- D. Brumley and D. Boneh, Remote Timing Attacks are Practical, Stanford University. https://crypto.stanford.edu/~dabo/papers/ssl-timing.pdf (opens in a new tab) ↩1 ↩2
- Crossref bibliographic record for DOI 10.1007/3-540-48405-1_25 (Advances in Cryptology, CRYPTO ‘99, Springer, 1999, pp. 388-397). https://api.crossref.org/works/10.1007/3-540-48405-1_25 (opens in a new tab) ↩1 ↩2
- P. Kocher, J. Jaffe and B. Jun, Differential Power Analysis, Cryptography Research, Inc. (CRYPTO ‘99). https://paulkocher.com/doc/DifferentialPowerAnalysis.pdf (opens in a new tab) ↩1 ↩2
- Y. Gluck, N. Harris and A. Prado, BREACH: Reviving the CRIME Attack, 12 July 2013. https://css.csail.mit.edu/6.566/2014/readings/breach.pdf (opens in a new tab) ↩1 ↩2 ↩3 ↩4
- CERT Coordination Center, Vulnerability Note VU#987798, BREACH vulnerability in compressed HTTPS, released 2 August 2013, revised 8 August 2013. https://www.kb.cert.org/vuls/id/987798 (opens in a new tab) ↩1 ↩2
- F.-X. Standaert, T. G. Malkin and M. Yung, A Unified Framework for the Analysis of Side-Channel Key Recovery Attacks, EUROCRYPT 2009, pp. 443-461, DOI 10.1007/978-3-642-01001-9_26. https://perso.uclouvain.be/fstandae/PUBLIS/63.pdf (opens in a new tab) ↩1 ↩2 ↩3

SecSIG