LinuxQuestions.org
Latest LQ Deal: Latest LQ Deals
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Server
User Name
Password
Linux - Server This forum is for the discussion of Linux Software used in a server related context.

Notices


Reply
  Search this Thread
Old 08-15-2011, 08:39 AM   #1
freakyal
LQ Newbie
 
Registered: Jul 2011
Distribution: FreeBSD, Ubuntu
Posts: 7

Rep: Reputation: Disabled
Question Limiting Apache https responses to one site


Hi,

I apologize in advance if this has already been covered in another thread.

Today I configured our web server to use https for our subversion site. Apache2 hosts multiple http sites and now this https site on a single IP.

The problem is that if you try to connect to any of the hosted http sites using https you get the subversion web pages on the requested URL. Access is restricted to active directory credentials, so that limits the impact ... but it is still messy.

From what I have gathered ...
  • the whole SSL thing has to happen before Apache gets the url request, so you are bound to get the cert/site-name mismatch browser error
  • VirtualHost directives don't work with SSL because of the whole single cert per IP thing, otherwise I could create certs and SSL VirtualHosts with redirects to the http URL

How can I get Apache to only serve the subversion web pages to requests that use the correct URL? Can I get it to simply ignore all other URLs? Is there a way to use redirects to point to the http site?

Much Appreciated,
Al
 
Old 08-15-2011, 12:47 PM   #2
bathory
LQ Guru
 
Registered: Jun 2004
Location: Piraeus
Distribution: Slackware
Posts: 13,163
Blog Entries: 1

Rep: Reputation: 2032Reputation: 2032Reputation: 2032Reputation: 2032Reputation: 2032Reputation: 2032Reputation: 2032Reputation: 2032Reputation: 2032Reputation: 2032Reputation: 2032
Hi,

Quote:
How can I get Apache to only serve the subversion web pages to requests that use the correct URL? Can I get it to simply ignore all other URLs? Is there a way to use redirects to point to the http site?
In named-base vhosts you can't. As you've already pointed out the ssl handshake happens before rewriting, so you get the warnings about wrong certificates when you visit the non-ssl vhosts.

Quote:
VirtualHost directives don't work with SSL because of the whole single cert per IP thing, otherwise I could create certs and SSL VirtualHosts with redirects to the http URL
This is no longer true. For apache 2.2.12 and newer, you can use SNI to define multiple ssl vhosts each with its own key/certificate

Regards
 
1 members found this post helpful.
Old 08-15-2011, 08:03 PM   #3
freakyal
LQ Newbie
 
Registered: Jul 2011
Distribution: FreeBSD, Ubuntu
Posts: 7

Original Poster
Rep: Reputation: Disabled
bathory,

Quote:
This is no longer true. For apache 2.2.12 and newer, you can use SNI to define multiple ssl vhosts each with its own key/certificate
He shoots he scores!

Many thanks,
Al
 
  


Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
apache 2.0 https to https redirect struct Linux - Software 1 04-22-2011 05:43 PM
https site not opening satish Linux - Networking 5 12-30-2010 03:10 PM
ssl_error_handshake_failure_alert on https site - localhost konzo Linux - Server 6 09-06-2010 05:21 AM
speed up https (apache) site peridot121 Linux - Server 3 05-18-2010 04:51 PM
Limiting number of responses in MagpieRSS oneandoneis2 Linux - Software 1 06-01-2005 10:25 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - Server

All times are GMT -5. The time now is 06:54 PM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration