Generating, Saving, and Retrieving Public/Private Keys

When I discussed generating encryption keys previously, I described only symmetric session keys. I haven't discussed working with public/private key pairs. So, now we need to turn our attention to how to generate, save, and retrieve public/private key pairs.

In the preceding chapter, you learned to generate key pairs by using the AT_KEYEXCHANGE and AT_SIGNATURE key algorithms, which were in the list for the CryptGenKey function. These algorithms are used to generate public/private key pairs.

Note

The two public/private key pair types, Key Exchange and Signature, generate a lot of confusion among newcomers to encryption. You might easily conclude that you need both types. However, all public/private ...

Get Developing Secure Applications with Visual Basic now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.