View previous topic :: View next topic |
Author |
Message |
GoofballJM1 Guru
![Guru Guru](/images/ranks/rank_rect_3.gif)
![](images/avatars/3445888644b294b87451f.jpg)
Joined: 22 Mar 2004 Posts: 392 Location: Denver, CO USA
|
Posted: Thu Jun 08, 2006 3:56 pm Post subject: forwarding http requests to https . . . . |
|
|
I have an SSL based connection on a webserver here at my job. I would like all requests to the particular domain via a regular port 80 http request to forward automatically to the https (port 443). So all anyone has to do is type in the domain name without specifying which protocol/port they will be connecting on. How is this done? _________________ "Great spirits have often encountered violent opposition from weak minds." - Albert Einstein |
|
Back to top |
|
![](templates/gentoo/images/spacer.gif) |
lxg Veteran
![Veteran Veteran](/images/ranks/rank_rect_5_vet.gif)
![](images/avatars/19265729674c9fac4bb9adf.png)
Joined: 12 Nov 2005 Posts: 1019 Location: Aachen, Germany
|
Posted: Thu Jun 08, 2006 4:05 pm Post subject: |
|
|
Given you have an Apache webserver with IP-based virtual hosts (which I think is a common configuration these days), put the following somewhere in your config:
Code: |
<VirtualHost xxx.xxx.xxx.xxx:80> # xxx.xxx.xxx.xxx being your IP
ServerName www.example.org
Redirect / https://www.example.org/
</VirtualHost>
|
Not tested, but should work. Don't forget to restart Apache. _________________ lxg.de – codebits and tech talk |
|
Back to top |
|
![](templates/gentoo/images/spacer.gif) |
GoofballJM1 Guru
![Guru Guru](/images/ranks/rank_rect_3.gif)
![](images/avatars/3445888644b294b87451f.jpg)
Joined: 22 Mar 2004 Posts: 392 Location: Denver, CO USA
|
Posted: Thu Jun 08, 2006 4:09 pm Post subject: |
|
|
I will give that a try. Thanks for your quick response! _________________ "Great spirits have often encountered violent opposition from weak minds." - Albert Einstein |
|
Back to top |
|
![](templates/gentoo/images/spacer.gif) |
kg4ysy Apprentice
![Apprentice Apprentice](/images/ranks/rank_rect_2.gif)
![](images/avatars/31424530744b2947e2ff5d.jpg)
Joined: 08 Jul 2006 Posts: 183 Location: North Carolina
|
Posted: Tue Jul 11, 2006 1:53 am Post subject: |
|
|
Is there anyway to use redirect without having to specify the domain name. At school I have multiple IP's which leads to a few different ways to access my computer. Can I just tell apache to redirect to port 443 without having to specify the IP? It doesn't seem possible from what I have seen around.
--Jim |
|
Back to top |
|
![](templates/gentoo/images/spacer.gif) |
lxg Veteran
![Veteran Veteran](/images/ranks/rank_rect_5_vet.gif)
![](images/avatars/19265729674c9fac4bb9adf.png)
Joined: 12 Nov 2005 Posts: 1019 Location: Aachen, Germany
|
Posted: Wed Jul 12, 2006 4:04 pm Post subject: |
|
|
Unfortunately, no. Apache is, although able to forward single/simple requests, not designed to manage IP and port routing. Such things are better done with... a router. ![Wink ;-)](images/smiles/icon_wink.gif) _________________ lxg.de – codebits and tech talk |
|
Back to top |
|
![](templates/gentoo/images/spacer.gif) |
kg4ysy Apprentice
![Apprentice Apprentice](/images/ranks/rank_rect_2.gif)
![](images/avatars/31424530744b2947e2ff5d.jpg)
Joined: 08 Jul 2006 Posts: 183 Location: North Carolina
|
Posted: Wed Jul 12, 2006 4:39 pm Post subject: |
|
|
Yeah that's what I figured...thanks for seconding my belief on apache. Nice icon by the way...MEIN FURHER!...Mr. President... |
|
Back to top |
|
![](templates/gentoo/images/spacer.gif) |
|