Home » Programming / Coding

WebPageSecurity Redirects to Url With Port Number – ASP .NET

15 July 2010 1,687 views One Comment

http://www.codeproject.com/KB/web-security/WebPageSecurity_v2.aspx is a great module for switching between https and http in IIS.

With version 3 you might get the port number on the redirected url.
For example you get for unencrypted url
http://www.yoursite.com:8059/default.aspx

Which supposed to be
http://www.yoursite.com/default.aspx

To solve this problem define the encryptedUri and unencryptedUri. And thats without https or http. For example:

<secureWebPages mode="RemoteOnly" ignoreHandlers="WithStandardExtensions" encryptedUri="www.yoursite.com" unencryptedUri="www.yoursite.com" maintainPath="True">
................
................
</secureWebPages>

From Webmaster Forum http://www.webcosmoforums.com/asp/20887-webpagesecurity-redirects-url-port-number-asp-net.html

1 Star2 Stars3 Stars4 Stars5 Stars (No Ratings Yet)
Loading ... Loading ...

One Comment »

Leave your response!

Add your comment below, or trackback from your own site. You can also subscribe to these comments via RSS.

Be nice. Keep it clean. Stay on topic. No spam.

You can use these tags:
<a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <strike> <strong>

This is a Gravatar-enabled weblog. To get your own globally-recognized-avatar, please register at Gravatar.