// Perform the conversion of the encryption key from unicode to ansi byte[] asciiBytes = Encoding.Convert(unicode,ascii,unicode.GetBytes(this.m_sEncryptionKey));I don't understand why you still see this over and over and over in .NET applications. Using a DOS compatible ASCII codepage in a Windows application and in claim to use ANSI in the comment. ASCII != ANSI, please....
var x = new Byte[256]; for(var i=0; i<256; i++) x[i] = (Byte) i; var e = Encoding.GetEncoding(50225); var y = e.GetBytes(new String(e.GetChars(x))); for (var i = 0; i < 256; i++) if(y[i] != (Byte) i) Console.WriteLine(i);If you run this you can see that one third of all byte values cannot be converted to a char and back to a byte. It works fine for 1252, 437, 1251, etc. though.