Jump to content

Recommended Posts

Posted

Hi all,

 

I have setup HAP for another school but am having issues with the URL Rewrite, I have setup a dedicated sub-domain for HAP+ (folders.schooldomain.com) and have setup a URL Rewrite on the Default Web Site to redirect all HTTP traffic to HTTPS.

 

 
               
                   
                   
                       
                   
                   
               
           
       

 

The above works if I type folders.schooldomain.com it redirects to https://folders.schooldomain.com/hap/login.aspx?ReturnUrl=%2fhap which is fine, but if I type https://folder.schooldomain.com it shows me the default IIS page rather than redirect, I realise this is because the request is already HTTPS so doesn't redirect based on the rule but how can I get all requests to folder.schooldomain.com regardless of weather they are HTTP or HTTPS to go to https://folders.schooldomain.com/hap/login.aspx?ReturnUrl=%2fhap

 

Many thanks in advance

Posted

I http redirection issues when I set it up and again when setting up 'INSIGHT' (Web based information gateway to SIMS for parents etc.) and when ever we typed in INSIGHT.schooldomain.uk (etc.) it would do nothing and sit there. First I thought because it was under the 'Default Web Site' tab/level/tree in ISS I couldn't do this with out causing issues to HAP (which was working) or it would give me infinite loops error. Rules/redirections didn't do much help either sadly however moments ago I've solved it (again kinda), while looking at 'Set Website Defaults' window (found in the 'Site' tab/level/tree in ISS), if you select 'Enable Protocols' it explains how to force HTTPS by checking the SLL settings.

 

Solution (simply put);

 

Click 'Default Web Site' tab/level/tree in ISS (or which ever you called it - for me today it was INSIGHT)

Click HTTP Redirect;

Tick Redirect request box

Enter in your address https://folder.schooldomain.com/HAP in the text box below

The following 2 tick boxes 'ticked'

Status Code as "Found (302)

 

Then expand the 'Default Web Site' tab/level/tree in ISS (or which ever you called it - for me today it was INSIGHT)

Select HAP (or INSIGHT for me)

Select 'SSL Settings'

Have the Tick box selected and Client certificates on Ignore (I think it will either hang or bombared the user to accept the certificate etc. if you put accept?)

 

So when you enter folder.schooldomain.com ISS will take the command go to the correct tab/level/tree, get redirected and enforce SLL/HTTPS to 'https://folder.schooldomain.com/HAP'

 

Hope this works :)

Posted

Cheers for the reply DPenfold, I actually managed to solve it myself yesterday but until it had been tested I didn't want to post a reply, I used a slightly different method but got the URL Rewrite to work correctly in the end. I basically added two URL rewrites to the Default Web Site in the end, one to direct the traffic to HTTPS and one to append /hap onto the URL so that the Default Internet Information Services page doesn't come up when if they typed https://folders.schooldomain.com, now regardless of what they put in http/https or just folders.schooldomain.com it will still redirect to https://folders.schooldomain.com/hap/login.aspx, here is the code from my web.config showing the URL Rewrites I used.

 

       
           
               
                   
                   
                       
                   
                   
               
               
                   
                   
               
           
       

 

Hopefully this may help someone else in the future.

  • Thanks 1

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now



×
×
  • Create New...