cryptography and cryptanalysis
Today:
Cryptography does not solve security problems; it just transforms them into other problems, which are hopefully easier to handle.
Law enforcement Key recovery Key escrow
cryptographic security
Cryptographic Security
Unconditional Security
→ Security can be measured using information theory
Conditional Security
→ Security can be measured using complexity theory
Cryptographic security services
cryptographic hash functions
Definition hash function
hash function is a function h which has, as a minimum, following two properties
Note: hash function usually implies an unkeyed hash function.
a keyed hash function is a function h(x,k) that takes some arbitrary-length input x and a fixed-length key k as input
Manipulation detection codes (MDCs)
Used to detect changes to a document; unkeyed hash
Two types of MDCs:
Message authentication codes (MACs)
Used to assure both the source of a message and its integrity; keyed hash function
Security properties of hash functions (see HAC)
Properties of one-way functions
Hash functions
OWHF:
CRHF:
Well known hash functions: SHA-1, RIPEMD-160, MD5
Properties of cryptographic hash functions
Checksums
The result of applying a hash function is called hash value, message digest, or checksum.
The last term creates frequent confusion:
Note: A cyclic redundancy check (CRC) is not a cryptographic hash function: CRC’s are designed for detecting transmission errors
Some use cases of crytographic hashes (OWHF, CRHF)
CRHF:
OWHF:
Birthday paradox
√0.5*π*m
Complexity of brute-force attacks
Output size of hash function: n bit Pre-image and 2nd pre-image:
Collision: birthday „attack“:
Illustration of complexity:
1 Gops/s, 100 parallel ops/unit, 1000 units:
264 ops in about 50 hours
280 ops in about 380 years
2128 ops in about 1017 years
Construction Hash function
Pattern for the design of fast hash functions:
The symbol “||” denotes concatenation.
Hash Functions: A Typical Architecture
Hash function constructions examples
Current generation: SHA-512
What if input data is not a multiple of compress function input data size n?
Trivial padding: add as many 0-bit as necessary to obtain a multiple of n (Example: n=64)
Improved padding: add 1 single 1-bit and, after that, as many 0-bit as necessary to obtain a multiple of n
MD-Strengthening:
MD-Strengthening:
Some additional benefits
Input Message Size: Padding
Padding as defined for MD5, SHA-1, SHA-224, SHA-256
SHA-384/SHA-512: