Administrator

Administrator

  • Tech Writer
  • 2.2k
  • 1.5m

help email and RijndaleManaged algorithm

Mar 4 2003 1:56 PM
I am trying to send email with an encrypted xml document attached to it. The file is writen to a log then picked up encrypted using the System.Security.Cryptography namespace and then attached to an email. When I receive the mail and decrypt the attachment, 1 out of ten will have the last few letters of the closing tag is missing. The path that the file takes is as follows. 1.Encrypted using RijndaelManaged Algorithm 2.attached to the email as a MIME Entity and encoded in base64 3.received in the email client and converted from base64 to a byte array of the attachment. 4.decrypt with RijndaelManaged Algorithm. The kicker is that when I don't encrypt the file with RijndaelManaged the files are all recieved in full and when I encrypt and decrypt without send in files by email the encrypted matches the decrypted file. however, when I do both together I lose data in 1 of every 10 files. the following is what the end of a messed up file looks like followed by the xml error it gets when opened. xml file ********************************************************** 30cee54dfc06 40904f34df5a Local Module 1