0

I recently took over a server that is using Apache2 with SSL. I have setup a new server to which I am migrating all of the old websites so that we can more easily scale (it's a cloud server) and so that I can set everything up correctly (or at least with some sort of convention).

I have read quite a few articles on setting up Apache2 and SSL with virtual hosts, but I'm a bit confused because all of the examples show three files and I only seem to have two. To compound the problem, they are all named differently (do the file extensions actually make a difference?).

The examples show something to this effect:

<VirtualHost X.X.X.X:443>
  ServerAlias something.mydomain.com
  ServerAdmin [email protected]
  DocumentRoot /var/www/project/client/site

  SSLEngine on 
  SSLCertificateFile /etc/ssl/certs/mydomain-cert.pem
  SSLCertificateKeyFile /etc/ssl/private/mydomain-key.pem
  SSLCertificateChainFile /etc/ssl/certs/mydomain-ca.crt
</VirtualHost>

However, the files I have are:

  1. _.mydomain.com.crt
  2. gd_bundle.crt

It is a wildcard certificate that we purchased through GoDaddy I believe. I believe that the first file is the actual certificate file and the gd_bundle.crt is the chain file, but that leaves me without a key file. There is also a random mydomain.csr file lying around on the old server, but it wasn't one of the files bundled with the download from GoDaddy, so I'm not really sure as to what it is.

Any help in figuring out what I need to do would be greatly appreciated. I am software developer, so I know my way around computers, but I have only dabbled in server setup/maintenance.

Much Thanks!

2 Answers 2

2

I think your guesses about those being the certificate and chain is correct.

What you need to do is look for the key file on your old server. Perhaps look at the old apache configuration file to see where key file is. Can you tell us a bit more about the old server? Maybe we can help you locate it.

3
  • I'm at lunch at the moment. I'll look for it in just a bit though. Thanks for your confirmation. If two people think it, perhaps it's right :-) Or, we'll all fall off a cliff and die =P Dec 4, 2009 at 17:53
  • As it turns out, we are using an old key file from our old domain...or it's the new file but was renamed wrong. Is it possible to use the same key file for multiple domains? Dec 4, 2009 at 19:31
  • It worked, I was correct about the two original files and the old key file worked when I renamed it, so I don't know if it was just never renamed or what. Anyway, thanks for your help! Dec 4, 2009 at 20:29
1

Just to answer that minor question in there: No, file extensions does not matter. .key and .pem are both common for key files.

You can also look for any private keys using 'grep -r "BEGIN RSA PRIVATE KEY" /etc'

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .