0
你好,我是在寻找适用于Windows 8(Metro应用)Windows 8的VB MD5哈希
我在谷歌一直在寻找这样一个MD5哈希函数(和其他搜索引擎),但并没有什么针对Windows 8,其中大部分是关于胜7(或以上)
谢谢任何方式:)
你好,我是在寻找适用于Windows 8(Metro应用)Windows 8的VB MD5哈希
我在谷歌一直在寻找这样一个MD5哈希函数(和其他搜索引擎),但并没有什么针对Windows 8,其中大部分是关于胜7(或以上)
谢谢任何方式:)
我没有找到MD5但我觉得对于SHA256这里是如果你有兴趣在一些样本;)
Function sha512(Key As String)
Dim hash As String
Dim strAlgName As String = "SHA512"
Dim objAlgProv As HashAlgorithmProvider = HashAlgorithmProvider.OpenAlgorithm(strAlgName)
Dim objHash As CryptographicHash = objAlgProv.CreateHash()
Dim buffMsg1 As IBuffer = CryptographicBuffer.ConvertStringToBinary(Key, BinaryStringEncoding.Utf16BE)
objHash.Append(buffMsg1)
Dim buffHash1 As IBuffer = objHash.GetValueAndReset()
Dim strHash1 As String = CryptographicBuffer.EncodeToBase64String(buffHash1)
hash = strHash1
Return hash
End Function
可能有[Comput在C#中Metro风格的应用程序的MD5](http://stackoverflow.com/questions/8297627/compute-md5-on-metro-style-app-in-c-sharp) - 这应该适用于VB.NET作为好,除了小的语法差异之外。 – Joey
但它甚至没有回答! 我现在可以在Windows 8上找到任何类型的哈希值! “Windows.Security.Cryptography.Certificates”没有散列属性:S –
如果为了安全起见,请注意MD5不是非常安全。 – jmoreno