Web Service Call Using Digital Certificates

B

bs

Hi,

I am currently having a problem calling a web service that is secured using
a digital certificate. I set up a Windows application to make a call to the
service and it works fine. However when I make a call from my ASP.NET page
it fails with "System.Net.WebException: The request failed with HTTP status
403: Forbidden". The code that I am using to make the call in both
instances is:
MyWebService myService = new MyWebService();

myService.ClientCertificates.Add(X509Certificate.CreateFromCertFile(@"C:\myC
ert.cer"));

myService.HelloWorld();

I think the problem may be related to permissions. The Windows application
runs using my account so I changed IIS to run as me as well. I have set
<identity impersonate="true"> in the web.config and I have checked using my
ASP.NET application that I am running under this account.

The Root CA certificate is installed under the "Current User" and the "Local
Computer" certificate stores and the client certificate is installed in both
these stores as well.

If anyone could help me solve this problem it would be great.

Ben
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

Forum statistics

Threads
473,744
Messages
2,569,479
Members
44,900
Latest member
Nell636132

Latest Threads

Top