[Last Call] Learn how to a build a cloud-first strategyRegister Now

x
?
Solved

Recompile Apache2 but add SSL without damaging Mysql/PHP installation

Posted on 2006-04-13
5
Medium Priority
?
540 Views
Last Modified: 2012-06-27
Fedora Core 3
Running Apache 2.0.55, MySQL 4.1, PHP 4.3.2 (all installed from source)

Ok, so the problem is that I did not install SSL when I compiled Apache2 and I want to add open_ssl (or mod ssl ??) to the current apache2 installation.  I am assuming, from reading other articles, that I will need to run ./configure again for apache2 but add the SSL configure options.

Question 1: If I do recompile apache with SSL, will this step on my current MySQL /PHP installations?  I don't want to have to reinstall PHP and MySQL all over again

Question 2: this current server previously had apache2 with SSL installed and I see an existing KEY stored in /home/ssl with two files: localhost.key and localhost.key.unsecure.  When I configure SSL, should I somehow point to these files to use that key?  I can't find a .csr file at all.

Question 3: Here is the ./configure command I used (that is lacking SSL):
./configure    --prefix=/usr/local/apache2    --enable-so    --enable-auth-digest    --enable-rewrite    --enable-setenvif    --enable-mime    --enable-deflate    --enable-headers

  So if I wanted to recompile with SSL exactly what options do I add to the configur line, and where exactly do I install from?

0
Comment
Question by:djs120
  • 3
  • 2
5 Comments
 
LVL 19

Accepted Solution

by:
ramazanyich earned 2000 total points
ID: 16460488
First install (if you didn't installed it previously) OpenSSL library (www.openssl.org).
After OpenSSL installation You should add to yor configure line option --enable-ssl. So in your case it will look like:
./configure    --prefix=/usr/local/apache2    --enable-so    --enable-auth-digest    --enable-rewrite    --enable-setenvif    --enable-mime    --enable-deflate    --enable-headers --enable-ssl

After compilation and installation configure you httpd.conf (and additional ssl.conf) to have an SSL virtual host. Check http://httpd.apache.org/docs/2.0/ssl/ for details of configuration.
You PHP module installtion will not be broken.


0
 
LVL 1

Author Comment

by:djs120
ID: 16469200
And after I reinstall apache2 with SSL, how can I install the localhost.key file that already exists on the server?  Will I have to go through with the temporary 30 day SSL that comes with the openSSL setup?
0
 
LVL 19

Expert Comment

by:ramazanyich
ID: 16469381
you should point to that file in the ssl.conf file. Check SSLCertificateKeyFile directive
0
 
LVL 1

Author Comment

by:djs120
ID: 16470663
Sorry if this is a dumb question, but do I need to do anything with "mod_ssl" and apache, or does "--enable-ssl" automatically setup mod_ssl?
0
 
LVL 1

Author Comment

by:djs120
ID: 16471394
Worked great with no problems.  All I had to do was copy the "ssl.crt" and "ssl.key" directories from the old apache installation and copy them over into the conf/ dir of the new apache install and restart with 'apacheclt startssl'.

Thanks!
0

Featured Post

Independent Software Vendors: We Want Your Opinion

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Introduction This article is intended for those who are new to PHP error handling (https://www.experts-exchange.com/articles/11769/And-by-the-way-I-am-New-to-PHP.html).  It addresses one of the most common problems that plague beginning PHP develop…
The title says it all. Writing any type of PHP Application or API code that provides high throughput, while under a heavy load, seems to be an arcane art form (Black Magic). This article aims to provide some general guidelines for producing this typ…
Exchange organizations may use the Journaling Agent of the Transport Service to archive messages going through Exchange. However, if the Transport Service is integrated with some email content management application (such as an anti-spam), the admin…
Look below the covers at a subform control , and the form that is inside it. Explore properties and see how easy it is to aggregate, get statistics, and synchronize results for your data. A Microsoft Access subform is used to show relevant calcul…
Suggested Courses
Course of the Month17 days, 16 hours left to enroll

829 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question