Apache2 and the proxy_pass to ssl based websites

Kategorien: IT, Security, Technik

Everybody knows this:


ProxyPass / http://domain.tld/
ProxyPassReverse / http://domain.tld/
ProxyPreserveHost on

But what will you do if you have a https based backend?

Some of you will try this:


ProxyPass / https://domain.tld/
ProxyPassReverse / https://domain.tld/
ProxyPreserveHost on

After an apache2 restart you will find this in your logfiles when you request the url.

[Mon Jul 29 13:14:22 2013] [warn] proxy: No protocol handler was valid for the URL /.
If you are using a DSO version of mod_proxy, make sure the proxy submodules are included in the configuration using LoadModule.

The point is, you have to enable the ssl module for your apache2.

After that you can:


SSLProxyEngine On

ProxyPass / https://domain.tld/
ProxyPassReverse / https://domain.tld/
ProxyPreserveHost on

Reload your Apache2 and be happy.

«
»

    Schreibe einen Kommentar

    Diese Website verwendet Akismet, um Spam zu reduzieren. Erfahre mehr darüber, wie deine Kommentardaten verarbeitet werden.