Share via


KeyedHashAlgorithm.Create Yöntem

Tanım

Anahtarlı karma algoritması uygulamasının bir örneğini oluşturur.

Aşırı Yüklemeler

Create()
Geçersiz.
Geçersiz.

Anahtarlı karma algoritmasının varsayılan uygulamasının bir örneğini oluşturur.

Create(String)
Geçersiz.

Anahtarlı karma algoritmasının belirtilen uygulamasının bir örneğini oluşturur.

Create()

Kaynak:
KeyedHashAlgorithm.cs
Kaynak:
KeyedHashAlgorithm.cs
Kaynak:
KeyedHashAlgorithm.cs

Dikkat

The default implementation of this cryptography algorithm is not supported

Dikkat

The default implementation of this cryptography algorithm is not supported.

Anahtarlı karma algoritmasının varsayılan uygulamasının bir örneğini oluşturur.

public:
 static System::Security::Cryptography::KeyedHashAlgorithm ^ Create();
[System.Obsolete("The default implementation of this cryptography algorithm is not supported", DiagnosticId="SYSLIB0007", UrlFormat="https://aka.ms/dotnet-warnings/{0}")]
public static System.Security.Cryptography.KeyedHashAlgorithm Create ();
[System.Obsolete("The default implementation of this cryptography algorithm is not supported.", DiagnosticId="SYSLIB0007", UrlFormat="https://aka.ms/dotnet-warnings/{0}")]
public static System.Security.Cryptography.KeyedHashAlgorithm Create ();
public static System.Security.Cryptography.KeyedHashAlgorithm Create ();
[<System.Obsolete("The default implementation of this cryptography algorithm is not supported", DiagnosticId="SYSLIB0007", UrlFormat="https://aka.ms/dotnet-warnings/{0}")>]
static member Create : unit -> System.Security.Cryptography.KeyedHashAlgorithm
[<System.Obsolete("The default implementation of this cryptography algorithm is not supported.", DiagnosticId="SYSLIB0007", UrlFormat="https://aka.ms/dotnet-warnings/{0}")>]
static member Create : unit -> System.Security.Cryptography.KeyedHashAlgorithm
static member Create : unit -> System.Security.Cryptography.KeyedHashAlgorithm
Public Shared Function Create () As KeyedHashAlgorithm

Döndürülenler

Varsayılan ayarlar değiştirilmediği sürece yeni HMACSHA1 bir örnek.

Öznitelikler

Açıklamalar

Varsayılan olarak, bu aşırı yükleme anahtarlı karma algoritmasının uygulamasını kullanır HMACSHA1 . Farklı bir uygulama belirtmek istiyorsanız, bunun yerine bir algoritma adı belirtmenize olanak tanıyan aşırı yüklemesini kullanın Create(String) . Şifreleme yapılandırma sistemi, sınıfının varsayılan uygulamasını KeyedHashAlgorithm tanımlar.

SHA1 ile ilgili çakışma sorunları nedeniyle Microsoft, SHA256 veya üzerini temel alan bir güvenlik modeli önerir.

Ayrıca bkz.

Şunlara uygulanır

Create(String)

Kaynak:
KeyedHashAlgorithm.cs
Kaynak:
KeyedHashAlgorithm.cs
Kaynak:
KeyedHashAlgorithm.cs

Dikkat

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

Anahtarlı karma algoritmasının belirtilen uygulamasının bir örneğini oluşturur.

public:
 static System::Security::Cryptography::KeyedHashAlgorithm ^ Create(System::String ^ algName);
public static System.Security.Cryptography.KeyedHashAlgorithm? Create (string algName);
[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.KeyedHashAlgorithm? Create (string algName);
public static System.Security.Cryptography.KeyedHashAlgorithm Create (string algName);
static member Create : string -> System.Security.Cryptography.KeyedHashAlgorithm
[<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.KeyedHashAlgorithm
Public Shared Function Create (algName As String) As KeyedHashAlgorithm

Parametreler

algName
String

Kullanılacak anahtarlı karma algoritması uygulaması. Aşağıdaki tabloda parametre için algName geçerli değerler ve eşledikleri algoritmalar gösterilmektedir.

Parametre değeri Uygulamalar
System.Security.Cryptography.HMACHMACSHA1
System.Security.Cryptography.KeyedHashAlgorithmHMACSHA1
HMACMD5HMACMD5
System.Security.Cryptography.HMACMD5HMACMD5
HMACRIPEMD160HMACRIPEMD160
System.Security.Cryptography.HMACRIPEMD160HMACRIPEMD160
HMACSHA1HMACSHA1
System.Security.Cryptography.HMACSHA1HMACSHA1
HMACSHA256HMACSHA256
System.Security.Cryptography.HMACSHA256HMACSHA256
HMACSHA384HMACSHA384
System.Security.Cryptography.HMACSHA384HMACSHA384
HMACSHA512HMACSHA512
System.Security.Cryptography.HMACSHA512HMACSHA512
MactripledesMACTripleDES
System.Security.Cryptography.MACTripleDESMACTripleDES

Döndürülenler

Belirtilen anahtarlı karma algoritmasının yeni bir örneği.

Öznitelikler

Özel durumlar

.NET Core 2.0 - 3.1 ve .NET 5 ve üzeri: Her durumda.

Açıklamalar

Bu yöntem .NET 5 ve sonraki sürümlerde eskidir.

Bu yöntem MD5, SHA-1, SHA-256 ve RIPEMD160 gibi bir dizi algoritmayı destekler. Tam liste için parametresi için desteklenen değerlere algName bakın.

Ayrıca bkz.

Şunlara uygulanır