Friday, October 15, 2010

Implementing SSL on SharePoint 2010 and IIS 7 and forcing http request to redirect to https

Assumptions:

1. Certificate is already imported in IIS
2. I am using a wild card cert here but I believe it will be pretty much the same for other types of certs as well.
3. Port 443 is configured to point to this web application also.
4.WebApplications are using host headers


Open up IIS 7.0








Right Click on the website and select “Edit Bindings” which opens up the windows below





Click on add and Add https binding, select the SSL certificate in my case it is a wild card cert





Hit on OK



Now Lets change the port 80 to any other port, lets say 8026









Create a Port80 to Port 443 Redirector Dummy Website :


Select the Sites node under IIS, right click and select properties






Enter the below valuues, I just make it point to the Root IIS folder, this is just a dummy website and does not have any files in it. Hit on OK







So this setup means that all request for my test1..com over http will be coming to this webapplication, now lets configure redirection for these requests coming over http to https. Select the dummy webapplicatin and select ‘Http Redirect’ on the right hand side pane.







Sharepoint configuration :

Go to CA\ AAM\ hit on Edit Public URLs and enter the following which is
Default : https://test1..com
Intranet : http://test1..com


 Save it to look like this.



Now try accessing http and it should redirect to https!
But this will break search and Excel services, lets go fix that up.
Go to CA\Application management \ Manage Service applications\



 Click on the instance of “Search Service Appilcation” that is indexing your website.


Click on the “content Sources” on the left hand side



 Click on the content source that has your webapplication, in my case it is “Local SahrePoint sites”.
In here change your website to use https instead of http and then start a new Crawl by check marking “Start Full Crawl of this content source”



 Check the Crawl Log to make sure there are no errors.


Excel services : lets fix this up , I require an https trusted location to store files.
Go to CA\Application Management\ Manage service application and select the Excel Service Application instance to which your web application is associated with.






Click Trusted File Locations to open it up





Click on Add Trusted file Location and enter the following :
Address : https
Location type : Microsoft SharePoint Foundation
Trusted Children : check mark it.


Confirm that excel files are opening up and search is worknig as well

10 comments:

  1. Thanks! To Configure SSL Certificates in SharePoint 2010 for HTTPS Access - Step by Step, this article could help: http://www.sharepointdiary.com/2012/03/configuring-ssl-certificates-in-sharepoint-2010.html

    ReplyDelete
  2. Muzammil,

    Great find everything worked great. One issue; we have multiple sites so we simply created more than one redirector but when we did this it HTTP redirect updated the URL for the other redirector as though there is only one Redirect for all IIS.

    We tried using an IP for one site and “all unassigned” for the other site. That did not work. Any possible solutions???

    ReplyDelete
  3. Very helpful article ! I was always curious about all these complex algorithms that are being used in these ssl encryptions.

    ReplyDelete
  4. sharepoint is a web based collaborative platform.it is basically an intranet and content management systemyou can get more information at sharepoint online training.Read More At sharepoint online course bangalore

    ReplyDelete