SHA256.Create Metodo

Definizione

Consente di creare un'istanza di implementazioni specifiche di questa classe astratta.

Overload

Nome Descrizione
Create()

Crea un'istanza dell'implementazione predefinita di SHA256.

Create(String)
Obsoleti.

Crea un'istanza di un'implementazione specificata di SHA256.

Create()

Origine:
SHA256.cs
Origine:
SHA256.cs
Origine:
SHA256.cs
Origine:
SHA256.cs
Origine:
SHA256.cs

Crea un'istanza dell'implementazione predefinita di SHA256.

public:
 static System::Security::Cryptography::SHA256 ^ Create();
public static System.Security.Cryptography.SHA256 Create();
static member Create : unit -> System.Security.Cryptography.SHA256
Public Shared Function Create () As SHA256

Valori restituiti

Nuova istanza di SHA256. In .NET Framework questo metodo crea un'istanza della classe se la modalità FIPS non è attiva. Se la modalità FIPS è attiva, crea un'istanza della classe /> SHA256.

Eccezioni

Solo in .NET Framework 4.6.1 e versioni precedenti: l'algoritmo è stato usato con la modalità FIPS (Federal Information Processing Standards), ma non è compatibile con FIPS.

Vedi anche

Si applica a

Create(String)

Origine:
SHA256.cs
Origine:
SHA256.cs
Origine:
SHA256.cs
Origine:
SHA256.cs
Origine:
SHA256.cs

Attenzione

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

Crea un'istanza di un'implementazione specificata di SHA256.

public:
 static System::Security::Cryptography::SHA256 ^ Create(System::String ^ hashName);
[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.SHA256? Create(string hashName);
public static System.Security.Cryptography.SHA256? Create(string hashName);
[System.Diagnostics.CodeAnalysis.RequiresUnreferencedCode("The default algorithm implementations might be removed, use strong type references like 'RSA.Create()' instead.")]
public static System.Security.Cryptography.SHA256? Create(string hashName);
public static System.Security.Cryptography.SHA256 Create(string hashName);
[<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.SHA256
static member Create : string -> System.Security.Cryptography.SHA256
[<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.SHA256
Public Shared Function Create (hashName As String) As SHA256

Parametri

hashName
String

Nome dell'implementazione specifica di SHA256 da utilizzare.

Valori restituiti

Nuova istanza di SHA256 utilizzando l'implementazione specificata.

Attributi

Eccezioni

Solo in .NET Framework: la modalità FIPS è abilitata, ma hashName richieste SHA256Managed, che non è compatibile con FIPS.

Commenti

Il framework .NET include le implementazioni e i relativi valori hashName associati:

Implementation Hashname
SHA256Managed SHA256
SHA-256
System.Security.Cryptography.SHA256
SHA256Cng System.Security.Cryptography.SHA256Cng
SHA256CryptoServiceProvider System.Security.Cryptography.SHA256CryptoServiceProvider

Vedi anche

Si applica a