Making WIF local STS to work with your ASP.NET application

Posted by DigiMortal on ASP.net Weblogs See other posts from ASP.net Weblogs or by DigiMortal
Published on Thu, 17 Feb 2011 14:22:42 GMT Indexed on 2011/02/17 15:25 UTC
Read the original article Hit count: 308

Filed under:
|

Making Windows Identity Foundation (WIF) STS test application work with your solution is not as straightforward process as you can read from books and articles. There are some tricks and some configuration modifications you must do to get things work. Fortunately these steps are simple one.

1. Move your application to IIS or IIS Express

If your application uses development web server that ships with Visual Studio then make your application use IIS or IIS Express. You get simple support for IIS Express to Visual Studio 2010 after installing Visual Studio 2010 SP1. You can read more from my blog posting Visual Studio 2010 SP1 Beta supports IIS Express.

NB! You don’t have to move your dummy STS project to IIS.

2. Change request validation mode to ASP.NET 2.0

As a next thing you will get the following error when coming back from dummy STS service:

HttpRequestValidationException (0x80004005): A potentially dangerous Request.Form value was detected from the client.

Open web.config of your application and add the following line before </system.web>:

<httpRuntime requestValidationMode="2.0" />

Now you are done with configuring web application to work with STS.

© ASP.net Weblogs or respective owner

Related posts about ASP.NET

Related posts about WIF