A pem encoded certificate chain suitable for installation on heroku should consist of the following: for the site, intermediate, and then for the root certificate encoded in pem.
cat server.orig.crt sub.class1.server.ca.pem ca.pem > heroku.crt
I like the problem with your private key more - you need to make sure that the pem file is not encrypted with a passphrase and that this is the same key pair that is used to create the certificate. The head of the private key will look like this if encrypted:
-----BEGIN RSA PRIVATE KEY----- Proc-Type: 4,ENCRYPTED ...
instead of just:
-----BEGIN RSA PRIVATE KEY----- MIICaQIBAAKBhACxlzv7H57F+vapTjqS9qdfDg20RjwFFU1B3yK8SqN7rX0jpjsW H3B2lhCqKPWd2To2LoOolhnsFbr5qlKK3ep/nuUZfkx1aOIg4L0FgzbuCSJfKE5B ...
In the first case, run (linux, mac os):
openssl rsa -in server.key -out server.unencrypted.key
and enter the passphrase when prompted. Then use server.unencrypted.key in the heroku call to add the certificate.
Johnny c
source share