A key generation algorithm creates cryptographic key material before communication begins. In asymmetric encryption, it produces a public key that may be shared and a private key that must remain secret; a security parameter controls key strength. section 6.1
A typical key-generation role looks like this:
- Choose a security parameter, usually indicating the desired key size or security level. section 6.1
- Generate a related public/private key pair. section 6.1 section 7.1
- Publish or exchange the public key while protecting the private key. section 6.1 section 5.1
- Use the resulting pair for encryption and decryption, signatures and verification, or shared-secret derivation. section 6.1 section 7.1 section 5.1
Alice and Bob establish a secret
Alice and Bob each generate a key pair, exchange public keys, and combine the peer's public key with their own private key. Both obtain the same shared secret, while a passive observer cannot reproduce it. Without authentication, however, an active man-in-the-middle can impersonate both parties. section 5.1
Figure 6.2 To use asymmetric encryption, you first need to generate a key pair. Depending on the security parameters you provide, you can generate keys of different security strengths.
Shows how the chosen security parameter affects the generated key pair's security strength. section 6.1
