Cryptography Flashcards

1
Q

What is Cryptography?

A

Cryptography is the art of transforming readable information into a form that is only readable by authorized individuals. This involves converting plaintext (readable information) into ciphertext (encrypted information) using algorithms and keys.

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

What are the four main security goals of cryptography?

A

Confidentiality: Ensures information remains secret and accessible only to authorized users.

Integrity: Guarantees information hasn’t been altered or tampered with.

Authentication: Verifies the sender’s identity and message origin.

Nonrepudiation: Prevents the sender from denying their message or action.

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

What are the two main types of cryptography?

A

Symmetric Key Cryptography: Uses the same key for encryption and decryption. It’s fast but requires secure key sharing.

Asymmetric Key Cryptography: Uses a key pair (private). The public key encrypts, and the private key decrypts, solving the key distribution problem.

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

How does cryptography ensure data integrity?

A

Cryptography uses hashing functions, which produce a unique, fixed-size output (hash value) from an input message. A small change in the input drastically alters the hash value, allowing detection of alterations by comparing original and received hash values.

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

How is cryptography used for authentication?

A

User ID and Password: Basic authentication where users provide credentials.

Digital Signatures: Created using asymmetric cryptography to verify the sender’s identity and ensure message integrity.

Digital Certificates: Issued by Certificate Authorities (CAs), binding a public key to an individual or organization.

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

What are the business benefits of using cryptography?

A

Protects sensitive information (customer data, financial records, trade secrets).

Ensures secure communication and
transactions, building trust.

Complies with regulatory requirements for data security.

Enhances brand reputation by demonstrating a commitment to security.

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

What are some common cryptographic algorithms?

A

DES (Data Encryption Standard): Older symmetric algorithm, now insecure.

Triple DES (3DES): More secure variant of DES.

AES (Advanced Encryption Standard): Secure and widely adopted symmetric-key algorithm.

RSA (Rivest-Shamir-Adelman): Popular asymmetric-key algorithm for encryption and digital signatures.

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

What are important considerations for key management?

A

Key Generation: Strong, random keys resist attacks.

Key Distribution: Securely share keys between authorized parties.

Key Storage: Protect keys from unauthorized access.

Key Rotation: Regularly change keys to limit impact of compromise.

Key Revocation: Mechanism to invalidate compromised or expired keys.

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

What is a Hash?

A

A hash is like a digital fingerprint for a message. It creates a fixed-size code (hash value) from the message, which helps check if the message has been changed.

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

What is Public Key Cryptography?

A

Public key cryptography uses two keys:

Public Key: Anyone can use this to encrypt a message.

Private Key: Only the person with this key can decrypt the message.

It’s also called asymmetric cryptography.

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

What is a Substitution Cipher?

A

A substitution cipher swaps parts of a message (letters, numbers, or bits) with other parts.
Example: The Caesar Cipher shifts letters by a set number (A → D).

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

What is a Transposition Cipher?

A

A transposition cipher rearranges the order of letters or bits in a message.

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

cryptosystem

A

the algorithms or ciphers used to encrypt data collectively known as a cryptosystem

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

plaintext/cleartext/ciphertext

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

cryptanalysis

A

process of breaking codes

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

cipher

A

algorithm to encrypt and decrypt information

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

one way algorithms/hash fuctions

A

can only encrypt, cant decrypt. output is called a hash

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

keyspace

A

the number of possible keys

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

session keys

A

last only for a seassion

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

Secure Shell (SSH)

A

used to set up secure sessions to a remote server

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

Out-of-band key exchange

A

is a method of securely exchanging cryptographic keys between two parties. This method uses a separate communication channel to exchange keys. This separate channel is established outside of the normal communications channel and is often called a secure channel. The Diffie-Hellman algorithm is one example of an out-of-band key exchange

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

In-band key exchange

A

in contrast, refers to exchanging encryption keys over the same communication channel that is used to transmit the messages. This method requires a secure connection

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

What is a homomorphic encryption algorithm?

A

Homomorphic encryption allows computations on encrypted data without decrypting it, preserving confidentiality while processing.

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

