From 52ffa29853e57db9c629ace6d96ed3307df9fe61 Mon Sep 17 00:00:00 2001 From: gilbertchen Date: Wed, 15 Mar 2023 13:43:14 -0400 Subject: [PATCH] Updated RSA encryption (markdown) --- RSA-encryption.md | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/RSA-encryption.md b/RSA-encryption.md index 9aac792..60363bd 100644 --- a/RSA-encryption.md +++ b/RSA-encryption.md @@ -96,7 +96,8 @@ You can run these commands to generate the private and public key pair: openssl genrsa -aes256 -out private.pem 2048 openssl rsa -in private.pem -pubout -out public.pem ``` -The key needs to be in the PEM format. + +The key needs to be in the PKCS#1 format. If the first line of the private key file is `-----BEGIN PRIVATE KEY-----` rather than `-----BEGIN RSA PRIVATE KEY-----`, then it is in the PKCS#8 format and you'll need to supply the `-traditional` option to openssl. ### How it works