Key (cryptography) Guide, Meaning , Facts, Information and Description
In cryptography, a key is a relatively small amount of information that is used by an algorithm to customize the transformation of plaintext into ciphertext (during encryption) or vice versa (during decryption). Enciphering using the same algorithm and plaintext, but with a different key, will likely produce a quite different ciphertext, and similarly for decryption as well. If the decryption key is lost, encrypted data should not in practice be recoverable — at least for high quality encryption algorithms and large enough key sizes. Thus, the security of a cryptographic key in most cases relies on its being kept secret.
| Table of contents |
|
2 Key sizes 3 Key choice 4 Applications 5 See also |
Need for secrecy
Cryptographic algorithms which use a single key for both encryption and decryption are known as symmetric key algorithms. An attacker who obtains the key (by, for example, theft, extortion, dumpster diving, or inspection of a Post-it note stuck to the side of a terminal) can recover the original message from the encrypted data.
It is commonly assumed that the details of the cryptographic algorithm are already available to the attacker. This design assumption is known as Kerckhoffs' law — "only secrecy of the key provides security", or "the enemy knows the system". The history of cryptography provides evidence that it can be difficult to keep the details of a widely-used algorithm secret; hence the principle has been widely adopted. A key is an easier a secret to protect (it's typically a small piece of information) than an encryption algorithm, and easier to change if compromised.
A new class of cryptographic encryption algorithms was discovered in the 1970s which use a pair of keys, one to encrypt and one to decrypt. Some of these asymmetric key algorithms have the property that it is not possible to determine one key from the other (so far as is currently known). Such an algorithm allows one key to be made public while retaining the private key in only one location.
Key sizes
Typical key sizes for estimated 'equivalent security' against a particular kind of attack (ie, brute force key space search) are 128 bits for symmetric ciphers and 2048 bits or more for public key cryptography. Elliptic curve cryptography may allow much smaller-size keys for equivalent security, but these algorithms have only been known for a relatively short time and current estimates of the difficulty of brute force searching for their keys may not survive. Recently, a message encrypted using a 109-bit key elliptic curve algorithm was broken by brute force. As a result it would appear that elliptic curve algorithm keys must be somewhat the same length as symmetric key algorithm keys for equivalent security. As always, for all but the one-time pad, a theoretical breakthrough may make everything you've encrypted an open book regardless of the algorithm or algorithm type you've chosen, and a too-short key will certainly do so.
If the key is too small, the algorithm will be vulnerable to a brute force attack in which all possible values of the key are tried one by one. Birthday attacks are also possible; the probability of a "collision" between a large group of values goes up roughly as the square of the number of possible values and this applies in cryptography as well. In addition, many algorithms permit reduced effort attacks as compared to brute force key search. If the effort is sufficiently reduced, the algorithm will be 'insecure' against that attack and should not be used. It may be expected that algorithms for which no improved attack is now known, and for which a brute force attack is impractical, will be found to be insecure when some new cryptanalytic technique is developed. When one is.
The problem of choosing a cryptographic algorithm reduces itself, in actual practice, to an estimate of how likely such an advance will be over the relevant time. Personal secrets need to be kept confidential for different durations than tactical deployment information in a battle, and still differently than some commercially valuable information (eg, the formula for Coke). There are no good answers known to this problem. Intelligent, cryptographically informed, choosers limit their choice to publicly known and publicly unbroken, but well studied, algorithms. Only algorithms from this group can be credibly thought secure. All others are either not sufficiently well tested, or are from secret organizations with adequate testing resources, but also with ulterior motives.
Key choice
In order to avoid being susceptible to attack, cryptographic keys must be chosen carefully. Nonrandom methods of key choice allow attackers to break the whole system just by breaking one key. For example, the poor choice of keys for the Japanese PURPLE cypher machine during World War II made it much easier for American analysts to continue to break encoded traffic after their initial breakthrough.
In general, keys must be random. Keys may also have to meet other requirements for, depending on the algorithms. The problem of how to generate truly random keys is fundamentally difficult and quite subtle, though it has been "solved" in many ways by various cryptographic systems. There is a RFC on generating randomness (RFC 1750, Randomness Recommendations for Security), but it is long on prescription and short on explanation. Randomness is always a problem in cryptography, and key choice is just an example of it. Failure to handle random key choice properly can easily make a system insecure.
Applications
See also
List of cryptographic key types
This is an Article on Key (cryptography). Page Contains Information, Facts Details or Explanation Guide About Key (cryptography)
