ECDiffieHellmanOpenSsl Construtores

Definição

Sobrecargas

ECDiffieHellmanOpenSsl()

Inicializa uma nova instância da classe ECDiffieHellmanOpenSsl, com uma curva padrão de NIST P-521/secp521r1.

ECDiffieHellmanOpenSsl(Int32)

Inicializa uma nova instância da classe ECDiffieHellmanOpenSsl estabelecendo como padrão a curva principal do NIST do tamanho especificado.

ECDiffieHellmanOpenSsl(IntPtr)

Inicializa uma nova instância da ECDiffieHellmanOpenSsl classe de uma chave OpenSSL existente representada como um EC_KEY*.

ECDiffieHellmanOpenSsl(ECCurve)

Inicializa uma nova instância da classe ECDiffieHellmanOpenSsl e gera uma nova chave na curva especificada.

ECDiffieHellmanOpenSsl(SafeEvpPKeyHandle)

Inicializa uma nova instância da ECDiffieHellmanOpenSsl classe de uma chave OpenSSL existente representada como um EVP_PKEY*.

ECDiffieHellmanOpenSsl()

Origem:
ECDiffieHellmanOpenSsl.cs
Origem:
ECDiffieHellmanOpenSsl.cs
Origem:
ECDiffieHellmanOpenSsl.cs

Inicializa uma nova instância da classe ECDiffieHellmanOpenSsl, com uma curva padrão de NIST P-521/secp521r1.

public:
 ECDiffieHellmanOpenSsl();
public ECDiffieHellmanOpenSsl ();
[System.Runtime.Versioning.UnsupportedOSPlatform("android")]
[System.Runtime.Versioning.UnsupportedOSPlatform("browser")]
[System.Runtime.Versioning.UnsupportedOSPlatform("ios")]
[System.Runtime.Versioning.UnsupportedOSPlatform("tvos")]
[System.Runtime.Versioning.UnsupportedOSPlatform("windows")]
public ECDiffieHellmanOpenSsl ();
Public Sub New ()
Atributos

Comentários

Esse construtor não gera um novo keypair público/privado imediatamente, apenas define o tamanho que será usado para gerar uma chave quando for necessário. Se a chave for carregada por meio do ImportParameters método ou de outro método de importação de chave, o tamanho da chave desse construtor não terá nenhum significado.

Confira também

Aplica-se a

ECDiffieHellmanOpenSsl(Int32)

Origem:
ECDiffieHellmanOpenSsl.cs
Origem:
ECDiffieHellmanOpenSsl.cs
Origem:
ECDiffieHellmanOpenSsl.cs

Inicializa uma nova instância da classe ECDiffieHellmanOpenSsl estabelecendo como padrão a curva principal do NIST do tamanho especificado.

public:
 ECDiffieHellmanOpenSsl(int keySize);
public ECDiffieHellmanOpenSsl (int keySize);
[System.Runtime.Versioning.UnsupportedOSPlatform("android")]
[System.Runtime.Versioning.UnsupportedOSPlatform("browser")]
[System.Runtime.Versioning.UnsupportedOSPlatform("ios")]
[System.Runtime.Versioning.UnsupportedOSPlatform("tvos")]
[System.Runtime.Versioning.UnsupportedOSPlatform("windows")]
public ECDiffieHellmanOpenSsl (int keySize);
new System.Security.Cryptography.ECDiffieHellmanOpenSsl : int -> System.Security.Cryptography.ECDiffieHellmanOpenSsl
[<System.Runtime.Versioning.UnsupportedOSPlatform("android")>]
[<System.Runtime.Versioning.UnsupportedOSPlatform("browser")>]
[<System.Runtime.Versioning.UnsupportedOSPlatform("ios")>]
[<System.Runtime.Versioning.UnsupportedOSPlatform("tvos")>]
[<System.Runtime.Versioning.UnsupportedOSPlatform("windows")>]
new System.Security.Cryptography.ECDiffieHellmanOpenSsl : int -> System.Security.Cryptography.ECDiffieHellmanOpenSsl
Public Sub New (keySize As Integer)

