http://code.msdn.microsoft.com/odcsp14ta/Release/ProjectReleases.aspx?ReleaseId=4744
If you are working with Visual Studio 2010, chances are that the source code will not work as downloaded. Therefore, I will provide the steps that you will need to follow in order to get many of these projects functioning as expected.
Once you have downloaded and extracted the project file, you will want to open the project in Visual Studio. In most cases, the code samples include one or more Claims-Aware web sites.
Since Visual Studio 2010 will by default want to try and use the built-in Cassini Web Server, Visual Studio will have the property for Use dynamic ports set to true. To correct this problem, do the following
- Right click on the Visual Studio web site project and select the Properties window
- Select the field for Use dynamic ports
- From the dropdown list selection, select False
- Save the project
- Repeat this process for as many web site projects as are present in the Visual Studio solution
If the solution is using an STS (Security Token Service), chances are that the Claims-aware Web Site will not work out-of-the-box with the STS configured in the Visual Studio solution.
To rectify this situation, you must perform the following steps:
- Right click on the Visual Studio project containing the Claims-aware Web Site
- Select Add STS Reference
- This will launch the Federation Utility wizard
- By default, the Federation Utility wizard should be populated with the correct location paths
- If the content is correctly populated, click on the Next button
- If you are prompted with a dialog stating that the application is not hosted on a secure connection, click on the Yes button to continue
- On the following screen, click on the radio button next to Use an existing STS (NOTE: If you are using the built-in Visual Studio Web Server, the Url will not be available until you browse to a web page in the STS Web Site which effectively starts the Cassini Web Server)
- For the STS WS-Federation metadata document location, enter the Url to the existing STS Web Site configured in the Visual Studio solution (ex: http://localhost:48924/WingtipSTS/FederationMetadata/2007-06/FederationMetadata.xml)
- If you wish to verify the Url, click on the Test Location button
- If you are prompted with a dialog stating that the security token service endpoint is not hosted on a secure connection, click on the Yes button to continue
- If you receive a signing certificate chain validation error dialog, click on the radio button for Disable certificate chain validation (since this is a development environment) and click on the Next button
- On the Security Token dialog, select the radio button for No encryption and click on the Next button
- If everything is configured correctly, you should see a dialog displaying the Offered Claims from the STS Web Site. Click the Next button to proceed
- The final dialog will be a Summary dialog. Click Finish on the Summary dialog to complete the Federation Utility wizard.
- A final message box will display stating Federation Utility completed successfully.
No comments:
Post a Comment