Take the 2-minute tour ×
Server Fault is a question and answer site for professional system and network administrators. It's 100% free, no registration required.

I have a QA setup that consists of multiple internal development servers and one world-accessible provisioning machine that is setup to proxy pass the web traffic. Everything works fine for non-SSL requests, but I'm having a hard time getting the SSL logic working as well. Here's a few example vhost blocks.

<VirtualHost 192.168.168.101:443>
    ProxyPreserveHost On
    SSLProxyEngine On
    ProxyPass / https://192.168.168.111/
    ServerName dev1.site.com
</VirtualHost>

<VirtualHost 192.168.168.101:80>
    ProxyPreserveHost On
    ProxyPass / http://192.168.168.111/
    ServerName dev1.site.com
</VirtualHost>


<VirtualHost 192.168.168.101:443>
    ProxyPreserveHost On
    SSLProxyEngine On
    ProxyPass / https://192.168.168.111/
    ServerName dev2.site.com
</VirtualHost>

<VirtualHost 192.168.168.101:80>
    ProxyPreserveHost On
    ProxyPass / http://192.168.168.111/
    ServerName dev2.site.com
</VirtualHost>

I end up seeing the following error in the provisioner's error log.

[Fri Jan 28 12:50:59 2011] [warn] [client 1.2.3.4] proxy: no HTTP 0.9 request (with no host line) on incoming request and preserve host set forcing hostname to be dev1.site.com for uri /

As well as the following entry in the destination QA machine's access log.

192.168.168.101 - - [22/Feb/2011:08:34:56 -0600] "\x16\x03\x01 / HTTP/1.1" 301 326 "-" "-"
share|improve this question
    
Did you already see Apache VirtualHost with mod-proxy and SSL? –  Alexander Janssen Nov 3 '12 at 9:30
add comment

2 Answers

Is the virtualHost definition complete? you missed turning on the ssl engine and specifying the key andcert and so on... So I guess there is listenong a plain http receiver at :443 without ssl.

share|improve this answer
add comment

I've never had that specific error message, but I can see a problem in your setup: you have two virtual host listening on 192.168.168.101:443.

You can't do that with SSL, because Apache cannot look at the content of the SSL connection before it is decrypted, so your second SSL virtual host dev2.site.com is ignored.

share|improve this answer
    
That was actually just a transcription error on my part. The server doesn't actually have multiple SSL hosts on the same IP. –  BBonifield Feb 22 '11 at 16:15
add comment

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.