Parâmetros

keySize
Int32

O tamanho da chave a ser gerada, quando uma chave é necessária.

Atributos

Exceções

O valor keySize não é compatível com esta implementação.

Comentários

Somente três tamanhos de chave têm suporte neste construtor: 256 (NIST P-256/secp256r1), 384 (NIST P-384/secp384r1) e 521 (NIST P-521/secp521r1). Para gerar chaves Para qualquer outra curva, use o ECDiffieHellmanOpenSsl(ECCurve) construtor ou o GenerateKey(ECCurve) método .

Esse construtor não gera um novo keypair público/privado imediatamente, apenas define o tamanho que será usado para gerar uma chave quando for necessário. Se a chave for carregada por meio do ImportParameters método ou de outro método de importação de chave, o tamanho da chave desse construtor não terá nenhum significado.

Confira também

Aplica-se a

ECDiffieHellmanOpenSsl(IntPtr)

Origem:
ECDiffieHellmanOpenSsl.cs
Origem:
ECDiffieHellmanOpenSsl.cs
Origem:
ECDiffieHellmanOpenSsl.cs

Inicializa uma nova instância da ECDiffieHellmanOpenSsl classe de uma chave OpenSSL existente representada como um EC_KEY*.

public:
 ECDiffieHellmanOpenSsl(IntPtr handle);
public ECDiffieHellmanOpenSsl (IntPtr handle);
[System.Runtime.Versioning.UnsupportedOSPlatform("android")]
[System.Runtime.Versioning.UnsupportedOSPlatform("browser")]
[System.Runtime.Versioning.UnsupportedOSPlatform("ios")]
[System.Runtime.Versioning.UnsupportedOSPlatform("tvos")]
[System.Runtime.Versioning.UnsupportedOSPlatform("windows")]
public ECDiffieHellmanOpenSsl (IntPtr handle);
new System.Security.Cryptography.ECDiffieHellmanOpenSsl : nativeint -> System.Security.Cryptography.ECDiffieHellmanOpenSsl
[<System.Runtime.Versioning.UnsupportedOSPlatform("android")>]
[<System.Runtime.Versioning.UnsupportedOSPlatform("browser")>]
[<System.Runtime.Versioning.UnsupportedOSPlatform("ios")>]
[<System.Runtime.Versioning.UnsupportedOSPlatform("tvos")>]
[<System.Runtime.Versioning.UnsupportedOSPlatform("windows")>]
new System.Security.Cryptography.ECDiffieHellmanOpenSsl : nativeint -> System.Security.Cryptography.ECDiffieHellmanOpenSsl
Public Sub New (handle As IntPtr)

Parâmetros

handle
IntPtr

nativeint

O valor OpenSSL EC_KEY* a ser usado como a chave.

Atributos

Exceções

handle é Zero.

handle não é um EC_KEY* válido.

Comentários

Importante

O OpenSSL dá suporte a várias versões de biblioteca que estão sendo carregadas no mesmo processo. Antes de chamar esse construtor, verifique se o valor do ponteiro veio da mesma versão do OpenSSL que essa classe usa. Para obter mais informações, consulte OpenSslVersion.

Confira também

Aplica-se a

ECDiffieHellmanOpenSsl(ECCurve)

Origem:
ECDiffieHellmanOpenSsl.cs
Origem:
ECDiffieHellmanOpenSsl.cs
Origem:
ECDiffieHellmanOpenSsl.cs

Inicializa uma nova instância da classe ECDiffieHellmanOpenSsl e gera uma nova chave na curva especificada.

public:
 ECDiffieHellmanOpenSsl(System::Security::Cryptography::ECCurve curve);
