ECDiffieHellman.Create Метод

Определение

Создает новый экземпляр реализации алгоритма elliptic Curve Diffie-Hellman (ECDH).

Перегрузки

Имя Описание
Create()

Создает новый экземпляр реализации по умолчанию алгоритма elliptic Curve Diffie-Hellman (ECDH).

Create(ECCurve)

Создает новый экземпляр реализации по умолчанию алгоритма elliptic Curve Diffie-Hellman (ECDH) с новой парой открытого и закрытого ключа, созданной по заданной кривой.

Create(ECParameters)

Создает новый экземпляр реализации по умолчанию алгоритма elliptic Curve Diffie-Hellman (ECDH) с ключом, описанным указанным ECParameters объектом.

Create(String)
Устаревшие.

Создает новый экземпляр указанной реализации алгоритма elliptic Curve Diffie-Hellman (ECDH).

Create()

Исходный код:
ECDiffieHellman.Create.OpenSsl.cs
Исходный код:
ECDiffieHellman.Create.OpenSsl.cs
Исходный код:
ECDiffieHellman.Create.OpenSsl.cs
Исходный код:
ECDiffieHellman.Create.OpenSsl.cs
Исходный код:
ECDiffieHellman.Create.OpenSsl.cs

Создает новый экземпляр реализации по умолчанию алгоритма elliptic Curve Diffie-Hellman (ECDH).

public:
 static System::Security::Cryptography::ECDiffieHellman ^ Create();
[System.Runtime.Versioning.UnsupportedOSPlatform("browser")]
public static System.Security.Cryptography.ECDiffieHellman Create();
public static System.Security.Cryptography.ECDiffieHellman Create();
[<System.Runtime.Versioning.UnsupportedOSPlatform("browser")>]
static member Create : unit -> System.Security.Cryptography.ECDiffieHellman
static member Create : unit -> System.Security.Cryptography.ECDiffieHellman
Public Shared Function Create () As ECDiffieHellman

Возвращаемое значение

Новый экземпляр реализации этого класса по умолчанию.

Атрибуты

Применяется к

Create(ECCurve)

Исходный код:
ECDiffieHellman.Create.OpenSsl.cs
Исходный код:
ECDiffieHellman.Create.OpenSsl.cs
Исходный код:
ECDiffieHellman.Create.OpenSsl.cs
Исходный код:
ECDiffieHellman.Create.OpenSsl.cs
Исходный код:
ECDiffieHellman.Create.OpenSsl.cs

Создает новый экземпляр реализации по умолчанию алгоритма elliptic Curve Diffie-Hellman (ECDH) с новой парой открытого и закрытого ключа, созданной по заданной кривой.

public:
 static System::Security::Cryptography::ECDiffieHellman ^ Create(System::Security::Cryptography::ECCurve curve);
[System.Runtime.Versioning.UnsupportedOSPlatform("browser")]
public static System.Security.Cryptography.ECDiffieHellman Create(System.Security.Cryptography.ECCurve curve);
public static System.Security.Cryptography.ECDiffieHellman Create(System.Security.Cryptography.ECCurve curve);
[<System.Runtime.Versioning.UnsupportedOSPlatform("browser")>]
static member Create : System.Security.Cryptography.ECCurve -> System.Security.Cryptography.ECDiffieHellman
static member Create : System.Security.Cryptography.ECCurve -> System.Security.Cryptography.ECDiffieHellman
Public Shared Function Create (curve As ECCurve) As ECDiffieHellman

Параметры

curve
ECCurve

Кривая, используемая для создания новой пары открытых и закрытых ключей.

Возвращаемое значение

Новый экземпляр реализации по умолчанию алгоритма elliptic Curve Diffie-Hellman (ECDH).

Атрибуты

Исключения

curve не проверяется.

Комментарии

