Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

How do I get the private key for a GoDaddy certificate so I can install it on Ubuntu 14+?

Tags:

ssl

apache

ubuntu

The cert I have from StartSSL comes with a key file. But from GoDaddy, I get only the 2 .crt files. GoDaddy's instructions are for CentOS and explicitly do not work for Ubuntu.

How do I export the private key ... or get it from somewhere ... so I can use it with Apache SSL? The question that is ALMOST the same as mine assumes use of a Mac Keychain application. I don't run a Mac and I'm trying to do everything on the Ubuntu command line. I know there's a way to do this ... can anyone help me find it?

Thanks!

like image 910
Daniel Wilson Avatar asked Apr 04 '17 12:04

Daniel Wilson


People also ask

How do I get my private key certificate from GoDaddy?

The path to your private key is listed in your site's virtual host file. Navigate to the server block for your site (by default, it's located in the /var/www directory). Open the configuration file for your site and search for ssl_certificate_key which will show the path to your private key.

How do I get my certificate private key?

Click Domains > your domain > SSL/TLS Certificates. You'll see a page like the one shown below. The key icon with the message “Private key part supplied” means there is a matching key on your server. To get it in plain text format, click the name and scroll down the page until you see the key code.

Why does my cert not have a private key?

A missing private key could mean: The certificate is not being installed on the same server that generated the CSR. The pending request was deleted from IIS. The certificate was installed through the Certificate Import Wizard rather than through IIS.


1 Answers

Follow this steps.

  1. First of all Generate the Private key and CSR using the following command.

    openssl req -new -newkey rsa:2048 -nodes -keyout server.key -out server.csr

You'll be asked the questions like the Country, State, City, Company Name, Domain name and all. Just fill up the details and your Private key will be ready as server.key in the directory you are going to run this command.

You'll be asked to enter Challenge Password, You can enter any secure Password in there.

2. Login into GoDaddy and ReKey the Certificate, You'll have to Submit the CSR we've generated with the Private Key.

Once you'll Rekey the Certificate, you'll be able to Install the certificate using the crt file you got, ca-bundle you got and the Private key we just made!

Let me know if you have any questions about this.

PS: You have to use this method when you lose your Private key.

like image 57
p01ymath Avatar answered Oct 06 '22 23:10

p01ymath