public ECDiffieHellmanOpenSsl (System.Security.Cryptography.ECCurve curve);
[System.Runtime.Versioning.UnsupportedOSPlatform("android")]
[System.Runtime.Versioning.UnsupportedOSPlatform("browser")]
[System.Runtime.Versioning.UnsupportedOSPlatform("ios")]
[System.Runtime.Versioning.UnsupportedOSPlatform("tvos")]
[System.Runtime.Versioning.UnsupportedOSPlatform("windows")]
public ECDiffieHellmanOpenSsl (System.Security.Cryptography.ECCurve curve);
new System.Security.Cryptography.ECDiffieHellmanOpenSsl : System.Security.Cryptography.ECCurve -> System.Security.Cryptography.ECDiffieHellmanOpenSsl
[<System.Runtime.Versioning.UnsupportedOSPlatform("android")>]
[<System.Runtime.Versioning.UnsupportedOSPlatform("browser")>]
[<System.Runtime.Versioning.UnsupportedOSPlatform("ios")>]
[<System.Runtime.Versioning.UnsupportedOSPlatform("tvos")>]
[<System.Runtime.Versioning.UnsupportedOSPlatform("windows")>]
new System.Security.Cryptography.ECDiffieHellmanOpenSsl : System.Security.Cryptography.ECCurve -> System.Security.Cryptography.ECDiffieHellmanOpenSsl
Public Sub New (curve As ECCurve)

Parâmetros

curve
ECCurve

A curva usada para gerar um par de chaves pública/privada efêmero.

Atributos

Exceções

curve não é validado.

Confira também

Aplica-se a

ECDiffieHellmanOpenSsl(SafeEvpPKeyHandle)

Origem:
ECDiffieHellmanOpenSsl.cs
Origem:
ECDiffieHellmanOpenSsl.cs
Origem:
ECDiffieHellmanOpenSsl.cs

Inicializa uma nova instância da ECDiffieHellmanOpenSsl classe de uma chave OpenSSL existente representada como um EVP_PKEY*.

public:
 ECDiffieHellmanOpenSsl(System::Security::Cryptography::SafeEvpPKeyHandle ^ pkeyHandle);
public ECDiffieHellmanOpenSsl (System.Security.Cryptography.SafeEvpPKeyHandle pkeyHandle);
[System.Runtime.Versioning.UnsupportedOSPlatform("android")]
[System.Runtime.Versioning.UnsupportedOSPlatform("browser")]
[System.Runtime.Versioning.UnsupportedOSPlatform("ios")]
[System.Runtime.Versioning.UnsupportedOSPlatform("tvos")]
[System.Runtime.Versioning.UnsupportedOSPlatform("windows")]
public ECDiffieHellmanOpenSsl (System.Security.Cryptography.SafeEvpPKeyHandle pkeyHandle);
new System.Security.Cryptography.ECDiffieHellmanOpenSsl : System.Security.Cryptography.SafeEvpPKeyHandle -> System.Security.Cryptography.ECDiffieHellmanOpenSsl
[<System.Runtime.Versioning.UnsupportedOSPlatform("android")>]
[<System.Runtime.Versioning.UnsupportedOSPlatform("browser")>]
[<System.Runtime.Versioning.UnsupportedOSPlatform("ios")>]
[<System.Runtime.Versioning.UnsupportedOSPlatform("tvos")>]
[<System.Runtime.Versioning.UnsupportedOSPlatform("windows")>]
new System.Security.Cryptography.ECDiffieHellmanOpenSsl : System.Security.Cryptography.SafeEvpPKeyHandle -> System.Security.Cryptography.ECDiffieHellmanOpenSsl
Public Sub New (pkeyHandle As SafeEvpPKeyHandle)

Parâmetros

pkeyHandle
SafeEvpPKeyHandle

O valor OpenSSL EVP_PKEY* a ser usado como a chave, representado como um SafeEvpPKeyHandle.

Atributos

Exceções

pkeyHandle representa um identificador inválido.

pkeyHandle é null.

pkeyHandle não representa uma chave de EC (curva elíptica).

Comentários

Importante

O OpenSSL dá suporte a várias versões de biblioteca que estão sendo carregadas no mesmo processo. Antes de chamar esse construtor, verifique se o valor do ponteiro veio da mesma versão do OpenSSL que essa classe usa. Para obter mais informações, consulte OpenSslVersion.

Confira também

Aplica-se a