Jump to content

ssl niginx error


Destramic
Go to solution Solved by requinix,

Recommended Posts

hey guys im getting an nginx error message when trying to use ssl on my server:
 

[emerg] 3108#6408: SSL_CTX_use_PrivateKey_file("C:\Users\Server\Desktop\host\myterms.co.uk\nginx/conf/ssl/myterms_co_uk.key") failed (SSL: error:0B080074:x509 certificate routines:X509_check_private_key:key values mismatch)

i've added the following to my nginx config:

ssl_certificate ssl/domain.ca-bundle;
ssl_certificate_key ssl/domain.key;

domain.ca-bundle  - my certificate bundle sent to me from comodo
domain.key            -  my private key generated with my RSA key

 

i've search the net, and i read that the i need to remove passphrase from key

openssl rsa -in domain.key -out newkey.pem

but that didnt work either

 

 

any help would be appreciated as i'm truly stuck now.


thank you

Link to comment
Share on other sites

Make sure the bundle has the certificates in the right order: nginx expects yours at the top and the rest of the chain after.

 

it appears the bundle sent from comodo was put together wrong.

 

i had to put my domain cert with my intermediate certificates in order and finally convert to .pem

 

not going to lie, it was tough :sweat:

 

but it worked thanks for the good advise requinix :happy-04:

Link to comment
Share on other sites

This thread is more than a year old. Please don't revive it unless you have something important to add.

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.