What is a certificate pinning?

A

Certificate pinning restricts which certificates are accepted for a service by “pinning” a predefined list of trusted certificates, reducing the risk of spoofing.

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

What is a cryptographic nonce?

A

A nonce is a number used once in cryptographic operations to ensure that old communications cannot be reused in replay attacks.

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

What is WPA3 in wireless security?

A

WPA3 is the latest wireless security protocol that improves encryption, protects against brute-force attacks, and supports individualized encryption for each device.

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

What is the role of SSL/TLS in secure communications?

A

SSL/TLS protocols encrypt data between a client and server, ensuring secure web browsing, email communication, and file transfers.

28
Q

What is Shor’s algorithm?

A

Shor’s algorithm is a quantum algorithm that can efficiently factorize large numbers, threatening traditional cryptographic systems like RSA.

29
Q

What is blockchain’s role in cryptography?

A

Blockchain uses cryptographic hashing to secure transactions and ensure data integrity, providing a tamperproof ledger for applications like cryptocurrency.

30
Q

What is a rainbow table attack?

A

A rainbow table attack uses precomputed hash values to reverse hashes and crack passwords quickly. Salting makes this attack ineffective.

31
Q

What is the difference between a symmetric key and a public/private key?

A

Symmetric Key: A single key is shared for both encryption and decryption.
Public/Private Key: A public key encrypts data, while a private key decrypts it, used in asymmetric cryptography.

32
Q

What is the importance of perfect forward secrecy (PFS)?

A

PFS ensures that if encryption keys from one session are compromised, previous or future sessions remain secure due to unique keys for each session.

33
Q

What is key escrow, and when is it used?

A

Key escrow involves storing cryptographic keys with a trusted third party, allowing access under special conditions like emergencies or legal requirements.

34
Q

What is a cryptographic random number generator (CSPRNG)?

A

CSPRNG is a secure random number generator designed for cryptographic applications, ensuring unpredictability and resistance to attacks.

35
Q

What is the purpose of elliptic curve cryptography (ECC)?

A

ECC provides strong encryption with smaller keys by using the properties of elliptic curves, making it efficient for devices with limited resources.

36
Q

What is the difference between hashing and encryption?

A

Hashing: A one-way process to produce a fixed-length output (hash) from input data for integrity verification.
Encryption: A two-way process to secure data, allowing it to be decrypted back to the original form.

37
Q

What is modular arithmetic in cryptography?

A

Modular arithmetic deals with numbers wrapped around a fixed value, called the modulus. It is fundamental in algorithms like RSA and Diffie–Hellman.

38
Q

What is a zero-knowledge proof?

A

A zero-knowledge proof allows one party to prove knowledge of a secret to another party without revealing the secret itself.

39
Q

What is the difference between DES and AES?

A

DES (Data Encryption Standard): Uses a 56-bit key and is now considered insecure.
AES (Advanced Encryption Standard): Uses 128, 192, or 256-bit keys and is widely regarded as secure.

40
Q

What is message authentication code (MAC)?

A

A MAC is a short piece of information used to verify both the integrity and authenticity of a message, created using a secret key and a cryptographic function.

41
Q

What is a padding oracle attack?

A

A padding oracle attack exploits weaknesses in how padding errors are handled during decryption, potentially allowing attackers to retrieve plaintext or keys.

42
Q

What is the difference between stream ciphers and block ciphers?

A

Stream Ciphers: Encrypt data bit by bit or byte by byte, ideal for real-time applications.
Block Ciphers: Encrypt data in fixed-size blocks, suitable for securing large amounts of data.

43
Q

What is entropy in cryptographic keys?

A

Entropy measures the randomness and unpredictability in cryptographic keys, with higher entropy providing greater security against brute-force attacks.

44
Q

What is public key infrastructure (PKI)?

A

PKI is a framework of policies, hardware, software, and standards that enable secure management, distribution, and use of public and private keys.

45
Q

What is a cryptographic salt?

A

A salt is random data added to passwords or keys before hashing to make attacks like dictionary attacks or rainbow table attacks more difficult.

