sslstream and certificates
From: Jakob Nielsen (a_at_b.c)
Date: 05/26/05
- Next message: Nicole Calinoiu: "Re: Appl. Security Problems"
- Previous message: otto: "Re: Impersonation through HttpModule"
- Next in thread: Joe Kaplan \(MVP - ADSI\): "Re: sslstream and certificates"
- Reply: Joe Kaplan \(MVP - ADSI\): "Re: sslstream and certificates"
- Reply: Dominick Baier [DevelopMentor]: "Re: sslstream and certificates"
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ] [ attachment ]
Date: Thu, 26 May 2005 16:23:30 +0200
Using net 2.0
I try creating a sslStream from a regular networkstream as folows
Socket clientSocket = serverSocket.EndAccept(result);
clientSocket.Blocking = true;
Stream clientStream = new NetworkStream(clientSocket);
SslStream sslStream = new SslStream(clientStream);
X509Certificate cert =
X509Certificate.CreateFromCertFile(@"c:\mycertificate.crt");
sslStream.AuthenticateAsServer(cert);
The call to AuthenticateAsServer fails with "The server mode SSL must use a
certificate with the associated private key"
What exactly should I put into that message? It needs another kind of
certificate with the private key embedded?
I do have a keyfile on the side with one of my certificates, but I can not
specify it anywhere.
Another certificate , I am testing with, is from rapidSSL a CA so I assume
it should be "right".
Has someone else tried setting up a sslStream as server?
Should i somehow put my private key into my certificate? I read somewhere
that you could concatenate the two files, but that didnt resolve the
problem.
- Next message: Nicole Calinoiu: "Re: Appl. Security Problems"
- Previous message: otto: "Re: Impersonation through HttpModule"
- Next in thread: Joe Kaplan \(MVP - ADSI\): "Re: sslstream and certificates"
- Reply: Joe Kaplan \(MVP - ADSI\): "Re: sslstream and certificates"
- Reply: Dominick Baier [DevelopMentor]: "Re: sslstream and certificates"
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ] [ attachment ]
Relevant Pages
|