Hi,

 

I am trying to establish a SSL connection with a remote server on a random port 10170. I have got a public key from the server side. And I have sent my public key to the server. And I am trying to use my certificate file and the public key of the server like this.

 

cert = sunPrimary.pem

key = sunStunnel.pem

 

But the problem is both the public key from server and my own certificate file starts with “-----BEGIN CERTIFICATE-----“ by default. So now, if I don’t change the “-----BEGIN CERTIFICATE-----“ header of the my certificate to ”-----BEGIN PRIVATE KEY-----“ I get errors and if I change it to private key and make the public key of the server as certificate then I still get errors.

 

Please let me know, how can I use the key and certificate together.

 

Thanks.

 

Kind Regards,

Hamid Shahid