DSACng Konstruktory

Definice

Inicializuje novou instanci DSACng třídy.

Přetížení

Name Description
DSACng()

Inicializuje novou instanci DSACng třídy s náhodným 2 048bitovým párem klíčů.

DSACng(Int32)

Inicializuje novou instanci DSACng třídy s náhodně vygenerovaným klíčem zadané velikosti.

DSACng(CngKey)

Inicializuje novou instanci DSACng třídy se zadaným klíčem.

DSACng()

Zdroj:
Cng.NotSupported.cs
Zdroj:
Cng.NotSupported.cs
Zdroj:
Cng.NotSupported.cs
Zdroj:
Cng.NotSupported.cs
Zdroj:
Cng.NotSupported.cs

Inicializuje novou instanci DSACng třídy s náhodným 2 048bitovým párem klíčů.

public:
 DSACng();
[System.Runtime.Versioning.SupportedOSPlatform("windows")]
public DSACng();
public DSACng();
Public Sub New ()
Atributy

Platí pro

DSACng(Int32)

Zdroj:
Cng.NotSupported.cs
Zdroj:
Cng.NotSupported.cs
Zdroj:
Cng.NotSupported.cs
Zdroj:
Cng.NotSupported.cs
Zdroj:
Cng.NotSupported.cs

Inicializuje novou instanci DSACng třídy s náhodně vygenerovaným klíčem zadané velikosti.

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

Parametry

keySize
Int32

Velikost klíče, který se má vygenerovat v bitech.

Atributy

Výjimky

keySize není platný.

Poznámky

Platné velikosti klíčů jsou v rozsahu od 512 do 3 072 bitů v přírůstcích po 64. Pro všechny klíče doporučujeme použít minimální velikost 2 048 bitů.

Important

Tvůrci algoritmu DSA stáhli podporu pro něj. Zvažte použití RSA třídy nebo ECDsa třídy místo DSA třídy. Používejte DSA pouze kvůli kompatibilitě se staršími aplikacemi a daty.

Platí pro

DSACng(CngKey)

Zdroj:
Cng.NotSupported.cs
Zdroj:
Cng.NotSupported.cs
Zdroj:
Cng.NotSupported.cs
Zdroj:
Cng.NotSupported.cs
Zdroj:
Cng.NotSupported.cs

Inicializuje novou instanci DSACng třídy se zadaným klíčem.

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

Parametry

key
CngKey

Klíč, který se má použít pro operace DSA.

Atributy

Výjimky

key není platný klíč DSA.

key je null.

Poznámky

Musí CngKey.AlgorithmGroup být key.CngAlgorithmGroup.Dsa

Tento konstruktor vytvoří kopii klíče. I když key je odstraněn, kopie tohoto objektu klíče v DSA zůstane naživu.

Platí pro