HashAlgorithmNames HashAlgorithmNames HashAlgorithmNames HashAlgorithmNames Class

Contains static properties that enable you to retrieve algorithm names that can be used in the OpenAlgorithm(System.String) method of the HashAlgorithmProvider class.

Syntax

Declaration

public static class HashAlgorithmNamespublic static class HashAlgorithmNamesPublic Static Class HashAlgorithmNames

Remarks

All of the properties associated with this class are static. You do not need to create an instance of the class to retrieve a property value.

Properties summary

Retrieves a string that contains "MD5".

Retrieves a string that contains "SHA1".

Retrieves a string that contains "SHA256".

Retrieves a string that contains "SHA384".

Retrieves a string that contains "SHA512".

Properties

  • Md5
    Md5
    Md5
    Md5

    Retrieves a string that contains "MD5".

    public static string Md5 { get; }public static string Md5 { get; }Public Static ReadOnly Property Md5 As string

    Property Value

    • string
      string
      string
      string

      String that contains "MD5".

    Remarks

    Use the string retrieved by this property to set the hash algorithm name when you call the OpenAlgorithm(System.String) method. The string represents an MD5 message digest algorithm. The algorithm produces a 128-bit hash value.

  • Sha1
    Sha1
    Sha1
    Sha1

    Retrieves a string that contains "SHA1".

    public static string Sha1 { get; }public static string Sha1 { get; }Public Static ReadOnly Property Sha1 As string

    Property Value

    • string
      string
      string
      string

      String that contains "SHA1".

    Remarks

    Use the string retrieved by this property to set the hash algorithm name when you call the OpenAlgorithm(System.String) method. The string represents a SHA1 (Secure Hash Algorithm 1) message digest algorithm. The algorithm produces a 160-bit hash value.

  • Sha256
    Sha256
    Sha256
    Sha256

    Retrieves a string that contains "SHA256".

    public static string Sha256 { get; }public static string Sha256 { get; }Public Static ReadOnly Property Sha256 As string

    Property Value

    • string
      string
      string
      string

      String that contains "SHA256".

    Remarks

    Use the string retrieved by this property to set the hash algorithm name when you call the OpenAlgorithm(System.String) method. The string represents a SHA2 (Secure Hash Algorithm 2) message digest algorithm that produces a 256-bit hash value.

  • Sha384
    Sha384
    Sha384
    Sha384

    Retrieves a string that contains "SHA384".

    public static string Sha384 { get; }public static string Sha384 { get; }Public Static ReadOnly Property Sha384 As string

    Property Value

    • string
      string
      string
      string

      String that contains "SHA384".

    Remarks

    Use the string retrieved by this property to set the hash algorithm name when you call the OpenAlgorithm(System.String) method. The string represents a SHA2 (Secure Hash Algorithm 2) message digest algorithm that produces a 384-bit hash value.

  • Sha512
    Sha512
    Sha512
    Sha512

    Retrieves a string that contains "SHA512".

    public static string Sha512 { get; }public static string Sha512 { get; }Public Static ReadOnly Property Sha512 As string

    Property Value

    • string
      string
      string
      string

      String that contains "SHA512".

    Remarks

    Use the string retrieved by this property to set the hash algorithm name when you call the OpenAlgorithm(System.String) method. The string represents a SHA2 (Secure Hash Algorithm 2) message digest algorithm that produces a 512-bit hash value.

Device family

Windows 10 (introduced v10.0.10240.0)

API contract

Windows.Foundation.UniversalApiContract (introduced v1)

Attributes

Windows.Foundation.Metadata.DualApiPartitionAttribute
Windows.Foundation.Metadata.MarshalingBehaviorAttribute
Windows.Foundation.Metadata.ContractVersionAttribute
Windows.Foundation.Metadata.StaticAttribute

Details

Assembly

Windows.Security.Cryptography.Core.dll