Terraria v1.4.4.9
Terraria source code documentation
Loading...
Searching...
No Matches

◆ GetHashAlgorithmId() [2/2]

static global.Interop.BCrypt.ECC_CURVE_ALG_ID_ENUM System.Security.Cryptography.ECCng.GetHashAlgorithmId ( HashAlgorithmName? name)
inlinestaticpackage

Definition at line 419 of file ECCng.cs.

420 {
421 if (!name.HasValue || string.IsNullOrEmpty(name.Value.Name))
422 {
423 return global::Interop.BCrypt.ECC_CURVE_ALG_ID_ENUM.BCRYPT_NO_CURVE_GENERATION_ALG_ID;
424 }
425 global::Interop.Crypt32.CRYPT_OID_INFO cRYPT_OID_INFO = global::Interop.Crypt32.FindOidInfo(global::Interop.Crypt32.CryptOidInfoKeyType.CRYPT_OID_INFO_NAME_KEY, name.Value.Name, OidGroup.HashAlgorithm, fallBackToAllGroups: false);
426 if (cRYPT_OID_INFO.AlgId == -1)
427 {
428 throw new CryptographicException(System.SR.Cryptography_UnknownHashAlgorithm, name.Value.Name);
429 }
430 return (global::Interop.BCrypt.ECC_CURVE_ALG_ID_ENUM)cRYPT_OID_INFO.AlgId;
431 }
static string Cryptography_UnknownHashAlgorithm
Definition SR.cs:152
Definition SR.cs:7

References System.SR.Cryptography_UnknownHashAlgorithm.