You are not logged in.

#1 2006-07-15 18:51:29

peque
Member
From: Denmark - Møn
Registered: 2005-06-26
Posts: 441

problems about http & https

Hi AF !

I' m trying to configure Apache with a lot of virtual hosts.

But 1 virtual host - I would like that one to run https and all others to run http.

But when I have setup my sslcerts and starting apache - I get the error bout I using the wrong protocol for http.

What am I doing wrong? It seems that I am not able of configuring the httpd.conf to run both virtual http & https hosts.
Is it possisble that some one could help me with this. I'm using the normal ssl.conf thats deliveret along with apache with pacman ?


Just getting better .... All the time

Offline

#2 2006-07-15 19:40:36

cactus
Taco Eater
From: t͈̫̹ͨa͖͕͎̱͈ͨ͆ć̥̖̝o̫̫̼s͈̭̱̞͍̃!̰
Registered: 2004-05-25
Posts: 4,615
Website

Re: problems about http & https

<VirtualHost>
 ServerName www.domain1.tld
 </VirtualHost>
 
 <VirtualHost>
 ServerName www.ssl-domain.tld
 #Some syntax to turn on ssl here...
</VirtualHost>

Don't have a reference file at hand, but I remember you need to specify the ports, and some syntax to turn on ssl for that specific virtual host.


"Be conservative in what you send; be liberal in what you accept." -- Postel's Law
"tacos" -- Cactus' Law
"t̥͍͎̪̪͗a̴̻̩͈͚ͨc̠o̩̙͈ͫͅs͙͎̙͊ ͔͇̫̜t͎̳̀a̜̞̗ͩc̗͍͚o̲̯̿s̖̣̤̙͌ ̖̜̈ț̰̫͓ạ̪͖̳c̲͎͕̰̯̃̈o͉ͅs̪ͪ ̜̻̖̜͕" -- -̖͚̫̙̓-̺̠͇ͤ̃ ̜̪̜ͯZ͔̗̭̞ͪA̝͈̙͖̩L͉̠̺͓G̙̞̦͖O̳̗͍

Offline

#3 2006-07-16 09:08:00

peque
Member
From: Denmark - Møn
Registered: 2005-06-26
Posts: 441

Re: problems about http & https

I have tried almost anything that I can figure out. So I would really like if somebody could give me and working example:
hereś what I got:
HTTP:
<VirtualHost>
      ServerAdmin      test@test.dk
      DocumentRoot  /www/test
      ServerName       www.test.dk
      ErrorLog               /var/log/httpd/test.log
</VirtualHost>

HTTPS:
<IfDefine>
Listen 443
<VirtualHost>
     ServerAdmin         test@test.dk
    DocumentRoot      /www/mail
    ServerName          test.dk
    ErrorLog                 /var/log/httpd/ssl.log

    SSLEngine            on

    SSLCipherSuite   (Havent touch this line?? )

     The path to the certs and key
<Files>
    SSLOptions  +StdEnvVars
</Files>
<Directory>
   SSLOptions +StdEnvVars
</Diretory>

SetEnvlf User-Agent ".*MSIE.*
     nokeepalive ssl-unclean-shutdown
     downgrade-1.0 force-response-1.0

CustomLog /var/log/httpd/ssl_request_log
    "%t %h %{SSL_PROTOCOL}x %{SSL_CIPHER}x "%r  " %b"
</VirtualHost>

</IfDefine>

es
Well - I have set /etc/conf.d/httpd to yes
And then its starts - but gives the error about I'm not using the right protocol for http   -  so all redirects to https??

Could anybody give me an exampel of their runnng hosts  or see whats wrong here???

Thanks
Peque


Just getting better .... All the time

Offline

#4 2006-07-16 17:43:38

cactus
Taco Eater
From: t͈̫̹ͨa͖͕͎̱͈ͨ͆ć̥̖̝o̫̫̼s͈̭̱̞͍̃!̰
Registered: 2004-05-25
Posts: 4,615
Website

Re: problems about http & https

first off, take out the ifdef's. You know you want it. doesn't make sense to test for it.
Second, you need ports in the virthost definition.

*removed because the forum software sucks*

EDIT: The forum keeps mangling my output. It isn't showing the tags properly.
soo....here it is in a nopaste.

Note the virthost tags, and the use of ports within it. That is what the forum ripped out the first time..

http://rafb.net/paste/results/7SwrSu16.html


"Be conservative in what you send; be liberal in what you accept." -- Postel's Law
"tacos" -- Cactus' Law
"t̥͍͎̪̪͗a̴̻̩͈͚ͨc̠o̩̙͈ͫͅs͙͎̙͊ ͔͇̫̜t͎̳̀a̜̞̗ͩc̗͍͚o̲̯̿s̖̣̤̙͌ ̖̜̈ț̰̫͓ạ̪͖̳c̲͎͕̰̯̃̈o͉ͅs̪ͪ ̜̻̖̜͕" -- -̖͚̫̙̓-̺̠͇ͤ̃ ̜̪̜ͯZ͔̗̭̞ͪA̝͈̙͖̩L͉̠̺͓G̙̞̦͖O̳̗͍

Offline

Board footer

Powered by FluxBB