Last post Oct 08, 2013 05:03 AM by kirthi.royadu
Oct 15, 2010 12:04 AM|sedge.rev|LINK
I'm trying to receive a Client Certificate in a Web Service and having some problems.
Dim cert As X509Certificate = X509Certificate.CreateFromCertFile("C:\cert.cer")
Dim hw As String = _ws.HelloWorld
The certificate seems to be correclty loading and added to the client.
The client connects to the server with HTTPS.
Public Function HelloWorld() As String
Dim cert As HttpClientCertificate = Me.Context.Request.ClientCertificate
Return "Hello World"
cert.IsPresent is false and all certificate fields are empty.
IIS is configured to Accept Client Certificates.
Reproduced in two environments:
- Windows 7 x64, IIS 7, VS 2008, .NET 3.5
- XP x86, IIS 5, VS 2008, .NET 3.5
Always in the Web Service the Client Certificate is not proesent. I haven't been able to find any other configuration I should do. Can anyone help?
Oct 19, 2010 03:36 AM|Wencui Qian - MSFT|LINK
"\" is an escape character, and you need to handle the path correctly. Please try to add "@" before the string or use "\\" instead. Thanks.
Oct 08, 2013 05:03 AM|kirthi.royadu|LINK
I have the same problem on my machine. I have an asmx web service migrated to .net 4.5 and deployed on IIS and client calling into it by adding a client certificate into the proxy object before invoking the required method.
Any pointers would be useful.