The following statement throws exception:
byte[] toEncryptArray = Convert.FromBase64String(cipherString);
The cipher string is "62KO b2aMA8=" and it is 12 characters long (a multiple of 4).
This string has been created using following routine (adapted from
http://www.codeproject.com/Articles/14150/Encrypt-and-Decrypt-Data-with-C):
public static string Encrypt(string toEncrypt, bool useHashing)
{
byte[] keyArray;
byte[] toEncryptArray = UTF8Encoding.UTF8.GetBytes(toEncrypt);
if (useHashing)
{
MD5CryptoServiceProvider hashmd5 = new MD5CryptoServiceProvider();
keyArray = hashmd5.ComputeHash(UTF8Encoding.UTF8.GetBytes(key));
hashmd5.Clear();
...
Go to the complete details ...