What is Cryptography? Cryptography is the study of secure communications techniques that allow only the sender and intended recipient of a message to view its contents. The term is derived from the Greek word kryptos, which means hidden. It is closely associated to encryption, which is the act of s…
What is Cryptography?
Cryptography is the study of secure communications techniques that allow only the sender and intended recipient of a message to view its contents. The term is derived from the Greek word kryptos, which means hidden. It is closely associated to encryption, which is the act of scrambling ordinary text into what's known as ciphertext and then back again upon arrival. In addition, cryptography also covers the obfuscation of information in images using techniques such as microdots or merging.
History Of Cryptography:
Ancient Egyptians were known to use these methods in complex hieroglyphics, and Roman Emperor Julius Caesar is credited with using one of the first modern ciphers. Cryptographic techniques mainly encryption & decryptions have been used for centuries to protect military and political issues. Throughout this history of cryptology, confidentiality has taken the primary seat and it was believed that if the secrecy is maintained (using symmetric encryption and secret key) then the authentication will automatically be achieved. The logic was if decryption of an encrypted text results in a meaningful message it must have been constructed by someone who knows the secret key. The trend changers were Diffie and Hellman, who are credited for advent of public key cryptography in mid 70s. Their seminal paper “New Directions in Cryptography”] introduced a number of relevant concepts like Digital Signatures and differentiated Confidentiality from Authentication and to quite an extent initiated the development of cryptographic schemes for the protection of authenticity. These schemes use a very important cryptographic primitive named ‘Cryptographic Hash Functions’. However cryptographic hash functions have received much less attention from the crypto logic community than encryption schemes in the past.
Cryptographic Hash Functions, CHF – one of the most important tools in modern cryptography and security.
- In crypto, CHF instantiates a Random Oracle paradigm
- In security, used in a variety of authentication and integrity applications
- Not the same as “hashing” used in DB or CRCs in communications
- Purpose: produce a fixed-size “fingerprint” or digest of arbitrarily long input data
- Why? To guarantee integrity
- Takes on input of any size
- Produces fixed-length output
- Easy to compute (efficient)
- Given any h, computationally infeasible to find any x such that H(x) = h
- For a given x, computationally infeasible to find y such that H(y) = H(x) and y≠x
- Computationally infeasible to find any (x, y) such that H(x) = H(y) and x ≠ y
- Cryptographic properties of a “good” HASH function:
- One-Way-ness (#4)
- Weak Collision-Resistance (#5)
- Strong Collision-Resistance (#6)
- Non-cryptographic properties of a “ good ” HASH function
- Efficiency (#3)
- Fixed Output (#2)
- Arbitrary-Length Input (#1)
- A hash function is typically based on an internal compression function f() that works on fixed-size input blocks (Mi)
- Sort of like a Chained Block Cipher
- Produces a hash value for each fixed-size block based on (1) its content and (2) hash value for the previous block
- “Avalanche” effect: 1-bit change in input produces “catastrophic” and unpredictable changes in output
- Bitwise-XOR
- Not secure, e.g., for English text (ASCIl<128) the high-order bit is almost always zero
- Can be improved by rotating the hash code after each block is XOR-ed into it
- If message itself is not encrypted, it is easy to modify the message and append one block that would set the hash code as needed
- Another weak hash example: IP Header CRC
- IPv4 header checksum
- One’s complement of the one’s complement sum of the IP header's 16-bit words
- H can be applied to block of data of any length. (In practice, ‘any length’ may be actually be bounded by some huge constant, larger than any message we ever would want to hash.)
- H produces a fixed-length output.
- Given H and x (any given input), it is easy to computer message digest H(x).
- Given H and H(x), it is computationally infeasible to find x.
- Given H and H(x), it is computationally infeasible to find x and x’ such that H(x) = H(x’)