Hash Flashcards
1
Q
Hash function general use(6)
A
- Digital Signatures
- Public key encryption
- Integrity verification
- Message Authentication
- Password protection
- Key Agreement protocols and cryptographic protocols
2
Q
Hash functions main uses(6)
A
- Identify files and detect modified files in cloud storage
- Identify files in repo in Git
- Detect modified files in Host based Intrusion Detection
- Detect malicious data in Network based Intrusion Detection
- Prove digital artefacts not modified
- Blockchain ensure integrity of previous transactions
3
Q
Hash function overview + 3 desired properties + 3 other properties
A
- many to one function, NOT one to one
- different files hash to SAME value
- Any length to Short Fixed length
1. Preimage Resistance
2. Second Preimage resistance
3. Collision Resistance - 1 and 2 hardest to crack
- for n bit function, security in finding hash collision at n/2 bit strength
- Fast for integrity, slow for password hashing
- Long length, at least 256 bits long
- Unpredictable, minute change in M affects many bits in hash
4
Q
Preimage resistance
A
- computationally infeasible to revert output to get input
5
Q
Second preimage resistance
A
- given input and digest it hashes to, computationally infeasible to find another input with same digest
-attacker no control over first input
6
Q
Collision resistance
A
- no one able to produce two different inputs that hash to same output
- attacker can choose two inputs
7
Q
Hash VS Encryption
A
Hash: ensures Integrity
Encryption: ensures confidentiality
8
Q
Using SHA256 on website, sha256sum
A
- Click button to download file
- Use SHA256 hash algorithm to hash downloaded file
- Compare digest with string on webpage to verify right file
* NOT always mean files not tampered despite hash being real secured, website may be hacked
9
Q
MD5 dumpster fire
A
- Colliding Certificates with different identities
10
Q
Final Notes on Hash
A
- Use KECCAK
- do not create or believe in proprietary hashes
- Sign hash of large file for file integrity
- use SHA256, SHA512
11
Q
Linear Algebra recap
A
- Form system of equations
- Gaussian elimination to get RREF
- Start from bottom row
- Find free variables and solve