Copied to clipboard

Flag this post as spam?

This post will be reported to the moderators as potential spam to be looked at


  • Neil Campbell 58 posts 182 karma points
    May 14, 2010 @ 08:46
    Neil Campbell
    0

    Url Rewriting Exclusion

    Hi all,
    We have a site that runs entirely in SSL, so there is a URL Rewrite configured to rewrite any http requests to https, as below:

    <add name="useSSL"
     virtualUrl="http://(.*)"
     rewriteUrlParameter="ExcludeFromClientQueryString"
     destinationUrl="https://$1"
     ignoreCase="true"
     redirect="Domain"
     redirectMode="Permanent" />

    We need to make one exclusion from SSL for the /umbraco/webservices folder or even just /umbraco/webservices/CacheRefresher.asmx
    Has anyone done this, or knows how to?

    So basically http://blah.com/umbraco/webservices/CacheRefresher.asmx should not be rewritten to https://

    Any help is really appreciated!

    Cheers,
    Neil

  • Sebastiaan Janssen 5060 posts 15522 karma points MVP admin hq
    May 14, 2010 @ 08:52
    Sebastiaan Janssen
    2

    You could just make two more rules that rewrite the https version of those two URL's back to http... Not very efficient, and might cause problems  if the cacherefresher still gets called with https (?).

    Maybe you can add them to the web.config as excluded pages.

  • Neil Campbell 58 posts 182 karma points
    May 14, 2010 @ 12:18
    Neil Campbell
    0

    Thanks for that Sebastiaan. I tried the first option and that didn't seem to work.

    I will try the excluded pages option and see if that works, otherwise i may have to modify urlrewrite source.

    Is there any other simple way that i am missing?

    Cheers,
    Neil

  • Neil Campbell 58 posts 182 karma points
    May 26, 2010 @ 07:43
    Neil Campbell
    0

    For anyone who finds this, and needs similar functionality.
    I ended up modifying the UrlRewritingNet source and adding some custom functionality that stops all preceeding UrlRedirects if a certain url is matched. Then added the useSSL redirect after the new redirect.

Please Sign in or register to post replies

Write your reply to:

Draft