LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Server (https://www.linuxquestions.org/questions/linux-server-73/)
-   -   Apache, VirtualHost and SSL (https://www.linuxquestions.org/questions/linux-server-73/apache-virtualhost-and-ssl-529689/)

Mr_CHISOL 02-16-2007 01:29 PM

Apache, VirtualHost and SSL
 
Hi All.

Let me first say: Gahhh... Thanks ;?)

Is it really supposed to be this hard? Oh.. Should perhaps describe my problem

I have a server and a domain that points to it (kachtus.net) and I'm trying to get SSL to work as I want.
The first thing that I want is the option to visit the site via a "secure connection" (https/SSL).
Then I have parts (both dirs and sub-domains) that I want to force SSL (mail.kachtus.net and secure.kachtus.net at the moment). It doesn't seem to be too hard to accomplish.

I use files in sites-availabe/ to configurate the different subdomains (I had this as reference) (Here's my files:https://secure.kachtus.net/sites-available/, apache2.conf doesn't have any conf. in this case...).

The secure.* works as it should (as do mail.*, but that one is still in apache2.conf to make sure it works until I know how to fix the rest, it looks like secure), https://kachtus.net also works as it should, but not the rest (keys
.*, http://kachtus.net etc).

I hope that you get the problem as I have a tendense to make things more complex than it is.. :?)

Any ideas are welcome.


ps
Note I've been working with this problem for a week (along with setting up sendmail, which I still hasn't finished).
I need the server/site up as soon as possible but I haven't time to mess with it as I have another site to finnish, besides I'm getting tired on not getting it to work.
:?)
ds

gilead 02-16-2007 02:17 PM

I'm not sure I fully understand your problem, but if you're using name based hosts in your virtual hosts setup (and the info at the Debian site suggests you are) then you can't have multiple SSL domains. Have a look at http://httpd.apache.org/docs/2.0/ssl...q.html#vhosts2 for a brief description.

It looks like you'll need to use separate IP addresses for different SSL hosts or use different port numbers for different SSL hosts. I haven't set up IP based virtual hosts here but there's some info at http://httpd.apache.org/docs/2.0/vhosts/ip-based.html that may help.

Mr_CHISOL 02-16-2007 03:59 PM

Ok... Three questions:

1. But I DO have two different "SSL-hosts" (or don't I); https://mail.kachtus.net & https://secure.kachtus.net
2. Does apache-ssl work better?? (Have no clue...)
3. WHY isn't there a nice way around it (or even why does this problem exist, I get the problem with mod_ssl etc, but why can't the "host processing" take part after the "SSL processing" if you wan't it to...).
I'd like (and would add if I was developing apache) an option to have modules integrate either before or after (or both!?) a certain step in the processing. But that's just me. ;?)


Addition:
Can Apache-SSL be configured to serve "non-ssl" for certain hosts?
If there's no way get this to wrk with a single daemon I guess I have to run two...


All times are GMT -5. The time now is 02:36 PM.