Hi
I want Encrypt-and-Decrypt-Username-or-Password so I used below link
http://aspsnippets.com/Articles/Encrypt-and-Decrypt-Username-or-Password-stored-in-database-in-ASPNet-using-C-and-VBNet.aspx
and download code but when I want run it below error happen
Server Error in '/Encrypt_Decrypt_Database' Application.
The input data is not a complete block.
Description: An unhandled exception occurred during the execution of the current web request. Please review the stack trace for more information about the error and where it originated in the code.
Exception Details: System.Security.Cryptography.CryptographicException: The input data is not a complete block.
Source Error:
Line 103: cs.Write(cipherBytes, 0, cipherBytes.Length);
Line 104: cs.Close();
Line 105: } Line 106: cipherText = Encoding.Unicode.GetString(ms.ToArray());
Line 107: }
|
Source File: c:\Users\NedMag\Desktop\Encrypt_Decrypt_Database\CS.aspx.cs Line: 105
can you help me?
Best regards
Neda