Apache Server connect Tomcat SSL Server

Posted on

Apache Server connect Tomcat SSL Server – Managing your servers can streamline the performance of your team by allowing them to complete complex tasks faster. Plus, it can enable them to detect problems early on before they get out of hand and compromise your business. As a result, the risk of experiencing operational setbacks is drastically lower.

But the only way to make the most of your server management is to perform it correctly. And to help you do so, this article will share nine tips on improving your server management and fix some problem about apache-2.2, ssl, tomcat, , .

I need to implement the following scenario:

  • 02 different web servers (1 Tomcat and 1 Apache)
  • Tomcat has SSL and was configured to restrict access to clients that do not have the appropriate certificate
  • Apache need to access the tomcat’s application

How can I configure apache with appropriate certificate to gain access in Tomcat?


Solution :

It is not clear whether or not you are using mod_proxy or if your PHP application is making the SSL connection directly.

If you are using mod_proxy then you need to use the following directives in your Apache http config, most likely in the appropriate Location block:

SSLProxyCACertificateFile /path/to/ca.pem 
SSLProxyMachineCertificateFile /path/to/client.pem

Normally ca.pem contains the certificates of the CAs you trust to sign server certificate but since you are using a self-signed certificate ca.pem will contain the self-signed certificate.

The client.pem file contains the client key and certificate in PEM format (BEGIN CERTIFICATE … END CERTIFICATE) concatenated together, with the key first.

If you are making the SSL connection directly from your PHP code then Apache httpd is not directly involved and just runs your PHP script.

Leave a Reply

Your email address will not be published. Required fields are marked *