FUDforum
Fast Uncompromising Discussions. FUDforum will get your users talking.

Home » FUDforum » How To » How-to: https for login operations only
Show: Today's Messages :: Unread Messages :: Show Polls :: Message Navigator
| Subscribe to topic | Bookmark topic 
Switch to threaded view of this topic Create a new topic Submit Reply
How-to: https for login operations only [message #165286] Fri, 20 May 2011 11:02 Go to next message
eclipsewebmaster is currently offline  eclipsewebmaster   Canada
Messages: 46
Registered: November 2009
Location: Ottawa, Ontario, Canada
Karma: 0
Member
add to buddy list
ignore all messages by this user
If you want your forum to operate on http, but automatically switch to https for the login process, here's what you can do. This is based on forum 3.0.2 using the default template and the LDAP plugin to authenticate but it should work with the standard auth.

Add this to your Apache config:
# https for forums
Rewritecond %{HTTPS} (?!on).*
Rewritecond %{THE_REQUEST} ^[A-Z]{3,9}\ /forums/index.php\?t=login
RewriteRule ^/(.*) https://www.example.com/$1 [L,R]

In FUDforum/thm/default/tmpl/header.tmpl, delete these two lines.
17:<base href="{FULL_ROOT}" />
52:<base href="{FULL_ROOT}" />

Rebuild your template and voila.
Re: How-to: https for login operations only [message #165299 is a reply to message #165286] Sun, 22 May 2011 06:39 Go to previous message
naudefj is currently offline  naudefj   South Africa
Messages: 3624
Registered: December 2004
Karma: 17
Senior Member
Administrator
Core Developer
remove from buddy list
ignore all messages by this user
Great tip - thanks!
Quick Reply
Formatting Tools:   
  Switch to threaded view of this topic Create a new topic
Previous Topic: Paste From Word
Next Topic: Permanently remove OR replace the logo on the Forum
Goto Forum:
  

-=] Back to Top [=-
[ Syndicate this forum (XML) ] [ RSS ]

Current Time: Thu Oct 19 18:11:56 EDT 2017

Total time taken to generate the page: 0.00537 seconds