There are lots of existing questions/answers with subsets of my question (basicHttpBinding with Windows Authentication, using custom bindings, specifying binaryMessageEncoding). However, there are no existing answers with this particular combination of all THREE of those items.
I started with a simple WCF service using basicHttpBinding, with Windows authentication, so the bindings section looked like:
<bindings>
<basicHttpBinding>
<binding name="BasicHttpWindowsBinding">
<security mode="TransportCredentialOnly">
<transport clientCredentialType="Windows" />
</security>
</binding>
</basicHttpBinding>
</bindings>
I tested the WCF service and it works just fine with respect to Windows authentication. But then, I wanted to utilize binary message encoding to boost performance. So, that's when I veered into custom binding territory because it appears that one can only specify binary message encoding for basicHttpBinding in a custom binding section, such as for example:
<bindings>
<customBinding>
<binding name="BasicHttpWindowsBinding">
<binaryMessageEncoding />
<httpTransport />
</binding>
</customBinding>
</bindings>
(And I need this EXACT combination of things; please don't advise me to switch to wsHttpBinding, or use netTcpBinding, etc.)
But now I have a problem (unless I'm missing something) because you can only specify the windows authentication under the basicHttpBinding section, and you can only specify the binaryMessageEncoding for the http protocol under the customBinding section.
So my question is, how does one specify basicHttpBinding protocol, with Windows authentication, and using binaryMessageEncoding, if it is possible? (I have to be honest and admit that I am finding the configuration of WCF services to be very difficult to grok, at least when custom bindings are thrown into the mix...)
I THINK that the correct custom binding specifications would be:
<bindings>
<customBinding>
<binding name="BasicHttpWindowsBinding">
<binaryMessageEncoding />
<httpTransport authenticationScheme="Windows" />
</binding>
</customBinding>
</bindings>
... but is this really exactly equivalent to
<bindings>
<basicHttpBinding>
<binding name="BasicHttpWindowsBinding">
<security mode="TransportCredentialOnly">
<transport clientCredentialType="Windows" />
</security>
</binding>
</basicHttpBinding>
</bindings>
... with respect to specifying windows authentication (Kerberos, not just Ntlm) for the WCF service?