When I add a Service Reference in Visual Studio to a service, it keeps adding this extendedProtectionPolicy
to my Security Bindings, which on my Win7 machine it works fine. But when I deploy to Server 2003 it errors out saying unrecognized element in configuration file.
Removing the line <extendedProtectionPolicy policyEnforcement="Never" />
fixes the error.
This is the entire portion of unwanted web.config generated after an Add Service Reference (client side)
<security mode="TransportWithMessageCredential">
<transport clientCredentialType="None" proxyCredentialType="None"
realm="">
<extendedProtectionPolicy policyEnforcement="Never" />
</transport>
<message clientCredentialType="UserName" algorithmSuite="Default" />
</security>
Here is the behavior my service is using (iis7-host side)
<behavior name="GetHttpsIncludeFaults">
<serviceCredentials>
<userNameAuthentication
userNamePasswordValidationMode="Custom"
customUserNamePasswordValidatorType="MyCustomValidator, MyOtherAssembly"/>
</serviceCredentials>
<serviceMetadata httpsGetEnabled="true" />
<serviceDebug includeExceptionDetailInFaults="true" />
</behavior>
I'd like to point out a few things. This happens in both VS2010 and VS2008. This happens in Consumer Projects of ASP.NET-MVC flavor AS WELL AS Windows Service / WPF Application.