You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I have a .NET x509 cert (System.Security.Cryptography.X509Certificates.X509Certificate2) with its private key which I'd like to use to make a client authentication in a regular tls session (The BC part is the client side).
For this, I'm inheriting TlsCredentials that I expect to return when TlsAuthentication.GetCredentials is called.
In short, this part looks like,
internal class CredentialsWithDotnetCert : TlsCredentials
{
public CredentialsWithDotnetCert(X509Certificate2 certificate, BcTlsCrypto crypto)
{
// .... how to get Certificate from System.Security.Cryptography.X509Certificates.X509Certificate2 ?
Certificate = new Certificate(new TlsCertificate[] { ..... });
}
public Certificate Certificate { get; }
}
But, I'm struggling to create a Org.BouncyCastle.Tls.Certificate from the System.Security.Cryptography.X509Certificates.X509Certificate2 object. Any idea?
I'm not bound to this particular implementation and I'm open to any other way to make this client auth work.
Thank you,
The text was updated successfully, but these errors were encountered:
I have a .NET x509 cert (
System.Security.Cryptography.X509Certificates.X509Certificate2
) with its private key which I'd like to use to make a client authentication in a regular tls session (The BC part is the client side).For this, I'm inheriting
TlsCredentials
that I expect to return whenTlsAuthentication.GetCredentials
is called.In short, this part looks like,
But, I'm struggling to create a Org.BouncyCastle.Tls.Certificate from the
System.Security.Cryptography.X509Certificates.X509Certificate2
object. Any idea?I'm not bound to this particular implementation and I'm open to any other way to make this client auth work.
Thank you,
The text was updated successfully, but these errors were encountered: