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

  • SEARCH
  • Home
  • 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 6867253
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 27, 20262026-05-27T03:17:11+00:00 2026-05-27T03:17:11+00:00

Problem : I am unable to connect to a TLS enabled webservice endpoint using

  • 0

Problem :
I am unable to connect to a TLS enabled webservice endpoint using C#.net on windows7.
Fiddler request and response are :

request :-

CONNECT myendpoint:9443 HTTP/1.1
Host: myendpoint:9443
Proxy-Connection: Keep-Alive
”

and here’s the response :-

HTTP/1.1 502 Connection failed
Connection: close
Timestamp: 18:54:29.909

HTTPS connection failed.

*System.Net.Sockets.SocketException:
No connection could be made because the target machine actively refused it :9443
at Fiddler.ServerChatter.CreateConnectedSocket(IPAddress[] arrDestIPs, Int32 iPort, Session _oSession)*
*at Fiddler.Session._handleHTTPSConnect()*”

My client is a .net desktop/console application. I am not confident that i have done the client side TLS/Certificate setup/configuration correctly. Also I have a few unanswered questions.
I have done the following:

I have a “TLS enabled” endpoint of a internet web service. In order to communicate properly, I have been provided 4 things :

1) ca.cert.pem : The public certificate from the CA
2) myname.cert.pem : My public certificate
3) myname.key.pem : My private key
4) A password : “mypassword”

I have also been gives certificate request (.csr) and the parameters used to generate my certificate.

After reading up on TLS related stuff I figured this is what I need to do :

step1) Use Openssl to convert the ca.cert.pem to a .cer file and add/import it to Local Computer’s “Trusted Root Certificate Authorities” so that the CA is trusted now onwards.

step2) Combine myname.cert.pem and myname.key.pem into a .pkcs12 by doing
“openssl pkcs12 -export -out keystore.pkcs12 -in myname.cert.pem -inkey myname.key.pem“. This asks for a password where i use “mypassword”.

step3) Add the keystore.pkcs12 to the “Personal” Certificates (here it asks for a password and i give “mypassword”)

The thumbprint of the certificate added in the step3 is “fef4ab753a11a30a6c4342e63e00f237ef0818c1”

Now, here are app.config changes that i have made:

<bindings>
  <wsHttpBinding>
    <binding name="My_HTTPS_Endpoint_Binding" closeTimeout="00:01:00"
     openTimeout="00:01:00" receiveTimeout="00:10:00" sendTimeout="00:01:00"
     bypassProxyOnLocal="false" transactionFlow="false" hostNameComparisonMode="StrongWildcard"
     maxBufferPoolSize="2147483647" maxReceivedMessageSize="2147483647" messageEncoding="Text"
     textEncoding="utf-8" useDefaultWebProxy="true" allowCookies="false">
      <readerQuotas maxDepth="32" maxStringContentLength="2147483647" maxArrayLength="2147483647"
       maxBytesPerRead="4096" maxNameTableCharCount="2147483647" />
      <reliableSession ordered="true" inactivityTimeout="00:10:00"
       enabled="false" />
      <security mode="Transport">
        <transport clientCredentialType="Certificate" proxyCredentialType="None"
         realm="" />
        <message clientCredentialType="Windows" negotiateServiceCredential="true"
         establishSecurityContext="true" />
      </security>
    </binding>
  </wsHttpBinding>
</bindings>

<client>
  <endpoint address="https://myendpoint:9443/myService"
   binding="wsHttpBinding" bindingConfiguration="My_HTTPS_Endpoint_Binding"
   contract="MyNs.myClass" name="My_HTTPS_Endpoint" behaviorConfiguration="clientBehaviour" />
</client>

<behaviors>
  <endpointBehaviors>
    <behavior name="clientBehaviour">
      <clientCredentials>
        <clientCertificate findValue="fef4ab753a11a30a6c4342e63e00f237ef0818c1"
   storeLocation="LocalMachine"
   storeName="My"
   x509FindType="FindByThumbprint" />

      </clientCredentials>
    </behavior>
  </endpointBehaviors>
</behaviors>

So does it seem I have missed any crucial step ? I have some knowledge gaps:

1) My understanding is The public and private key combination i have is only useful for communication from server to client. How does the client to server message encryption work ? Where does my client get the public key from the server which needs to be used for message encryption ?

2) Is the password required to be provided in the config somewhere ? Just guessing..

  • 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-05-27T03:17:11+00:00Added an answer on May 27, 2026 at 3:17 am

    The issue turned out that the destination port config was buggy and they fixed it now. The port was unreachable

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I'm getting this problem: PHP Warning: mail() [function.mail]: SMTP server response: 550 5.7.1 Unable
We are unable to connect to an HTTPS server using WebRequest because of this
I have a seemingly simple problem though i am unable to get my head
I'm trying to write a re-usable .NET Assembly that implements WCF. My current problem
I've run into a weird problem yesterday. I am using selenium-rc along with C#
ive got a problem when trying to connect to a mysql db for blogengine
Problem deploying my jaudiotagger project since java.net moved from CollabNet to Project Kenai I
I am using this guide: http://www.asp.net/mvc/tutorials/mvc-music-store-part-7 Like instructed, I entered to ASP.NET Web Application
I have got this error Unable to connect to the remote server when I
Problem: I have an address field from an Access database which has been converted

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.