title: Using custom tcp bindings
body: <p>I have a custom tcp binding I want to test on a service, specifically to disable the security:</p>
  
  <pre><code>&lt;bindings&gt;
    &lt;netTcpBinding&gt;
      &lt;binding name="customTcpBinding" maxReceivedMessageSize="20480000" transferMode="Streamed" &gt;
        &lt;security mode="None"&gt;&lt;/security&gt;
      &lt;/binding&gt;
    &lt;/netTcpBinding&gt;
  &lt;/bindings&gt;
  </code></pre>
  
  <p>However, upon using the tcp binding's name in the config I recieve this error:</p>
  
  <pre><code>    Severity    Code    Description Project File    Line
  Warning     The 'binding' attribute is invalid - The value 'customTcpBinding' is invalid according to its datatype 'serviceBindingType' - The Enumeration constraint failed.    Server  C:\Users\Totally Not Beau\documents\visual studio 2015\Projects\WCF Proj\WCF Proj\App.config    24
  </code></pre>
  
  <p>Endpoint config:</p>
  
  <pre><code>        &lt;endpoint 
            address="" 
            binding="customTcpBinding" 
            bindingConfiguration="" 
            contract="Server.IMyService"&gt;
          &lt;/endpoint&gt;
  </code></pre>
  
  <p>Whole file if it helps:</p>
  
  <pre><code>&lt;?xml version="1.0" encoding="utf-8" ?&gt;
  &lt;configuration&gt;
      &lt;startup&gt; 
          &lt;supportedRuntime version="v4.0" sku=".NETFramework,Version=v4.5.2" /&gt;
      &lt;/startup&gt;
      &lt;system.serviceModel&gt;
     &lt;behaviors&gt;
        &lt;serviceBehaviors&gt;
           &lt;behavior name=""&gt;
              &lt;serviceMetadata httpGetEnabled="false" /&gt;
              &lt;serviceDebug includeExceptionDetailInFaults="false" /&gt;
           &lt;/behavior&gt;
        &lt;/serviceBehaviors&gt;
     &lt;/behaviors&gt;
      &lt;bindings&gt;
        &lt;netTcpBinding&gt;
          &lt;binding name="customTcpBinding" maxReceivedMessageSize="20480000" transferMode="Streamed" &gt;
            &lt;security mode="None"&gt;&lt;/security&gt;
          &lt;/binding&gt;
        &lt;/netTcpBinding&gt;
      &lt;/bindings&gt;
     &lt;services&gt;
         &lt;service name="Server.MyService"&gt;
             &lt;endpoint address="" binding="customTcpBinding" bindingConfiguration=""
                 contract="Server.IMyService"&gt;
             &lt;/endpoint&gt;
             &lt;endpoint address="mex" binding="mexTcpBinding" bindingConfiguration=""
                 contract="IMetadataExchange" /&gt;
             &lt;host&gt;
                 &lt;baseAddresses&gt;
                     &lt;add baseAddress="net.tcp://192.168.2.7:8732/MyService/" /&gt;
                 &lt;/baseAddresses&gt;
             &lt;/host&gt;
         &lt;/service&gt;
     &lt;/services&gt;
  &lt;/system.serviceModel&gt;
  &lt;/configuration&gt;
  </code></pre>
  
  <p>Any advice would be greatly appreciated!</p>