Chapter 7 Cryptography and the Public Key Infrastructure Flashcards

1
Q

Substitution Cipher

A

Changes one symbol/character into another. the Identity of the character is changed, but it’s position is unchanged.
Caesar Cipher, ROT13
Polyalphabetic sub cipher uses multiple alphabets for the same message.

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

Transposition Cipher

A

Character position changes but the value/identity remains the same.
Columnar Transpostion: chosen number of columns IS the key.

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

Stenography

A

Embedding secret messages within another file like a picture.

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

Four Fundamental Goals of Cryptography

A

Confidentiality, Integrity, Authentication, Nonrepudiation

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

Confidentiality

A

Cryptographic systems must ensure data remains private at rest, in use, and in motion.
The preservation of secrecy for stored information and communication.

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

Obfuscation

A

Intentionally making something difficult for humans to understand.

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

Integrity

A

Ensures data is not altered without authorization. Digital signatures enforce the concept of integrity, and can be enforced through both public key (asymm) and secret key (symm) cryptosystems.

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

Authentication

A

verifies the claimed identity of system users and is a major function of cryptosystems. Challenge response authentication ensures that Bob is who he claims to be.

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

Nonrepudiation

A

provides assurance to the recipient that the message was originated by the sender and not a masquerade. Also prevents sender from claiming they didn’t send the message. Symmetric Key systems do NOT provide for Nonrepudiation!

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

Kerchoff Principle

A

A cryptosystem should be secure even if everything about the system (except the private key) is public knowledge.

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

Block Cipher vs. Stream Cipher

A

Block Cipher apply encryption algorithm to each chunk or block of a message at a time.
Stream Ciphers operate on one character or bit of a message/data stream at a time.

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

Symmetric Key Algorithm (shared secret key)

A

relies on shared secret encryption key that is distributed to all participating members. Difficult to break with large key, however:
- Key distribution is a major problem
- Doesn’t have nonrepudiation
- Algorithm not scalable
- Keys must be regenerated often
+very fast, much faster than asymmetric key encryption

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

Asymmetric Key Algorithm (public key)

A

Each user has a public key and a private key. Opposite keys must be used in tandem to encrypt or decrypt.
+ additional users only require creating one public/private key pair
+ Users can be removed easily
+ Key regeneration only required when private key is compromised
+ Provides for Integrity, authentication as well as nonrepudiation
+ Key distribution is simple
+ No pre-existing communication link necessary
- slow speed of operation

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

DES/Triple DES (symmetric key)

A

DES is a 64-bit block cipher with 5 modes, the key is 56-bits long.
- uses exclusive (XOR) operation which produces a unique output each time.
Triple DES uses the same algorithm over again with different keys. DES-EEE3 notes the number of encryption operations. All variations are now considered equally secure.

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

DES mode 1: ECB

A

Electronic Codebook Mode, simplest and least secure. encrypts block using chosen secret key.
Impractical on all but the shortest transmissions.

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

DES Mode 2: CBC

A

Cipher Block Chaining uses an initializing vector (IV) randomly selected value to start process. combines IV with first block using XOR.
In CBC, errors propagate.

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

DES Mode 3: CFB

A

Cipher Feedback Mode is a streaming version of CBC, so it processes data realtime.

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

DES Mode 4: OFB

A

Output Feedback Mode is similar to CFB, but instead of XORing previous encrypted block, DES XOR’s the plain text with seed. No chaining function, so errors do not propagate.

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

DES Mode 5: CTR

A

Counter Mode is a stream similar to CFB and OFB, but instead of seed, it uses a counter that increments each operation. Errors do not propagate.

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

AES (symmetric key)

A

Advanced Encryption Standard is a symmetric block cipher that replaces DES. Allows 3 key strengths: 128, 192, 256. AES only processes 128 bit blocks but encryption rounds can be increased to reach the key size required.

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

Key Exchange - 3 methods

A

Offline
Public Key Encryption- Many people use public key encryption (asymm) to set up comms link, then use secret key (symm) because of the superior speed.
Diffie-Hellman - algorithm that allows the exchange of secret keys over an unencrypted network.

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

Diffie-Hellman

A

“Standard Discrete Logarithm” that allows the exchange of secret keys over an unsecured network.

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

Key Escrow

A

