My first suggestion is that you one way hash the passwords so that they can never be decrypted. Then when a user types in a password you hash it the exact same way and compare it to the stored hash. Here is a function I use to hash passwords.
Public Function HashString(ByVal instrString As String) As String
Dim Ue As New System.Text.UnicodeEncoding()
Dim ByteSourceText() As Byte = Ue.GetBytes(Trim(instrString))
Dim SHA2 As New System.Security.Cryptography.SHA384Managed
Dim ByteHash() As Byte = SHA2.ComputeHash(ByteSourceText)
Dim strSha2 As String = Convert.ToBase64String(ByteHash)
Return Convert.ToBase64String(ByteHash)
End Function
You can find a lot more information in the
CP Articles.[
^] You may want to research salting a hash. And
this article[
^] seemed to really define the different types of cryptography.
Hope this helps.