Activities

September 2014
M T W T F S S
« Aug   Oct »
1234567
891011121314
15161718192021
22232425262728
2930  

Amazon Loadbalencer SSL install errors : java.lang.ClassCastException

SSL has expired on of the client server on today which is running in AWS cloud. I uses Elastic loadbalencer to manage the SSL acceleration of my platform. Once I have issued the SSL at CA and apply the newly downloaded certificate on loadbalener, it’s throws me some strange errors which I do not understood.

java.lang.ClassCastException: org.bouncycastle.asn1.pkcs.PrivateKeyInfo cannot be cast to org.bouncycastle.openssl.PEMKeyPair

I got the same error while I’m installing SHA-2 SSL on AWS LB.

java.lang.ClassCastException: org.bouncycastle.asn1.pkcs.PrivateKeyInfo cannot be cast to org.bouncycastle.openssl.PEMKeyPair

AWS_LB_SSL_error

I’m sure that both private key and certificate which I provided in side the SSL input area are correct. After googling I found a solution from the AWS support portal itself. We need to convert the SSL private key to .pem format in order to accept by the LB.

Solution :
openssl rsa -in test.key -text > mydomain_private_key.pem

[root@web02 ~]# openssl rsa -in www.mydomain.com.key -text > mydomain_private_key.pem
writing RSA key

Now open the “mydomain_private_key.pem” file and copy the content inside private key file along with certificate file and CA Chanil file, it will accept the new SSL and listed in the SSL selection box on LB .

🙂 cheers

Leave a Reply

You can use these HTML tags

<a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <s> <strike> <strong>