6 - Cryptography Flashcards

1
Q

What is the Caesar Cipher?

A

The Caesar Cipher is one of the earliest known ciphers used by Julius Caeser to communicate with Cicero in Rome that simply shifted each letter of the alphabet 3 places to the right. If you reached the end of the alphabet you just wrap around to the beginning.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
2
Q

What is the significance of Ultra and Enigma?

A
  • Enigma was a code machine made up of 3-6 rotors to implement an extremely complicated substitution cipher. It was created by the German military during WW2.
  • Ultra was the code name for the program used by the Allies that were attempting to attack Enigma.

Eventually, Enigma was reconstructed by the Polish military.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
3
Q

What security principles does Cryptography apply?

A
  1. Confidentiality: Ensures data remains private in three different situations: at rest, in transit, and in-use.
  2. Integrity: Ensures that data is not altered without authorization. Digital Signatures help enforce integrity.
  3. Authentication: The claimed identity of system users and is a major function of cryptosystems.
  4. Nonrepudiation: Provides assurance to the recipient that the message was originated by the sender and not someone masquerading as the sender.
How well did you know this?
1
Not at all
2
3
4
5
Perfectly
4
Q

What are the 2 main types of cryptosystems used?

A
  1. Symmetric: Uses a shared secret available to all users of the system.
  2. Asymmetric: Combinations of public and private keys for each user of the system.
How well did you know this?
1
Not at all
2
3
4
5
Perfectly
5
Q

What is an algorithm?

A

A set of rules, usually mathematical, that dictates how enciphering and deciphering processes are to take place.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
6
Q

What is Cryptology and what are its components?

A

Cryptology is made up of:

  • Cryptography: The art of creating and implementing secret codes and ciphers.
  • Cryptanalysis: The study of methods to defeat codes and ciphers.
How well did you know this?
1
Not at all
2
3
4
5
Perfectly
7
Q

What are some important components of Cryptographic Mathematics?

A
  • Boolean Mathematics: Defines the rules used for the bits and bytes that form the nervous system of any computer. In an electrical system, there are only two possible states: on (representing the presence of electrical currents) and off (representing the absence of electrical current). Computer scientists refer to the on condition as a “True” value and the off condition as a “false” value.
  • Logical Operations:
    • AND (^): Checks to see whether two values are both true. Only takes 2 variables as input. With Boolean math, this means only 4 possible inputs for the AND function.
    • OR (v): Checks to see if at least one value is true (both inputs can be true as well). The only time a value is false is when both inputs are false.
    • NOT (- or !): Simply reverses the value of an input variable.
    • Exclusive OR (XOR): Only returns a true value when only one of the input values is true. If both values are true or false then the function is false.
  • Modulo Function (%): The remainder value left over after a division operation is performed.
  • One-Way Operations: A mathematical operation that easily produces output values for each possible combination of inputs but makes it impossible to retrieve the input values. **Its never been proven that any known function is truly one way.**
  • Nonce: A nonce is a random number that acts as a placeholder variable in mathematical functions. When the function is executed, the nonce is replaced with a random number generated at the moment of processing for one-time use. The nonce must be a unique number each time it is used.
    • Initialization Vector (IV): A random bit string that is the same length as the block size and is XORed with the message. IV’s are used to create unique ciphertext every time the same message is encrypted using the same key.
  • Zero-Knowledge Proof: Proving your knowledge of a fact to a third party without revealing the fact itself to that third party. Often done with passwords and other secret authenticators.
  • Split Knowledge: When the info or privilege required to perform an operation is divided among multiple users, no single person has sufficient privileges to compromise the security of an environment.
  • Work Function: Represents the time and effort required to perform a complete brute-force attack against an encryption system is what the work function represents.
How well did you know this?
1
Not at all
2
3
4
5
Perfectly
8
Q

What are Ciphers? And what is the difference between a Code and a Cipher?

A
  • Ciphers use a variety of techniques to alter and/or rearrange the characters or bits of a message to achieve confidentiality. Ciphers convert messages from plaintext to ciphertext on a bit basis (single digit of binary code), character basis (a single character of ASCII), or block basis (a fixed-length segment of a message).
  • Codes are cryptographic systems of symbols that represent words, or phrases, which are sometimes secret but not necessarily meant to provide confidentiality.
How well did you know this?
1
Not at all
2
3
4
5
Perfectly
9
Q

What are some common types of ciphers?

A
  • Transposition Ciphers: Use an encryption algorithm to rearrange the letters of a plaintext message, forming the ciphertext message.
  • Substitution Ciphers: Replace each character or bit of the plaintext message with a different character.
  • One-Time Pad (Vernam cipher): An extremely powerful substitution cipher where a different substitution alphabet for each letter of the plaintext message is used. Must be randomly generated and must be physically protected against disclosure. The key is as long as the message itself and must only be used once!
  • Running Key Ciphers (Book Cipher): The encryption method is as long as the message itself and is often chosen from a common book.
  • Block Cipher: Operate on chunks, or blocks, of a message and apply the encryption algorithm to an entire message block at the same time.
  • Stream Ciphers: operate on one character or bit at a time.
How well did you know this?
1
Not at all
2
3
4
5
Perfectly
10
Q

What is the difference between confusion and diffusion?