46
Q

What are hybrid cryptographic systems?

A

Hybrid cryptographic systems use both symmetric and asymmetric cryptography. Asymmetric cryptography is used to exchange symmetric session keys, which are then used for faster data encryption.

47
Q

What is cryptographic obfuscation?

A

Obfuscation refers to methods that make data harder to understand without decrypting it, such as scrambling information to prevent unauthorized access.

48
Q

What is identity-based encryption (IBE) and attribute-based encryption (ABE)?

A

IBE: Derives encryption keys from the encryptor’s identity.
ABE: Uses descriptive attributes to determine encryption and decryption keys.

49
Q

What is key-stretching?

A

Key-stretching is a technique to make weak keys more resistant to brute-force attacks by using a function to generate a stronger key from the original weak one.

50
Q

Why is cryptanalysis important in evaluating ciphers?

A

Cryptanalysis evaluates the strength of ciphers by attempting to find flaws or weaknesses through analysis. Open-source ciphers are often tested publicly to ensure reliability.

51
Q

What is a one-time pad cipher?

A

A one-time pad uses a random key as long as the message itself. Each key is used only once, making this cipher theoretically unbreakable.

52
Q

What is the Vernam cipher?

A

The Vernam cipher is a type of one-time pad cipher that uses XOR operations with a random key for encryption and decryption, making it unbreakable if used correctly.

53
Q

What is the difference between symmetric and asymmetric cryptography?

A

Symmetric Cryptography: Uses the same key for encryption and decryption.
Asymmetric Cryptography: Uses a pair of keys—a public key for encryption and a private key for decryption.

54
Q

What is lightweight cryptography?

A

Lightweight cryptography is designed for devices with limited computational power, such as IoT devices, to provide efficient and secure encryption.

55
Q

What are ciphertext-only, known-plaintext, and chosen-plaintext attacks?

A

Ciphertext-Only Attack (COA): The attacker only has access to the ciphertext and attempts to deduce the plaintext or key.

Known-Plaintext Attack (KPA): The attacker has pairs of plaintext and ciphertext and uses these to find the key.

Chosen-Plaintext Attack (CPA): The attacker can choose plaintexts to encrypt and uses the ciphertext output to analyze the encryption process.

56
Q

What is homomorphic encryption?

A

Homomorphic encryption allows computations to be performed on ciphertext without decrypting it. Results of these computations remain encrypted and can later be decrypted to obtain the final result.

57
Q

What is a checksum?

A

A checksum is a small-sized output created from data to detect errors or alterations during transmission. Unlike hashes, checksums are not secure against intentional tampering.

58
Q

What are the properties of a secure hash function?

A

Deterministic: The same input always produces the same output.

Collision-Resistant: It is infeasible to find two different inputs that produce the same hash.

Pre-image Resistant: Given a hash, it is infeasible to determine the original input.

Fast Computation: The hash is quick to compute for any input.

59
Q

What is the Diffie–Hellman algorithm?

A

The Diffie–Hellman algorithm is a method for secure key exchange over an untrusted network. It enables two parties to generate a shared secret key without transmitting it directly.

60
Q

What is a man-in-the-middle attack in cryptography?

A

A man-in-the-middle attack occurs when an attacker secretly intercepts and possibly alters communication between two parties without their knowledge.

61
Q

What is WPA3 in wireless security?

A

WPA3 is the latest wireless encryption protocol that improves security by using stronger encryption methods, individualized encryption, and protection against brute-force attacks.

62
Q

What is a block cipher?

A

A block cipher encrypts data in fixed-size blocks, typically 64 or 128 bits, using a symmetric key.

63
Q

What is AES (Advanced Encryption Standard)?

A

AES is a widely used symmetric key encryption standard known for its strength and efficiency. It supports key lengths of 128, 192, and 256 bits.

64
Q

What is quantum key distribution (QKD)?

A

QKD uses quantum mechanics to securely exchange encryption keys. Any interception of the key transmission alters the state of the particles, revealing the presence of an eavesdropper.