Re: sslstream and certificates
From: Dominick Baier [DevelopMentor] (dbaier_at_pleasepleasenospamdevelop.com)
Date: 05/26/05
- Next message: Dominick Baier [DevelopMentor]: "Re: Impersonation through HttpModule"
- Previous message: Jakob Nielsen: "Re: sslstream and certificates"
- In reply to: Jakob Nielsen: "sslstream and certificates"
- Next in thread: Jakob Nielsen: "Re: sslstream and certificates"
- Reply: Jakob Nielsen: "Re: sslstream and certificates"
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ] [ attachment ]
Date: Thu, 26 May 2005 09:55:46 -0700
Hello Jakob,
i described the procedure
here: http://www.leastprivilege.com/PermaLink.aspx?guid=f34680fd-a58d-43a7-ba6d-2d813814ee73
and here: http://www.leastprivilege.com/PermaLink.aspx?guid=6b5d5471-0710-41d7-891b-308afa959a6e
---------------------------------------
Dominick Baier - DevelopMentor
http://www.leastprivilege.com
> 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: Dominick Baier [DevelopMentor]: "Re: Impersonation through HttpModule"
- Previous message: Jakob Nielsen: "Re: sslstream and certificates"
- In reply to: Jakob Nielsen: "sslstream and certificates"
- Next in thread: Jakob Nielsen: "Re: sslstream and certificates"
- Reply: Jakob Nielsen: "Re: sslstream and certificates"
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ] [ attachment ]
Relevant Pages
|