473,414 Members | 1,848 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,414 software developers and data experts.

Using two client certificates for a SSL Webservice

I'd like to connect to a webservice using TLS/SSL. I have two separate
client certificates:
1. A certificate for digital verification
2. A certificate for encryption.

When I use the first one (i.e. add it to the ClientCertificates
collection of the web request), I can establish a connection but I get
a WebException: "Underlying connection closed: Could not establish
trust relationship". When I use the second one I can't even establish a
connection.

When I add both certificates to the ClientCertificates collection, it
seems only the first one I added is used and from what I found, I'd
think the certificate is used to set up the connection. So how do I
specify to use an alternate certificate for encryption?

You'd think that .NET should be able to find it out automatically by
looking at the certificate usage flags but it doesn't.

Any help would be greatly appreciated!

Nov 28 '06 #1
2 2628
Hi,

This article may help you to solve the problem, it mainly discusses
different approaches to secure a web service using X509 certificates.

http://msdn.microsoft.com/library/de...tpsecurity.asp

Regards,
Pablo Cibraro.
<b.*****@gmail.comwrote in message
news:11**********************@14g2000cws.googlegro ups.com...
I'd like to connect to a webservice using TLS/SSL. I have two separate
client certificates:
1. A certificate for digital verification
2. A certificate for encryption.

When I use the first one (i.e. add it to the ClientCertificates
collection of the web request), I can establish a connection but I get
a WebException: "Underlying connection closed: Could not establish
trust relationship". When I use the second one I can't even establish a
connection.

When I add both certificates to the ClientCertificates collection, it
seems only the first one I added is used and from what I found, I'd
think the certificate is used to set up the connection. So how do I
specify to use an alternate certificate for encryption?

You'd think that .NET should be able to find it out automatically by
looking at the certificate usage flags but it doesn't.

Any help would be greatly appreciated!

Nov 28 '06 #2
Hello Pablo,

The article describes how to secure a webservice. However, the
webservice is already working. The problem I have is that I need two
separate certificates for SSL: One for authentication and one for
encryption. Although I can supply more than one certificate using the
ClientCertificates.Add() method, it seems that only the first one is
used.

Cheers,
Bram
Hi,

This article may help you to solve the problem, it mainly discusses
different approaches to secure a web service using X509 certificates.

http://msdn.microsoft.com/library/de...tpsecurity.asp

Regards,
Pablo Cibraro.
<b.*****@gmail.comwrote in message
news:11**********************@14g2000cws.googlegro ups.com...
I'd like to connect to a webservice using TLS/SSL. I have two separate
client certificates:
1. A certificate for digital verification
2. A certificate for encryption.

When I use the first one (i.e. add it to the ClientCertificates
collection of the web request), I can establish a connection but I get
a WebException: "Underlying connection closed: Could not establish
trust relationship". When I use the second one I can't even establish a
connection.

When I add both certificates to the ClientCertificates collection, it
seems only the first one I added is used and from what I found, I'd
think the certificate is used to set up the connection. So how do I
specify to use an alternate certificate for encryption?

You'd think that .NET should be able to find it out automatically by
looking at the certificate usage flags but it doesn't.

Any help would be greatly appreciated!
Nov 28 '06 #3

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

0
by: languy | last post by:
Hi there, I have an ASP page, which have to connect to an SSL server that requires a client certificate, but I get the following error: Erroror Type: msxml3.dll (0x80072F0C) A certificate...
1
by: Next | last post by:
Hello, I sure could use someone's help : ) I need to authenticate users and securely upload files from laptops on the internet ( not on the same domain as server ) to a server on my domain....
0
by: Russ | last post by:
I have set up a C# web application that runs on my test Web Server (Windows 2003 Server, Web Edition). It in turn calls a web service running on the internal network. Now I want to issue a...
0
by: dinoo | last post by:
Can some body help me out? I am trying to use client certificates in a Webservice. But some how i am not able to make it. I went through the msdn resources but i think some one needs to help me...
0
by: Eric Rosenberger | last post by:
I am developing a web service that uses SSL client certificates for authentication. It works fine with self-generated certificates, but our customer's CA wants specific information about what...
0
by: Ron Fluegge | last post by:
We are developing a Winforms app that retrieves data from our company's SQL Server 2000 database via a webservice. We are considering using something like client certificates so that we have a...
5
by: | last post by:
Hi all, HttpWebRequest, and SoapHttpClientProtocol both expose a ClientCertificates property, which can hold multiple client certificates, but on the service side, it can only receive one client...
2
by: steveS | last post by:
Hi all, I'm having trouble connecting to a Java web service using HttpWebRequest. I get the error message "The request was aborted: Could not create SSL/TLS secure channel". The Java service...
0
by: Justin Carasick | last post by:
I am trying to understand the process for securing a webservice. I have set up an https iis web service and require client certificates. Now, as I understand it when I make the web service request I...
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...
0
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each...
0
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing,...
0
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.