Key escrow allows an authority to obtain a cryptographic key from a central storage facility or 2+ parties holding a split key. This may be a result of a court order or other authoritative motive.

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

RSA (public key/asymm)

A

RSA public key algorithm remains the worldwide standard. Relies on computational difficulty of factoring large prime numbers.

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

How to determine key length?

A

Weigh the difficulty of defeating a given key length against the importance of the data.

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

Elliptic Curve Cryptography

A

Elliptic curve equation, must be solve for X, extremely difficult to do, even with known variables. Believed to be more difficult than the prime factorization in RSA or the standard discrete logarithm by Diffie-Hellman.
*Provides equal strength to RSA but uses a shorter key length.

27
Q

What is the purpose of Hash Functions in relation to cryptography?

A

Take a potentially long message and generate a unique output value derived from the message content. This value is known as the message digest. Hash functions can be used to implement a digital signature algorithm.

28
Q

What are the Five Requirements of a cryptographic hash function?

A
  1. They accept input of any length.
  2. They produce output of fixed length.
  3. The hash value is relatively easy to compute.
  4. The hash function is one way (extremely hard to determine input solely from output).
  5. The hash function is collision free.
29
Q

SHA (secure hash algorithm) Symmetric

A

SHA is a ONE WAY HASH FUNCTION.
SHA-2 algorithms considered secure but theoretically suffer same weakness as SHA-1.
In 2015 Keccak algorithm became the SHA-3 Standard. 512-bit.

30
Q

MD5
What is it?
How many bit blocks?
Problems?

A

One way hash function.
Like SHA, MD5 processes 512-bit blocks but uses 4 rounds of computation.
Suffers from collisions and is therefore considered inferior to SHA.

31
Q

Digital Signatures:

What are the two distinct goals of Digital Signatures?

A
  1. Assure the recipient that the message truly came from the claimed sender
  2. Assure the recipient that the message was not altered in transit
  • Digital signatures do not actually provide any security or privacy on their own.
32
Q

HMAC

Hashed Message Authentication Code

A

HMAC Algorithm implements partial digital signature- guarantees the integrity of a message but does NOT provide for nonrepudiation.
Can be combined with any standard message digest (hash) generation algorithm (SHA-3) by using a shared secret key (symm). In such instance, only communicating parties can verify the digital sig.

  • Think of HMAC like a halfway point between unencrypted message digest algorithm and digital signature algorithms based on public key cryptography.
33
Q

Digital Signature Standard (DSS)

A

NIST specified 3 digital signature algorithms:

  • Digital Signature Algorithm (DSA)
  • RSA
  • Elliptic Curve DSA

*All must use the SHA-3 hashing functions.

34
Q
Key Selection:
David would like to send Mike a message using an asymmetric encryption algorithm. What key should he use to encrypt the message?
A. David Public Key
B. David Private Key
C. Mike Public Key
D. Mike Private Key
A

Mike’s Public Key.

35
Q
Key Selection:
Mike receives a message David encrypted for him using an asymmetric encryption algorithm, what key should he use to decrypt the message?
David's Public Key
David's Private Key
Mike's Public Key
Mike's Private Key
A

Mike’s Private Key

36
Q
Key Selection:
David wishes to digitally sign a message he is sending to mike using an asymmetric encryption algorithm. What key should David use to create the digital signature?
David's Public Key
David's Private Key
Mike's Public Key
Mike's Private Key
A

David’s Private Key

37
Q
Key Selection:
Mike receives a digitally signed message from David, what key should Mike use to verify the digital signature?
David's Public Key
David's Private Key
Mike's Public Key
Mike's Private Key
A

David’s Public Key

38
Q

Digital Certificates

A

Digital Certificates provide communicating parties with the assurance that the people they are communicating with are who they claim to be. Essentially endorsed copies of an individual’s public key.
- Governed by international standard X.509

39
Q

What is a wildcard (in certificate name)

A

The wildcard indicates that the certificate is good for subdomains as well, designated by asterisk symbol.

40
Q

Public Key Infrastructure

A

Manages digital certificates, facilitates communication between parties. Hierarchy of trust relationships. These trusts permit combining asymmetric and symmetric cryptography as well as hashing and digital certificates giving us hybrid cryptography.

41
Q

Hybrid Cryptography

A

