WCF: how to use AllowInsecureTransport

In the context of .NET 4 WCF, I am trying to use the new AllowInsecureTransport attribute so that I can use my own authentication without using SSL (only in our development environment - we use SSL in the production process).

My bindings configuration looks like this:

<bindings> <wsHttpBinding> <binding name="CustomAuthentication"> <security mode="TransportWithMessageCredential" allowInsecureTransport="true"> <transport clientCredentialType="None" /> <message clientCredentialType="UserName"/> </security> </binding> </wsHttpBinding> </bindings> 

However, I get an Unrecognized "allowInsecureTransport" error. This attribute has been described in this thread and help on msdn .

Can someone help me with my rather inept knowledge of WCF configuration options and point me in the right direction?

I would prefer not to use ClearUsernameBinding , as described here , but will be if there is no other built-in option.

+4
source share
1 answer

I really believe that the element is only accessible through user binding ... if you see the documents, this is part of the SecurityBindingElement, not part of the standard binding, such as wsHttpBinding. The thread you pointed to has a configuration example using custom bindings to enable it.

+4
source

All Articles