ECDiffieHellmanCng 构造函数

定义

初始化 ECDiffieHellmanCng 类的新实例。

重载

名称 说明
ECDiffieHellmanCng()

使用随机密钥对初始化类的新实例 ECDiffieHellmanCng

ECDiffieHellmanCng(Int32)

使用指定的密钥大小使用随机键对初始化类的新实例 ECDiffieHellmanCng

ECDiffieHellmanCng(CngKey)

使用指定的ECDiffieHellmanCng对象初始化类的新实例CngKey

ECDiffieHellmanCng(ECCurve)

创建类的新实例,该类的 ECDiffieHellmanCng 公钥/私钥对在指定的曲线上生成。

ECDiffieHellmanCng()

Source:
Cng.NotSupported.cs
Source:
Cng.NotSupported.cs
Source:
Cng.NotSupported.cs
Source:
Cng.NotSupported.cs
Source:
Cng.NotSupported.cs

使用随机密钥对初始化类的新实例 ECDiffieHellmanCng

public:
 ECDiffieHellmanCng();
[System.Runtime.Versioning.SupportedOSPlatform("windows")]
public ECDiffieHellmanCng();
public ECDiffieHellmanCng();
Public Sub New ()
属性

注解

随机密钥对的默认公钥长度为 521 位。

适用于

ECDiffieHellmanCng(Int32)

Source:
Cng.NotSupported.cs
Source:
Cng.NotSupported.cs
Source:
Cng.NotSupported.cs
Source:
Cng.NotSupported.cs
Source:
Cng.NotSupported.cs

使用指定的密钥大小使用随机键对初始化类的新实例 ECDiffieHellmanCng

public:
 ECDiffieHellmanCng(int keySize);
[System.Runtime.Versioning.SupportedOSPlatform("windows")]
public ECDiffieHellmanCng(int keySize);
public ECDiffieHellmanCng(int keySize);
[System.Security.SecurityCritical]
public ECDiffieHellmanCng(int keySize);
[<System.Runtime.Versioning.SupportedOSPlatform("windows")>]
new System.Security.Cryptography.ECDiffieHellmanCng : int -> System.Security.Cryptography.ECDiffieHellmanCng
new System.Security.Cryptography.ECDiffieHellmanCng : int -> System.Security.Cryptography.ECDiffieHellmanCng
[<System.Security.SecurityCritical>]
new System.Security.Cryptography.ECDiffieHellmanCng : int -> System.Security.Cryptography.ECDiffieHellmanCng
Public Sub New (keySize As Integer)

参数

keySize
Int32

键的大小。 有效的密钥大小为 256、384 和 521 位。

属性

例外

keySize 指定无效长度。

此系统上不支持下一代加密(CNG)类。

注解

随机密钥对将具有参数定义的 keySize 公钥长度。

适用于

ECDiffieHellmanCng(CngKey)

Source:
Cng.NotSupported.cs
Source:
Cng.NotSupported.cs
Source:
Cng.NotSupported.cs
Source:
Cng.NotSupported.cs
Source:
Cng.NotSupported.cs

使用指定的ECDiffieHellmanCng对象初始化类的新实例CngKey

public:
 ECDiffieHellmanCng(System::Security::Cryptography::CngKey ^ key);
[System.Runtime.Versioning.SupportedOSPlatform("windows")]
public ECDiffieHellmanCng(System.Security.Cryptography.CngKey key);
public ECDiffieHellmanCng(System.Security.Cryptography.CngKey key);
[System.Security.SecurityCritical]
public ECDiffieHellmanCng(System.Security.Cryptography.CngKey key);
[<System.Runtime.Versioning.SupportedOSPlatform("windows")>]
new System.Security.Cryptography.ECDiffieHellmanCng : System.Security.Cryptography.CngKey -> System.Security.Cryptography.ECDiffieHellmanCng
new System.Security.Cryptography.ECDiffieHellmanCng : System.Security.Cryptography.CngKey -> System.Security.Cryptography.ECDiffieHellmanCng
[<System.Security.SecurityCritical>]
new System.Security.Cryptography.ECDiffieHellmanCng : System.Security.Cryptography.CngKey -> System.Security.Cryptography.ECDiffieHellmanCng
Public Sub New (key As CngKey)

参数

key
CngKey

将用作当前对象执行的加密操作的输入的密钥。

属性

例外

keynull

key 不指定椭圆曲线 Diffie-Hellman(ECDH)算法组。

此系统上不支持下一代加密(CNG)类。

适用于

ECDiffieHellmanCng(ECCurve)

Source:
Cng.NotSupported.cs
Source:
Cng.NotSupported.cs
Source:
Cng.NotSupported.cs
Source:
Cng.NotSupported.cs
Source:
Cng.NotSupported.cs

创建类的新实例,该类的 ECDiffieHellmanCng 公钥/私钥对在指定的曲线上生成。

public:
 ECDiffieHellmanCng(System::Security::Cryptography::ECCurve curve);
[System.Runtime.Versioning.SupportedOSPlatform("windows")]
public ECDiffieHellmanCng(System.Security.Cryptography.ECCurve curve);
public ECDiffieHellmanCng(System.Security.Cryptography.ECCurve curve);
[<System.Runtime.Versioning.SupportedOSPlatform("windows")>]
new System.Security.Cryptography.ECDiffieHellmanCng : System.Security.Cryptography.ECCurve -> System.Security.Cryptography.ECDiffieHellmanCng
new System.Security.Cryptography.ECDiffieHellmanCng : System.Security.Cryptography.ECCurve -> System.Security.Cryptography.ECDiffieHellmanCng
Public Sub New (curve As ECCurve)

参数

curve
ECCurve

用于生成公钥/私钥对的曲线。

属性

例外

curve 不验证。

注解

curve 必须验证(即,它必须返回 true)传递给 ECCurve.Validate 方法,并且必须是命名或显式质素。

适用于