A
  • Confusion occurs when the relationship between the plaintext and the key is so complicated that an attacker can’t merely continue altering the plaintext and analyzing the resulting ciphertext to determine the key.
  • Diffusion occurs when a change in the plaintext results in multiple changes spread throughout the ciphertext.
How well did you know this?
1
Not at all
2
3
4
5
Perfectly
11
Q

What are the different key algorithms?

A
  • Symmetric Key Algorithms (Private Key Algorithms): These rely on a “shared key” encryption key that is distributed to all members who participate in the communication. It is used to encrypt and decrypt messages. Weaknesses:
    • Safe Distribution
    • Does not implement nonrepudiation
    • Not Scalable
    • Keys must be regenerated often
  • Asymmetric Key Algorithms (Public Key Algorithms): Each user has two keys: a public and a private. They are used to together to encrypt and decrypt. Strengths:
    • Users can be removed easily
    • Key generation only required when a private key is compromised.
    • Can provide CIA
    • Key distribution is simple
    • No preexisting communication link needs to exist.
How well did you know this?
1
Not at all
2
3
4
5
Perfectly
12
Q

What is a Message Digest?

A

A Message Digest is a summary of a message content (like a file checksum) produced by a hashing algorithm.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
13
Q

What is a collision?

A

Where a hash function produces the same value for two different methods.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
14
Q

What are some common symmetric cryptosystems?

A
  • Data Encryption Standard (DES): Produced by the government in 1977, DES is no longer considered safe but it is the building for Triple DES (3DES). DES is a 64-bit block cipher with 56 bit key that has five modes of operation:
  • Triple DES (3DES): Encrypts target 3 times to strengthen ciphertext.
  • International Data Encryption Algorithm (IDEA): Operates on 64-bit blocks of plaintext/ciphertext. Uses a 128-bit key which is broken up into 52 16-bit subkeys that are used to encrypt. Used in PGP
  • Blowfish: Operates on 64-bit blocks and uses variable sized key lengths ranging from 32-448 bits.
  • Skipjack: Operates on 64-bit blocks of text, uses an 80-bit key, and supports the same modes of operation supported by DES. NIST and the Department of Treasury own portions of info on how the key was made so they have the capability to decrypt Skipjack.
  • Advanced Encryption Standard (AES): Replaced DES as the encryption standard for the US government in 2001.Uses 3 key strengths which process blocks of equal length but the rounds differ per key:
    • 128-bit: 10 rounds
    • 192-bit: 12 rounds
    • 256-bit: 14 rounds
  • Twofish: Block cipher that operates on 128-bit blocks and is capable of using keys 256 bits in length. Uses 2 techniques:
    • Prewhitening: XORing the plaintext with a separate subkey before the first round of encryption.
    • Postwhitening: Uses similar XORing after the 16th round of encryption.
How well did you know this?
1
Not at all
2
3
4
5
Perfectly
15
Q

What are the 5 modes of DES?

A
  • Electronic Code Book (EBC): The simplest and least secure. Processes a 64-bit block, only used to exchanging small amounts of data.
  • Cipher Block Chaining (CBC): each block of unencrypted text is XORed with the block of ciphertext immediately preceding it before it is encrypted with DES. Utilizes an IV for encryption. Downside is errors can propagate, where one block has an issue it will carry over.
  • Cipher Feedback (CFB): The streaming cipher version of CBC, instead of using blocks, uses memory buffers of the same block size. It uses real-time data instead of pre-existing data.
  • Output Feedback (OFB): XOR’s the plaintext with a seed value. Future sees values are derived by running the DES algo on the previous seed value.
  • Counter (CTR): Uses a simple counter that increments for each operation.
How well did you know this?
1
Not at all
2
3
4
5
Perfectly
16
Q

What are the 4 versions of 3DES?

A
  • DES-EEE3: Encrypts 3 times with 3 different keys
  • DES-EDE3: Uses 3 keys but replaces the second encryption operation with a decryption operation.
  • DES-EEE2: Only uses 2 keys.
  • DES-EDE2: Uses 2 keys but also uses a decryption operation in the middle.
17
Q

What are some common symmetric key distribution methods?

A
  • Offline: Material transferred physically usually in external, removable media. Can also be paper. The Risk of interception can happen.
  • Public Key Encryption: Using a person’s public/private key to set up a channel to exchange symmetric keys. Symmetric key communications are thousands times faster than public-key systems.
  • Diffie-Hellman: An algorithm that allows two users to verify each other’s identity. It involves the 2 parties to agree on a large prime number and a large integer which are then used in a formula to confirm the key they will use.
18
Q

What are some best practices for the storage and destruction of symmetric keys?

A
  • Never store an encryption key on the same system where encrypted data resides.
  • For sensitive keys, consider providing two different individuals with half of the key. They then must collaborate to re-create the entire key. This is known as Split-Knowledge.
19
Q

What are some major approaches for key escrow?

A
  • Fair Cryptosystems: Secret keys used in communication are divided into two or more pieces, each of which is given to an independent 3rd party. Each piece is useless on its own but necessary to obtain a full key. If the government wants to access encrypted data, they must provide a court order to each of the 3rd parties and then reassembles the secret key.
  • Escrowed Encryption Standard: Provides the government with a technological means to decrypt ciphertext. This is the basis behind the Skipjack algorithm.