The combination of symmetric (shared secret key) and asymmetric (public key) encryption algorithms as well as hashing and digital certificates.

42
Q

Certificate Authorities (CA)

A

CAs are the glue that binds the PKI together. These neutral organizations offer notarization of digital certificates. Trust in these organizations is paramount.

43
Q

Registration Authorities (RA)

A

Assist CAs with the burden of verifying users’ identity prior to issuing digital certificates.

44
Q

CA infrastructure

What are the 3 levels of CAs?

A

Root is top level of a CA and should be kept offline unless needed to protect its integrity and confidentiality.
intermediate CAs serve online and issue certificates on a routine basis
Leaf CAs are below intermediate CAs and further isolate issues should they occur.

  • this concept is known as certificate chaining.
45
Q

Self Signed Certificate/Internal CA

A

These can be used inside an organization. While the certificates won’t be trusted by the browsers of external users, internal systems can be configured to trust the internal CA.
- Saves cost

46
Q

Enrollment of Digital Certificate

A

Provide your public key in the form of a CSR (certificate signing request). The CA creates a X.509 digital certificate then digitally signs it.

47
Q

Domain Validation vs. Extended Validation

A

Domain Validation is the simplest and most common certificate; it verifies the subject has control of the domain name.
Extended Validation certificates provide assurance that the certificate owner is a legitimate business owner before issuing a certificate.

48
Q

Certificate Verification

A

When you receive a digital signature from someone you want to communicate with, you verify the certificate by checking the CA’s digital signature using the CAs public key. Next you ccheck that the certificate was not revoked using a Certificate Revocation List (CRL) or the Online Certificate Status Protocol (OCSP)

49
Q

Certificate Stapling

A

the process of appending a digitally signed OCSP response to a certificate. This reduces overall OCSP traffic sent to the CA.

50
Q

Certificate Pinning

A

Instruct browsers to attach a certificate to a subject for an extended period of time. When sites use pinning, the browser associates that site with their public key.

51
Q

Certificate Formats - DER, PEM, PFX, P7B
Which are binary/ACSII?
Which are used by Windows?

A

DER- most common, binary format .DER, .CRT, .CER
PEM ACSII version of DER .PEM or .CRT

PFX used by windows, binary .PFX .P12
P7B used by windows, ASCII .P7B

52
Q

Asymmetric Key Management

A
  1. Chose Encryption System Wisely
  2. Select Keys appropriately
  3. Keep Private Key Secret!
  4. Retire old keys
  5. change key pair regularly
  6. back up your key
  7. HSM provide effective way to manage keys
53
Q

Attacks: Brute Force

A

Trying every possible key/PW until one works

54
Q

Attacks: Frequency Analysis

A

looking at the blocks of an encrypted message for common patterns - doesn’t fucking work on modern algorithms

55
Q

Attacks: Known Plain Text

A

This attack relies on the attacker having pairs of known plain text along with the corresponding ciphertext. This gives the attacker a place to start attempting to derive the key.

56
Q

Chosen Plain Text Attack

A

The attacker can specify his own plaintext then encrypt it. He can carefully craft the plain text to learn characteristics about the algorithm. For example, if the Vigenere cipher is used, it is very easy to extract the key length and recover the key by repeating a letter “aa”.
Chosen plain text attacks are much more powerful than known plain text attacks.

57
Q

Related Key Attack

A

any attack where the attacker can observe the operation of a cipher under several different keys whose values are initially unknown, but where some mathematical relationship connecting the keys is known to the attacker. For example, the attacker might know that the last 80 bits of the keys are always the same.

58
Q

Attacks: Birthday Attack

A

Probability based attack; how many people would you need to have in a room to have a strong likelihood that two would have the same birthday?

59
Q

Attacks: Downgrade Attack

A

Attempts to get the user to switch to a less secure cryptographic mode.

60
Q

Attacks:: Rainbow Tables

A

Attempt to reverse hashed password value by precomputing the hashes of common password.

61
Q

How to prevent rainbow tables attack?

A

Salting, which is adding random characters to passwords before hashing.

62
Q

Blockchain

A

a distributed, immutable public ledger that no one can tamper with. Foundational technology for bitcoin and is primarily used for cryptocurrency.

63
Q

Homomorphic Encryption

A

Sometimes you need to protect the privacy of individuals but still need to perform calculations on data.