Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • Home
  • SEARCH
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 7872119
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 3, 20262026-06-03T02:06:50+00:00 2026-06-03T02:06:50+00:00

In short: I cannot get my console client connected to an https endpoint of

  • 0

In short: I cannot get my console client connected to an https endpoint of the WCF service which is hosted on another PC in the same network. It pops up an error at debug time at: Object loginObject = client.Login(password, username); and says:Unable to automatically step into this server machine domain.Connecting to the server machine failed. Logon failure:unknown user name or bad password.

I am not hosting this on IIS, i just host the service from visual studio

—–for more details check below—–

I have a wcf service hosted in console on a computer, the config file with only the binding, endpoint and behaviour, looks like this:

<bindings>
  <wsHttpBinding>
    <binding
    name="HighQuotaWSHttpBinding"
    receiveTimeout="00:10:00"
    sendTimeout="00:10:00"
    bypassProxyOnLocal="true"
    maxBufferPoolSize="2147483647"
    useDefaultWebProxy="false"
    maxReceivedMessageSize="2147483647">
      <security mode="Transport">
        <transport clientCredentialType="Certificate" />
      </security>
    </binding>
  </wsHttpBinding>
</bindings>

<services>
  <!-- WebDataService -->
  <service
  behaviorConfiguration="WebDataServiceBehaviour"
  name="ANameSpace">
    <endpoint
    address="WebDataService"
    binding="wsHttpBinding" bindingConfiguration="HighQuotaWSHttpBinding"
    contract="AContract"
    name="WebDataServiceHttpBinding">
      <!--<identity>
<dns value="" />
</identity>-->
    </endpoint>
    <endpoint
    address="mex"
    binding="mexHttpsBinding"
    contract="IMetadataExchange"
    name="mexManagement" />
    <host>
      <baseAddresses>
        <add baseAddress="http://mylocalip:9650/" />
        <add baseAddress="https://mylocalip:9651/" />
      </baseAddresses>
    </host>
  </service>
</services>

<!-- Definition of WebDataService behaviour -->
<behaviors>
  <serviceBehaviors>
    <!-- Behavior for WebserviceData interface -->
    <behavior name="WebDataServiceBehaviour">
      <!-- Set throttling of (concurrent) cals -->
      <serviceThrottling
      maxConcurrentCalls="100"
      maxConcurrentSessions="100"
      maxConcurrentInstances="100"/>
      <!-- To avoid disclosing metadata information, 
set the value below to false and remove the metadata endpoint above before deployment -->
      <serviceMetadata httpsGetEnabled="True"/>
      <serviceCredentials>
        <!--certificate storage path in the server -->
        <serviceCertificate findValue="localhost" x509FindType="FindBySubjectName" storeLocation="LocalMachine"  storeName="My"/>
        <issuedTokenAuthentication allowUntrustedRsaIssuers="true"/>
        <!--certificate storage path in the client -->
        <clientCertificate>
          <certificate findValue="localhost" x509FindType="FindBySubjectName" storeLocation="LocalMachine" storeName="My"/>
        </clientCertificate>
        <userNameAuthentication userNamePasswordValidationMode="MembershipProvider"/>
      </serviceCredentials>
    </behavior>
  </serviceBehaviors>

  <endpointBehaviors>
    <behavior name="WebDataServiceBehaviour">
      <clientCredentials>
        <!--certificate storage path in the client -->
        <clientCertificate findValue="localhost" storeLocation="LocalMachine" x509FindType="FindBySubjectName" storeName="My"/>
        <serviceCertificate>
          <authentication certificateValidationMode="PeerOrChainTrust"/>
        </serviceCertificate>
      </clientCredentials>
    </behavior>
  </endpointBehaviors>
</behaviors>
</system.serviceModel>
</configuration>

I made my own root and server certificate by doing this:

Root:
makecert.exe -sv SignRoot.pvk -cy authority -r signroot.cer -a sha1 -n “CN=AuthorityName” -ss my -sr localmachine

Server:
makecert.exe -iv SignRoot.pvk -ic signroot.cer -cy end -pe -n CN=”localhost” -eku 1.3.6.1.5.5.7.3.1 -ss my -sr localmachine -sky exchange -sp “Microsoft RSA SChannel Cryptographic Provider” -sy 12

Then with a program called httpconfig.exe i added this cert to the ports 9651..

Now on another pc in the same network I try to make a simple C# console client..
The program.cs is as follows:

class Program
{
    static void Main(string[] args)
    {


        System.Net.ServicePointManager.ServerCertificateValidationCallback += (se, cert, chain, sslerror) =>
        {
            return true;
        };
        wcf1.WebDataServiceClient client = new wcf1.WebDataServiceClient();



        string username = "A";
        string password = "A";
        Object loginObject = client.Login(password, username);
        Console.WriteLine("bla");
        Console.ReadLine();
        client.Close();
    }
}

and the config is generated as follows:

  <system.serviceModel>
    <bindings>
      <wsHttpBinding>
        <binding name="WebDataServiceHttpBinding" closeTimeout="00:01:00"
            openTimeout="00:01:00" receiveTimeout="00:10:00" sendTimeout="00:01:00"
            bypassProxyOnLocal="false" transactionFlow="false" hostNameComparisonMode="StrongWildcard"
            maxBufferPoolSize="524288" maxReceivedMessageSize="65536"
            messageEncoding="Text" textEncoding="utf-8" useDefaultWebProxy="true"
            allowCookies="false">
          <readerQuotas maxDepth="32" maxStringContentLength="8192" maxArrayLength="16384"
              maxBytesPerRead="4096" maxNameTableCharCount="16384" />
          <reliableSession ordered="true" inactivityTimeout="00:10:00"
              enabled="false" />
          <security mode="Transport">
            <transport clientCredentialType="Certificate" proxyCredentialType="None"
                realm="" />
            <message clientCredentialType="Windows" negotiateServiceCredential="true" />
          </security>
        </binding>
      </wsHttpBinding>
    </bindings>
    <client>
      <endpoint address="https://Theipfromthepc:9651/WebDataService" binding="wsHttpBinding"
          bindingConfiguration="WebDataServiceHttpBinding" contract="wcf1.IWebDataService"
          name="WebDataServiceHttpBinding">
        <!--<identity>
<dns value="" />
</identity>-->

      </endpoint>
    </client>
  </system.serviceModel>
  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-03T02:06:51+00:00Added an answer on June 3, 2026 at 2:06 am

    clientCredentialType="Certificate" means that the client will authenticate itself using a client certificate, but you have not provided a client certficate. You have only created a server certificate. Depending on how you have configured your server, chances are you want either:

    clientCredentialType = "None"
    

    or

    clientCredentlaType = "Windows"
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

In short, I get following error: QObject::connect: Cannot queue arguments of type 'cv::Mat' (Make
Short best practice question: If an object A is injected into another object B,
Short version: I have a similar setup to StackOverflow. Users get Achievements. I have
short version: how can I get rid of the multiple-versions-of-python nightmare ? long version:
Is it possible to get a HttpSession object by session ID, which is submitted
I cannot get a string broken into fixed length chunks and added to an
Short version: When I try to use Access's DatePart function via ODBC, it cannot
Short version : echo testing | vim - | grep good This doesn't work
Short version: Is it easy/feasible/possible to program modal window in Flash (AS3)? Is there
SHORT INTRO: I'm having trouble with a 3D cube on a plane. The plane

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.