Posted on: 10/27/2014 10:30:59 PM | Views : 523

Hello
I am trying to come to terms with salting and hashing and have come across an interesting article, albeit outdated, by a senior manager at Microsoft, who suggests using a one-way hashing algorithm and storing the hashing in a database table (in my case, Access). So,
Imports System.Security.Principal ... Dim user As WindowsIdentity = WindowsIdentity.GetCurrent() Dim username As String = user.Name If CType(Me.LoginTableAdapter1.GetLoginByUserName(username), Integer) = 1 Then MsgBox("Welcome to my application!") Else MsgBox("Invalid Username or Password.") End If SELECT COUNT(*) FROM myTable WHERE username = @username and then:
Imports System.Security.Cryptography Imports System.Text ... Function HashEncryptString(ByVal s As String) As String Dim hasher As New SHA1CryptoServiceProvider() Dim clearBytes As Byte() = Enco ...

Go to the complete details ...