Security – Unable to parse certificate. Please ensure the certificate is in PEM format [AWS Console]

amazon-web-servicesaws-cliSecurityssl-certificate

I got the following error,

Unable to parse certificate. Please ensure the certificate is in PEM
format aws console

when trying to add https listener to the aws load balancer as instructed guide here (using aws console).
I gave the the corresponding certificate as text (same as in the guide). But the above error comes saying that its not in the pem format.

—–BEGIN PUBLIC KEY—–MIIBIj…..IDAQAB—–END PUBLIC KEY—–

and

—–BEGIN RSA PRIVATE KEY—–MIIE….68J—–END RSA PRIVATE KEY—–

What am I doing wrong here?

Best Answer

What am I doing wrong here?

You are using a key that is in the wrong format - RSA. You will need to convert your RSA format file to a PEM format.