AssemblyHashAlgorithm 枚举


指定用于哈希文件和用于生成强名称的所有哈希算法。Specifies all the hash algorithms used for hashing files and for generating the strong name.

public enum class AssemblyHashAlgorithm
public enum AssemblyHashAlgorithm
public enum AssemblyHashAlgorithm
public enum AssemblyHashAlgorithm
type AssemblyHashAlgorithm = 
Public Enum AssemblyHashAlgorithm


MD5 32771

检索 MD5 消息摘要算法。Retrieves the MD5 message-digest algorithm. MD5 是 Rivest 在 1991 年开发的。MD5 was developed by Rivest in 1991. 它与 MD4 基本相同,只是增加了安全性。它虽然比 MD4 稍慢一些,但更安全。It is basically MD4 with safety-belts and while it is slightly slower than MD4, it helps provide more security. 该算法包括四个不同的步骤,其设计与 MD4 的略有不同。The algorithm consists of four distinct rounds, which has a slightly different design from that of MD4. 消息摘要的大小以及填充要求保持不变。Message-digest size, as well as padding requirements, remain the same.

None 0

一个掩码,它指示无哈希算法。A mask indicating that there is no hash algorithm. 如果为多模块程序集指定 None,则公共语言运行时默认采用 SHA1 算法,因为多模块程序集需要生成哈希。If you specify None for a multi-module assembly, the common language runtime defaults to the SHA1 algorithm, since multi-module assemblies need to generate a hash. 由于与 SHA1 冲突,Microsoft 建议使用 SHA256。Due to collision problems with SHA1, Microsoft recommends SHA256.

SHA1 32772

用于检索“安全哈希算法”修订版的掩码,该修订版更正了 SHA 中的一个未发布的错误。A mask used to retrieve a revision of the Secure Hash Algorithm that corrects an unpublished flaw in SHA.

SHA256 32780

用于检索“安全哈希算法”的版本的掩码,其哈希值大小为 256 位。A mask used to retrieve a version of the Secure Hash Algorithm with a hash size of 256 bits.

SHA384 32781

用于检索“安全哈希算法”的版本的掩码,其哈希值大小为 384 位。A mask used to retrieve a version of the Secure Hash Algorithm with a hash size of 384 bits.

SHA512 32782

用于检索“安全哈希算法”的版本的掩码,其哈希值大小为 512 位。A mask used to retrieve a version of the Secure Hash Algorithm with a hash size of 512 bits.


hash function``H 是一种转换,它采用输入 m 并返回固定大小的字符串,该字符串称为哈希值 h (即 h = Hm))。A hash function``H is a transformation that takes an input m and returns a fixed-size string, which is called the hash value h (that is, h = H (m)). 仅具有此属性的哈希函数具有各种一般计算用途,但在加密时,通常会选择使用哈希函数作为一些附加属性。Hash functions with just this property have a variety of general computational uses, but when employed in cryptography, the hash functions are usually chosen to have some additional properties.

加密哈希函数的基本要求如下:The basic requirements for a cryptographic hash function are:

  • 输入可以为任意长度。The input can be of any length.

  • 输出具有固定长度。The output has a fixed length.

  • Hx) 对于任何给定的 x 相对容易。H (x) is relatively easy to compute for any given x.

  • Hx)是单向的。H (x) is one-way.

  • Hx)无冲突。H (x) is collision-free.

哈希值表示从其计算所得的较长消息或文档此值称为 "消息摘要"。The hash value represents concisely the longer message or document from which it was computed; this value is called the message digest. 可以将消息摘要视为大文档的数字指纹。You can think of a message digest as a digital fingerprint of the larger document. 众所周知的哈希函数的示例包括 MD2 和 SHA。Examples of well-known hash functions are MD2 and SHA.