LinuxQuestions.org
Help answer threads with 0 replies.
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 03-06-2007, 09:01 AM   #1
kaplan71
Member
 
Registered: Nov 2003
Posts: 719

Rep: Reputation: 39
Automatic Redirects in Apache


Hi there --

I have set up SquirrelMail on our e-mail server and I would like to have users be automatically redirected to a secure or https page when they type in the URL to get to the initial login page. The apache server is version 2.2.2. What file(s) should I modify to make this happen? Thanks.
 
Old 03-08-2007, 08:09 AM   #2
Teukka
LQ Newbie
 
Registered: Aug 2003
Location: Finland
Distribution: Debian, Fedora, FreeBSD, OpenBSD
Posts: 22

Rep: Reputation: 15
Quote:
Originally Posted by kaplan71
Hi there --

I have set up SquirrelMail on our e-mail server and I would like to have users be automatically redirected to a secure or https page when they type in the URL to get to the initial login page. The apache server is version 2.2.2. What file(s) should I modify to make this happen? Thanks.
Assuming you are using apache? First enable mod_rewrite (how? depends what distribution you use) and then you can do like this

<VirtualHost *:80>
ServerName some.name.fi
Redirect permanent / https://some.name.fi/
RewriteEngine on
RewriteCond %{REQUEST_METHOD} ^(TRACE|TRACK)
RewriteRule .* - [F]
</VirtualHost>


This is basic and simple rewriterule, works fine
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

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 automatic domains 70mas Linux - Server 1 02-01-2007 01:51 AM
I'm looking for automatic reloading apache script martien Red Hat 1 04-09-2006 05:11 AM
Apache redirects?! How rincewind Linux - Software 3 02-23-2005 03:43 PM
Apache: Request exceeded the limit of 10 internal redirects guarriman Linux - General 1 01-26-2005 09:06 AM
Automatic Startup of Apache m2azer Linux - General 6 09-20-2004 08:39 AM


All times are GMT -5. The time now is 11:49 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
identi.ca: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration