1. Home
  2. Explore
  3. Computer Science
  4. Cryptography Fundamentals

Study methods

Flashcards
Quiz
Fill in the blanks
Written test
Lesson
Notes
Podcast
Content

Cryptography Fundamentals

  • 34Unfamiliar
  • 0Learning
  • 0Familiar
  • 0Mastered
Topic: Cryptography Basics
Cryptography is the study of techniques for secret communication or
.

34 questions

  1. 1
    Cryptography is the study of techniques for secret communication or
    _____
    .
    Hint

    Think about the Greek roots: 'crypto' means hidden, and 'graphy' means writing.

    Answer

    secret writing

  2. 2
    The Greek word 'kryptos', from which cryptography derives, means
    _____
    .
    Hint

    Consider what 'cryptic' means in everyday language.

    Answer

    hidden

  3. 3
    Node.js's built-in crypto module is built on top of the open-source library
    _____
    .
    Hint

    This is a widely used library that implements SSL/TLS and cryptographic algorithms.

    Answer

    OpenSSL

  4. 4
    The function that returns a list of all available cipher algorithms in Node.js is
    _____
    .
    Hint

    Think about naming: 'get' + something related to ciphers.

    Answer

    getCiphers()

  5. 5
    AES stands for Advanced
    _____
    Standard.
    Hint

    The full name includes a word that means 'encoding'.

    Answer

    Encryption

  6. 6
    In AES-256-CBC, the '256' refers to the key size in
    _____
    .
    Hint

    This is a unit of digital information.

    Answer

    bits

  7. 7
    In CBC mode, the first block of plaintext is XORed with an
    _____
    before encryption.
    Hint

    This value is random and ensures different ciphertexts even for identical plaintexts.

    Answer

    initialization vector

  8. 8
    Using the same key and IV for every encryption would allow an attacker to detect
    _____
    .
    Hint

    Think about what Eve could observe if the same plaintext always produced the same ciphertext.

    Answer

    patterns

  9. 9
    To create a cipher object for encryption in Node.js, you call crypto.
    _____
    .
    Hint

    The function name includes 'create' and ends with 'iv' to indicate it requires an IV.

    Answer

    createCipheriv

  10. 10
    The method on a Cipher object that processes plaintext in chunks and returns ciphertext is
    _____
    .
    Hint

    This method can be called multiple times for streaming data.

    Answer

    update

  11. 11
    A key derivation function (KDF) is designed to be slow on purpose to thwart
    _____
    attacks.
    Hint

    This type of attack tries many passwords systematically.

    Answer

    brute-force

  12. 12
    Using a KDF without a salt allows Eve to use pre-computed
    _____
    to quickly guess passwords.
    Hint

    These are precomputed tables of hash values for common passwords.

    Answer

    rainbow tables

  13. 13
    The scrypt KDF in Node.js is called using crypto.
    _____
    .
    Hint

    The function name matches the algorithm name exactly.

    Answer

    scrypt

  14. 14
    Using Math.random() for cryptography is insecure because it is not
    _____
    .
    Hint

    The MDN documentation explicitly warns against this for security purposes.

    Answer

    cryptographically secure

  15. 15
    The crypto function that returns a buffer filled with random bytes of a given size is
    _____
    .
    Hint

    Think 'random' + 'bytes'.

    Answer

    randomBytes

  16. 16
    The function that generates a random integer in a given range is crypto.
    _____
    .
    Hint

    It returns an integer between min and max (inclusive).

    Answer

    randomInt

  17. 17
    The problem of securely sharing a symmetric key over an insecure channel is known as the
    _____
    problem.
    Hint

    This was a major challenge before public-key cryptography.

    Answer

    key distribution

  18. 18
    The Diffie-Hellman key exchange allows Alice and Bob to derive a shared
    _____
    without exchanging it directly.
    Hint

    They end up with the same secret value that can be used as a symmetric key.

    Answer

    key

  19. 19
    In Diffie-Hellman, the function createDiffieHellman creates an object that generates a prime, generator, and
    _____
    keys.
    Hint

    Each party has a pair of keys: one secret and one shared.

    Answer

    public and private

  20. 20
    The variant of Diffie-Hellman that uses elliptic curves for smaller keys is called
    _____
    .
    Hint

    It stands for Elliptic Curve Diffie-Hellman.

    Answer

    ECDH

  21. 21
    RSA is an example of
    _____
    encryption, where different keys are used for encryption and decryption.
    Hint

    This contrasts with symmetric encryption, which uses the same key.

    Answer

    asymmetric

  22. 22
    In RSA, anyone can encrypt a message using the recipient's
    _____
    key.
    Hint

    This key is intended to be widely distributed.

    Answer

    public

  23. 23
    The Node.js function to generate an RSA key pair is crypto.
    _____
    .
    Hint

    It generates both public and private keys asynchronously.

    Answer

    generateKeyPair

  24. 24
    To encrypt with RSA in Node.js, you call crypto.
    _____
    .
    Hint

    The function name indicates which key is used.

    Answer

    publicEncrypt

  25. 25
    Digital signatures provide
    _____
    β€” assurance that a message came from a specific sender.
    Hint

    This property ensures the identity of the sender.

    Answer

    authentication

  26. 26
    To create a digital signature, Alice uses her
    _____
    key.
    Hint

    Only Alice possesses this key.

    Answer

    private

  27. 27
    The function to verify a signature in Node.js is crypto.
    _____
    .
    Hint

    It checks if the signature matches the data and public key.

    Answer

    verify

  28. 28
    HMAC (Hash-based Message Authentication Code) is used for signing in
    _____
    cryptography.
    Hint

    HMAC uses a shared secret key, not a key pair.

    Answer

    symmetric

  29. 29
    A digital certificate binds a public key to an entity's
    _____
    .
    Hint

    The certificate serves as a form of ID for the key holder.

    Answer

    identity

  30. 30
    The four components of a certificate are subject, issuer, claim, and
    _____
    .
    Hint

    This is what makes the certificate tamper-evident.

    Answer

    signature

  31. 31
    Before a certificate is signed, the data to be signed is called a certificate signing
    _____
    .
    Hint

    Abbreviated as CSR.

    Answer

    request

  32. 32
    In Node.js, certificates can be parsed using the
    _____
    class.
    Hint

    The class name follows the standard format for certificates.

    Answer

    X509Certificate

  33. 33
    The hierarchy of certificates ends with a
    _____
    certificate that is inherently trusted by the system.
    Hint

    This certificate is self-signed and embedded in the OS or browser.

    Answer

    root

  34. 34
    In the browser, the equivalent of Node.js crypto module is the Web Crypto
    _____
    .
    Hint

    It provides similar cryptographic functions for client-side JavaScript.

    Answer

    API

1 of 34
Question 1 of 34

Ask anything

We've read this whole study set, so questions about it get the best answers.

FlashcardsQuizFill in the blanksWritten testLessonNotesPodcastContent