кривая должна проверить (то есть возвращает значение true при передаче в ECCurve.Validate метод.

Кривые характеристики-2 не поддерживаются в Windows.

См. также раздел

Применяется к

Create(ECParameters)

Исходный код:
ECDiffieHellman.Create.OpenSsl.cs
Исходный код:
ECDiffieHellman.Create.OpenSsl.cs
Исходный код:
ECDiffieHellman.Create.OpenSsl.cs
Исходный код:
ECDiffieHellman.Create.OpenSsl.cs
Исходный код:
ECDiffieHellman.Create.OpenSsl.cs

Создает новый экземпляр реализации по умолчанию алгоритма elliptic Curve Diffie-Hellman (ECDH) с ключом, описанным указанным ECParameters объектом.

public:
 static System::Security::Cryptography::ECDiffieHellman ^ Create(System::Security::Cryptography::ECParameters parameters);
[System.Runtime.Versioning.UnsupportedOSPlatform("browser")]
public static System.Security.Cryptography.ECDiffieHellman Create(System.Security.Cryptography.ECParameters parameters);
public static System.Security.Cryptography.ECDiffieHellman Create(System.Security.Cryptography.ECParameters parameters);
[<System.Runtime.Versioning.UnsupportedOSPlatform("browser")>]
static member Create : System.Security.Cryptography.ECParameters -> System.Security.Cryptography.ECDiffieHellman
static member Create : System.Security.Cryptography.ECParameters -> System.Security.Cryptography.ECDiffieHellman
Public Shared Function Create (parameters As ECParameters) As ECDiffieHellman

Параметры

parameters
ECParameters

Параметры для алгоритма шифрования с многоточием кривой (ECC).

Возвращаемое значение

Новый экземпляр реализации по умолчанию алгоритма elliptic Curve Diffie-Hellman (ECDH).

Атрибуты

Исключения

parameters не проверяется.

Комментарии

parameters необходимо проверить (т. е. возвращать true) при передаче в ECParameters.Validate метод. Параметры по неявным кривым не поддерживаются.

Кривые характеристики-2 не поддерживаются в Windows.

См. также раздел

Применяется к

Create(String)

Исходный код:
ECDiffieHellman.cs
Исходный код:
ECDiffieHellman.cs
Исходный код:
ECDiffieHellman.cs
Исходный код:
ECDiffieHellman.cs
Исходный код:
ECDiffieHellman.cs

Внимание!

Cryptographic factory methods accepting an algorithm name are obsolete. Use the parameterless Create factory method on the algorithm type instead.

Создает новый экземпляр указанной реализации алгоритма elliptic Curve Diffie-Hellman (ECDH).

public:
 static System::Security::Cryptography::ECDiffieHellman ^ Create(System::String ^ algorithm);
[System.Diagnostics.CodeAnalysis.RequiresUnreferencedCode("The default algorithm implementations might be removed, use strong type references like 'RSA.Create()' instead.")]
[System.Obsolete("Cryptographic factory methods accepting an algorithm name are obsolete. Use the parameterless Create factory method on the algorithm type instead.", DiagnosticId="SYSLIB0045", UrlFormat="https://aka.ms/dotnet-warnings/{0}")]
public static System.Security.Cryptography.ECDiffieHellman? Create(string algorithm);
public static System.Security.Cryptography.ECDiffieHellman? Create(string algorithm);
[System.Diagnostics.CodeAnalysis.RequiresUnreferencedCode("The default algorithm implementations might be removed, use strong type references like 'RSA.Create()' instead.")]
public static System.Security.Cryptography.ECDiffieHellman? Create(string algorithm);
public static System.Security.Cryptography.ECDiffieHellman Create(string algorithm);
[<System.Diagnostics.CodeAnalysis.RequiresUnreferencedCode("The default algorithm implementations might be removed, use strong type references like 'RSA.Create()' instead.")>]
[<System.Obsolete("Cryptographic factory methods accepting an algorithm name are obsolete. Use the parameterless Create factory method on the algorithm type instead.", DiagnosticId="SYSLIB0045", UrlFormat="https://aka.ms/dotnet-warnings/{0}")>]
static member Create : string -> System.Security.Cryptography.ECDiffieHellman
static member Create : string -> System.Security.Cryptography.ECDiffieHellman
[<System.Diagnostics.CodeAnalysis.RequiresUnreferencedCode("The default algorithm implementations might be removed, use strong type references like 'RSA.Create()' instead.")>]
static member Create : string -> System.Security.Cryptography.ECDiffieHellman
Public Shared Function Create (algorithm As String) As ECDiffieHellman

Параметры

algorithm
String

Имя реализации алгоритма ECDH.

Возвращаемое значение

Новый экземпляр указанной реализации этого класса. Если указанное имя алгоритма не сопоставляется с реализацией ECDH, этот метод возвращается null.

Атрибуты

Исключения

Параметр algorithm имеет значение null.

Комментарии

При разработке собственной реализации объекта можно использовать ECDiffieHellman перегрузку метода для создания пользовательской Create(String)algorithm строки, указывающей реализацию.

Параметр algorithm задает имя реализации алгоритма ECDH. Следующие строки ссылаются на одну и ту же реализацию, которая в настоящее время поддерживается в .NET Framework.

  • "ECDH"

  • "ECDiffieHellman"

  • "ECDiffieHellmanCng"

  • "System.Security.Cryptography.ECDiffieHellmanCng"

Можно также указать имя пользовательской реализации ECDH для algorithm параметра. При этом CryptoConfig объект будет использовать его для определения возможности создания объекта ECDH.

Применяется к