Cryptography Flashcards
Cryptanalysis
Study and methods used to crack encrypted communications
Cryptography
The science or study of protecting information whether in transit or at rest by using techniques to render the information unusable to anyone who does not possess the means to decrypt it.
Plain text
Something you can read
Cipher text
Plain text turned into something that cannot be read unless you have the proper key
Linear Crypt-analysis
Linear - take blocks of encrypted text and compare them to blocks of the unencrypted text line by line. Works best on block ciphers
Differential Crypt-analysis
Applicable to symmetric keys, compares differences in inputs to how each one affects the outcome
Integral Crypt-analysis
Input vs output comparison running multiple computations of the same block size input
Nonrepudiation
The means by which a recipient can ensure the identity of the sender and neither party can deny having sent or received the message.
Algortithm
Step by step method of solving a problem. Encryption algorithms are mathematical formulas used to encrypt and decrypt data. Encryption algorithms are also known as ciphers.
Encryption of bits methods
Substitution - bits are replaced by other bits
Transposition - changes the order of the bits
Stream cipher
Bits are encrypted as a continuous stream, one at a time, normally using an XOR function. These work at a very high rate of speed.
Block cipher
Data bits are split into blocks (commonly 64 bits at a time) and each block is encrypted with the key. Normally uses substitution and transposition in the algorithm. Slower than stream ciphers.
XOR (Exclusive OR)
0 XOR 0 = 0
0 XOR 1 = 1
1 XOR 0 = 1
1 XOR 1 = 0
If the two bits match, the result is a 0 and if they don’t match the result is a 1.
Key length
If the key chosen is smaller than the data, the cipher will be vulnerable to frequency attack because the key will be used repeatedly in the process.
Symmetric Encryption
Also known as single key which both encrypts and decrypts. Good for bulk encryption because it is fast but key distribution is an issue. Encryption only, does not provide for integrity (nonrepudiation)
DES - block cipher uses a 56 bit key - not considered secure
3DES - block cipher uses a 168 bit key with up to 3 keys, Slower than DES but more secure
AES - block cipher that uses a key length of 128, 192 or 256 bits. Faster than DES and 3DES
IDEA - block cipher that uses a 128 bit key. Used in PGP and Europe
Twofish - block cipher that uses a key size up to 256 bits
Blowfish - block cipher uses a 64 bit block size and a key from 32 to 448 bits. Considered public domain
RC series: RC2 to RC6 - block ciphers that uses variable key length up to 2040 bits
RC4 - is a stream cipher
RC5 - variable block sizes (32, 54,128) and 2-bit working registers
RC6 - uses 128 bit blocks and 4-bit working registers
N(N-1)/2
To calculate the number of keys you need to communicate with N devices.
Asymmetric Encryption
Key pairs - public and private - what one key encrypts, the other key decrypts. Can also be used for integrity via hashing algorithm, What one key signs, the other key can verify the signature as valid. Slower than symmetric and is suitable for small amounts of data.
Diffie-Hellman - a key exchange protocol used in SSL and IPSEC. Vulnerable to man in the middle attacks
Elliptic Curve Cryptosystem (ECC) - uses points on an elliptical curve in conjunction with logarithms for encryption and signatures. Uses less processing power so good for mobile devices
El Gamal - Solving of discreet logarithm problems
RSA - Uses primer numbers with key sizes up to 4096 bits.
Hash Algorithm
One-way mathematical function takes a variable length input and generates a fixed length message digest that acts as a signature for that data.
MD5 - 128 bits - considered insecure
SHA-1 - 160 bits - replaced by SHA-2 due to security concerns
SHA-2 - can product 224, 256, 384 and 512 bit hashes. Not widely used
SHA-3 - uses sponge construction
RIPEMD-# where the # indicates the bit length -works through 80 stages