Help | Site Map
Connecting Tech Pros Worldwide
Reply
 
LinkBack Thread Tools
  #1  
Old July 3rd, 2008, 09:46 PM
dlite922's Avatar
Site Addict
 
Join Date: Dec 2007
Location: US
Age: 23
Posts: 624
Default VirtualHost Redirect to HTTPS, SSLRequireSSL? ModRewrite?

I need help with redirecting virtualhosts to use HTTPS (SSL) when they type in HTTP

Must work in IE.

Right now there is two virtual host blocks for every subdomain.

I want to combine the virtual hosts so that I don't have one for port 80 (which basically gives you a page that says type https, UGH! ugly!), and one for port 443

Current Config:
Code:
<VirtualHost x.x.x.x:80>
	ServerName sub1.example.com
	DocumentRoot...
	DirectoryIndex...
</VirtualHost> 

<VirtualHost x.x.x.x:443>
	ServerName sub1.example.com
	SSL Engine on
	SSLCertificateFile ...
	SSLCertificateKeyFile...
	SSLCertificateChainFile...
	DocumentRoot...
	DirectoryIndex...
</VirtualHost>
How can I combine those to that if someone types in HTTP it redirects to HTTPS.

(I know its ModRewrite but I don't know how, GoogleSearch examples were confusing. )

SSLRequireSSL gives you an access denied page if not SSL?

thanks in advance,



Dan
Reply
Reply

Bookmarks


Currently Active Users Viewing This Thread: 1 (0 members and 1 guests)
 
Thread Tools

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 Off
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On

What is Bytes?

We are a network of experts and professionals in IT and software development that help one another with answers to tough questions and share insights. Get the best answers to your questions from over network members.
Post your question now . . .
It's fast and it's free

Popular Articles