C# Класс Utilities.Cryptography.ExtensionMethods.HashExtensions

Hash based extensions
Показать файл Открыть проект

Открытые методы

Метод Описание
Hash ( this data, HashAlgorithm algorithm = null ) : byte[]

Computes the hash of a byte array

Hash ( this data, HashAlgorithm algorithm = null, Encoding encodingUsing = null ) : string

Computes the hash of a string

Приватные методы

Метод Описание
ToByteArray ( this input, Encoding encodingUsing = null ) : byte[]

Описание методов

Hash() публичный статический Метод

Computes the hash of a byte array
public static Hash ( this data, HashAlgorithm algorithm = null ) : byte[]
data this Byte array to hash
algorithm System.Security.Cryptography.HashAlgorithm Hash algorithm to use (defaults to SHA256)
Результат byte[]

Hash() публичный статический Метод

Computes the hash of a string
public static Hash ( this data, HashAlgorithm algorithm = null, Encoding encodingUsing = null ) : string
data this string to hash
algorithm System.Security.Cryptography.HashAlgorithm Algorithm to use (defaults to SHA256)
encodingUsing System.Text.Encoding Encoding used by the string (defaults to UTF8)
Результат string