Diffie Hellman Key Exchange

Alice and Bob agree on a prime number and a base .

  1. Alice chooses a secret number and sends Bob
  2. Bob chooses a secret number and sends Alice
  3. Alice computes
  4. Bob computes

Example

Alice and Bob agree on:

Alice chooses .

Alice’s Calculation:

  • Alice computes her public key:
  • Alice sends to Bob.

Bob’s Calculation:

  • Bob chooses a secret number .
  • Bob computes his public key:
  • Bob sends to Alice.

Shared Secret Calculation:

  • Alice computes the shared secret using Bob’s public key:

  • Bob computes the shared secret using Alice’s public key:

Thus, both Alice and Bob now share the same secret key .


Diffie-Hellman with and

  1. Alice and Bob agree on:

  2. Alice’s Secret Number:

    • Alice chooses .
  3. Alice’s Public Key:

    Compute .

  4. Bob’s Secret Number:

    • Bob chooses (e.g., ).
  5. Bob’s Public Key:

    Compute .

  6. Shared Secret Computation:

    • Alice computes .
    • Bob computes .

Now, both Alice and Bob have a shared secret key they can use for encrypted communication.


RSA Encryption

the RSA (Rivest, Shamir, and Adleman) algorithm, which is a widely used asymmetric cryptographic algorithm. The content covers the key aspects of RSA, including the generation of keys.

Key Points from the Slide:

  1. RSA Basics:

    • RSA involves a public key and a private key.
    • The public key is broadcasted and used for encrypting messages.
  2. Key Generation Steps:

    • Choose two distinct prime numbers and .
    • Compute , where:
      • is used as the modulus for both the public and private keys.
    • Compute Euler’s Totient Function, .
  3. Algorithm Processes:

    • Key Generation
    • Encryption
    • Decryption