title: TLS for securing acces to web services
body: <p>I need to send the combination (login name / User Password) from my web application to a web service that autenticate all employees in all the companie's programs. But what is happening rigth now is plain text going throught the wire. I was asked to use TLS (not SSL3) in order to encrypt the combination for decent security (asp.net 4.0 Framework, c#).</p>
  
  <p>The problem is I don't even know where to start, everywhere I look for similar questions, I see peoples that are arleady very close to there goal, only needing one last line of code to confirm the certificate or one last little configuration to allow the "handshake" process. </p>
  
  <p>The way I am accessing my web services seems TOO SIMPLE, maybe I have to start all over from the begining, that's is why I want to ask poeple first. Here is how i call the web service's fonctions :</p>
  
  <p>In the Web.Config :</p>
  
  <pre><code>//Binding
  
  
  &lt;binding name="BasicHttpBinding_ICommun1" closeTimeout="00:01:00"
        openTimeout="00:01:00" receiveTimeout="00:10:00" sendTimeout="00:01:00"
        allowCookies="false" bypassProxyOnLocal="false" hostNameComparisonMode="StrongWildcard"
        maxBufferSize="65536" maxBufferPoolSize="524288" maxReceivedMessageSize="65536"
        messageEncoding="Text" textEncoding="utf-8" transferMode="Buffered"
        useDefaultWebProxy="true"&gt;
        &lt;readerQuotas maxDepth="32" maxStringContentLength="8192" maxArrayLength="16384"
          maxBytesPerRead="4096" maxNameTableCharCount="16384" /&gt;
        &lt;security mode="None"&gt;
          &lt;transport clientCredentialType="None" proxyCredentialType="None"
            realm="" /&gt;
          &lt;message clientCredentialType="UserName" algorithmSuite="Default" /&gt;
        &lt;/security&gt;
  
  //Declaring EndPoint
  
  &lt;endpoint address="http://CannotTellYouThat.svc"
      binding="basicHttpBinding" bindingConfiguration="BasicHttpBinding_ICommun1"
      contract="NameOfTheService.ICommun" name="BasicHttpBinding_ICommun1" /&gt;
  </code></pre>
  
  <p>In the C# class, I only need this :</p>
  
  <pre><code>public NameOfTheService.Utilisateur login(string ip, string nomUtilisateur, string userPass)
  {
  
      NameOfTheService.CommunClient instance = new NameOfTheService.CommunClient();
  
  
      return instance.Authentifier(ip, nomUtilisateur, userPass, AuthentificationServices.SystemeEnum.AppName);
  }
  </code></pre>
  
  <p>It returns a User (Utilisateur) with all the informations needed. This looks like I have to remove the web.Config binding and do all that in the C#. Any kind of help or advice would be welcome. Thanks.</p>