HTTP Redirect to HTTPS

Help us improve our product. Feature requests are welcomed!
Post Reply
User avatar
DamianS
Posts: 16
Joined: Tue Sep 03, 2013 7:49 pm
Contact:

HTTP Redirect to HTTPS

Post by DamianS » Fri Sep 06, 2013 12:47 am

For me I never use HTTP since it allows users to send password unsecured over the internet. I would like to see the option to forward HTTP requests to the HTTPS port (whatever port that has been setup in the software). Currently I have to set the HTTP server to a nonstandard port, then install IIS and use it just to do a simple redirect.

BTW - Still an AWESOME PRODUCT!!!

Damian :)
Damian C. Stalls
Senior IT Engineer

Image

User avatar
DamianS
Posts: 16
Joined: Tue Sep 03, 2013 7:49 pm
Contact:

Re: HTTP Redirect to HTTPS

Post by DamianS » Fri Sep 06, 2013 12:55 pm

I have found an alternative to installing IIS (as I really do not like that resource hog installed on my system). Please note that this will only work if you are using the standard port 443 for your HTTPS connections.

1. Open the following file in notepad "C:\Programs Files (x86)\TSplus\Clients\www\template.html"
2. Please search for the original code shown below and change accordingly:

[ORIGINAL CODE]
<script type="text/javascript" src="software/java/third/sha256.js"></script>
<script type="text/javascript">
// --------------- Page Configuration ---------------
var page_configuration = new Array();


[NEW CODE]
<script type="text/javascript" src="software/java/third/sha256.js"></script>
<script type="text/javascript">
// --------------- Custom Configuration ---------------
var loc = window.location+'';
if (loc.indexOf('http://')==0){
window.location.href = loc.replace('http://','https://');
}
// --------------- End of Custom Configuration ---------------

// --------------- Page Configuration ---------------
var page_configuration = new Array();



While this works, I would still prefer the option in the TSplus webserver to force HTTP connections automatically to the configured HTTPS port.

Damian
Damian C. Stalls
Senior IT Engineer

Image

Brian
Posts: 89
Joined: Thu Mar 21, 2013 6:19 pm

Re: HTTP Redirect to HTTPS

Post by Brian » Thu Jul 31, 2014 7:51 pm

This re-direct doesn't work for me?

My Standard port is 443 for HTTPS and the port for HTTP is 8081. Does my HTTP port have to be 8080 for this to work properly?

User avatar
admin
Site Admin
Posts: 1649
Joined: Wed Sep 05, 2012 6:38 am

Re: HTTP Redirect to HTTPS

Post by admin » Tue Aug 05, 2014 2:12 pm

The patch given by DamianS will work fine, however you have to apply it not only in the template.html file but also for your current web access page (usually the index.html file located in C:\Program Files (x86)\TSplus\Clients\www ).
The template.html file will only be used if you re-generate your web access page using our Webmaster Toolkit ;)

var loc = window.location+'';
if (loc.indexOf('http://')==0){
loc = loc.replace('http://','https://');
window.location.href = loc.replace(':8080','');
}
Olivier
TSplus support team administrator
Image

Barton
Posts: 30
Joined: Tue Feb 04, 2014 1:42 pm

Re: HTTP Redirect to HTTPS

Post by Barton » Sun Feb 15, 2015 3:40 pm

Please, tell me how can I redirect to port 8443 ?

Thanks!

User avatar
admin
Site Admin
Posts: 1649
Joined: Wed Sep 05, 2012 6:38 am

Re: HTTP Redirect to HTTPS

Post by admin » Tue Feb 17, 2015 6:51 pm

Hello,

You will find this information here : tsplus.net/support/kb/faq.php?id=6
Olivier
TSplus support team administrator
Image

Post Reply