Share via


ECDiffieHellman.DeriveKeyFromHash Yöntem

Tanım

Belirtilen karma algoritmayı kullanarak anahtar türetmesi gerçekleştirir.

Aşırı Yüklemeler

DeriveKeyFromHash(ECDiffieHellmanPublicKey, HashAlgorithmName)

Belirtilen karma algoritmayı kullanarak anahtar türetmesi gerçekleştirir.

DeriveKeyFromHash(ECDiffieHellmanPublicKey, HashAlgorithmName, Byte[], Byte[])

Türetilmiş bir sınıfta uygulandığında, isteğe bağlı önceden eklenmiş veya eklenmiş verilerle belirtilen karma algoritmayı kullanarak anahtar türetmesi gerçekleştirir.

DeriveKeyFromHash(ECDiffieHellmanPublicKey, HashAlgorithmName)

Kaynak:
ECDiffieHellman.cs
Kaynak:
ECDiffieHellman.cs
Kaynak:
ECDiffieHellman.cs

Belirtilen karma algoritmayı kullanarak anahtar türetmesi gerçekleştirir.

public:
 cli::array <System::Byte> ^ DeriveKeyFromHash(System::Security::Cryptography::ECDiffieHellmanPublicKey ^ otherPartyPublicKey, System::Security::Cryptography::HashAlgorithmName hashAlgorithm);
public byte[] DeriveKeyFromHash (System.Security.Cryptography.ECDiffieHellmanPublicKey otherPartyPublicKey, System.Security.Cryptography.HashAlgorithmName hashAlgorithm);
member this.DeriveKeyFromHash : System.Security.Cryptography.ECDiffieHellmanPublicKey * System.Security.Cryptography.HashAlgorithmName -> byte[]
Public Function DeriveKeyFromHash (otherPartyPublicKey As ECDiffieHellmanPublicKey, hashAlgorithm As HashAlgorithmName) As Byte()

Parametreler

otherPartyPublicKey
ECDiffieHellmanPublicKey

Diğer tarafın ortak anahtarı.

hashAlgorithm
HashAlgorithmName

Anahtar malzemeyi türetmek için kullanılacak karma algoritması.

Döndürülenler

Byte[]

Paylaşılan gizli dizinin karması.

Özel durumlar

tarafından otherPartyPublicKey kullanılan eğri, bu anahtardaki eğriden farklı bir boyuta sahiptir.

-veya-

hashAlgorithm parametresi bir karma belirtmez.

otherPartyPublicKey, null değeridir.

tarafından otherPartyPublicKey kullanılan eğri, bu anahtardan farklı bir eğridir.

-veya-

Bu örnek yalnızca bir ortak anahtarı temsil eder.

Açıklamalar

Bu aşırı yükleme, ön ekli ve ekleme değerleri olarak geçen null yöntemini çağırırDeriveKeyFromHash.

Şunlara uygulanır

DeriveKeyFromHash(ECDiffieHellmanPublicKey, HashAlgorithmName, Byte[], Byte[])

Kaynak:
ECDiffieHellman.cs
Kaynak:
ECDiffieHellman.cs
Kaynak:
ECDiffieHellman.cs

Türetilmiş bir sınıfta uygulandığında, isteğe bağlı önceden eklenmiş veya eklenmiş verilerle belirtilen karma algoritmayı kullanarak anahtar türetmesi gerçekleştirir.

public:
 virtual cli::array <System::Byte> ^ DeriveKeyFromHash(System::Security::Cryptography::ECDiffieHellmanPublicKey ^ otherPartyPublicKey, System::Security::Cryptography::HashAlgorithmName hashAlgorithm, cli::array <System::Byte> ^ secretPrepend, cli::array <System::Byte> ^ secretAppend);
public virtual byte[] DeriveKeyFromHash (System.Security.Cryptography.ECDiffieHellmanPublicKey otherPartyPublicKey, System.Security.Cryptography.HashAlgorithmName hashAlgorithm, byte[]? secretPrepend, byte[]? secretAppend);
public virtual byte[] DeriveKeyFromHash (System.Security.Cryptography.ECDiffieHellmanPublicKey otherPartyPublicKey, System.Security.Cryptography.HashAlgorithmName hashAlgorithm, byte[] secretPrepend, byte[] secretAppend);
abstract member DeriveKeyFromHash : System.Security.Cryptography.ECDiffieHellmanPublicKey * System.Security.Cryptography.HashAlgorithmName * byte[] * byte[] -> byte[]
override this.DeriveKeyFromHash : System.Security.Cryptography.ECDiffieHellmanPublicKey * System.Security.Cryptography.HashAlgorithmName * byte[] * byte[] -> byte[]
Public Overridable Function DeriveKeyFromHash (otherPartyPublicKey As ECDiffieHellmanPublicKey, hashAlgorithm As HashAlgorithmName, secretPrepend As Byte(), secretAppend As Byte()) As Byte()

Parametreler

otherPartyPublicKey
ECDiffieHellmanPublicKey

Diğer tarafın ortak anahtarı.

hashAlgorithm
HashAlgorithmName

Anahtar malzemeyi türetmek için kullanılacak karma algoritması.

secretPrepend
Byte[]

Karma oluşturmadan önce türetilmiş gizli diziye eklenmek için bir değer.

secretAppend
Byte[]

Karma oluşturmadan önce türetilmiş gizli diziye eklenecek değer.

Döndürülenler

Byte[]

Verileri istendiği gibi önceden ekledikten veya ekledikten sonra paylaşılan gizli dizinin karması.

Özel durumlar

Türetilmiş bir sınıf bu yöntemi geçersiz kılmalıdır.

tarafından otherPartyPublicKey kullanılan eğri, bu anahtardaki eğriden farklı bir boyuta sahiptir.

-veya-

hashAlgorithm parametresi bir karma belirtmez.

otherPartyPublicKey, null değeridir.

tarafından otherPartyPublicKey kullanılan eğri, bu anahtardan farklı bir eğridir.

-veya-

Bu örnek yalnızca bir ortak anahtarı temsil eder.

Açıklamalar

Bu yöntem, paylaşılan gizli diziyi (z ) oluşturmak için Eliptik Eğri Diffie-Hellman anahtar sözleşmesini dahili olarak gerçekleştirir. Bu yöntemden döndürülen değer, birleştirmeyi işaret eden || belirtilen karma algoritmasını kullanmanın sonucudurHASH(secretPrepend || z || secretAppend).

veya secretAppend değeri secretPrepend isenull, bunlar boş diziler olarak değerlendirilir.

Şunlara uygulanır