Created
September 3, 2014 20:55
-
-
Save mxmissile/019294152da407ca52f1 to your computer and use it in GitHub Desktop.
Rewrite rule for IIS rewrites everything to https
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<rule name="Redirect to HTTPS" stopProcessing="true"> | |
<match url="(.*)" /> | |
<conditions logicalGrouping="MatchAll" trackAllCaptures="false"> | |
<add input="{HTTPS}" pattern="^OFF$" /> | |
</conditions> | |
<action type="Redirect" url="https://{HTTP_HOST}/{R:1}" redirectType="Permanent" /> | |
</rule> | |
courtesy of Sides of March | |
http://www.sidesofmarch.com/index.php/archive/2014/09/02/forcing-iis-to-rewrite-all-requests-to-https/ |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment