Visit Jeremy's Blog.
Go Back > Forums > Linux Forums > Linux - General
User Name
Linux - General This Linux forum is for general Linux questions and discussion.
If it is Linux Related and doesn't seem to fit in any other forum then this is the place.


  Search this Thread
Old 03-22-2004, 01:27 PM   #1
Registered: Oct 2003
Posts: 40

Rep: Reputation: 15
Question mod_ssl cannot find a private key


I just installed apache with mod-ssl and it was working fine, but then I moved everything to /chroot, and now my mod_ssl is reporting an Error: Private Key not found, even though I am pointing at the key in my httpd.conf
Does anybody know what could be a problem?

Old 03-22-2004, 01:55 PM   #2
LQ Guru
Registered: Jan 2001
Posts: 24,149

Rep: Reputation: 235Reputation: 235Reputation: 235
Is /chroot a directory you made? And what does it say in your httpd.conf file for location?
Old 03-22-2004, 02:20 PM   #3
Registered: Oct 2003
Posts: 40

Original Poster
Rep: Reputation: 15
yes, /chroot is a directory, and I moved all apache files there, and all libraries, and the certificate and the private key, and in the httpd.conf the key location is:

SSLCertificateKeyFile /etc/ssl/private/server.key

and the certificate:

SSLCertificateFile /etc/ssl/certs/server.crt
Old 03-22-2004, 04:37 PM   #4
LQ Guru
Registered: Aug 2001
Location: Fargo, ND
Distribution: SuSE AMD64
Posts: 15,733

Rep: Reputation: 671Reputation: 671Reputation: 671Reputation: 671Reputation: 671Reputation: 671
Is appache running in a jail. Are there /chroot/etc/ssl/private/server.key and a /chroot/etc/ssl/certs/server.crt files. I believe that appache is being run with /chroot as the new root. Therefore in the environment that apache is run, /chroot is the new root (/) partition, and files that apache needs to run that are outside this new root partition, need to be located inside the jail.
Old 03-22-2004, 04:41 PM   #5
Registered: Oct 2003
Posts: 40

Original Poster
Rep: Reputation: 15
yes, I do have the certificate and the key copied to /chroot/etc/ssl/certs/server.crt and /chroot/etc/ssl/private/server.key and it still doesn't find it...

UPDATE: Yesterday I was playing around with the key, and found out, that as long as I use unencrypted key, it works just fine, but as soon as I encrypt it, it says it cannot find it... Could there be something wrong with my encryption program?

Last edited by ner; 03-23-2004 at 09:44 AM.
Old 03-23-2004, 12:42 PM   #6
Senior Member
Registered: Aug 2002
Location: Stuttgart (Germany)
Distribution: Debian/GNU Linux
Posts: 1,467

Rep: Reputation: 46
I suggest you make use of strace to locate the source of the problem. Also take a look at


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Similar Threads
Thread Thread Starter Forum Replies Last Post
seahorse on FreeSBIE ( export private key ) shakespeare *BSD 0 04-22-2005 02:29 PM
public/private key authentication with PuTTY NetAX Linux - Security 5 10-27-2004 07:00 PM
if they got my gpg private key...... qwijibow Linux - Security 1 10-21-2003 01:22 AM
RSA public key encryption/private key decription koningshoed Linux - Security 1 08-08-2002 08:25 AM
private key compromised sourian Linux - Security 4 04-17-2002 07:59 PM > Forums > Linux Forums > Linux - General

All times are GMT -5. The time now is 08:43 PM.

Main Menu
Write for LQ is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration