RijndaelManaged without padding

  • Thread starter Thread starter Daniel Meier
  • Start date Start date
D

Daniel Meier

Hey

I'd tried to use the RijndaelManaged-Class to encrypt some data. The
size of the encrypted data have to be exactly the same as the original
data. Is there a way to do this with RijndaelManaged? I thought I can
use the CTS-Mode, but RijndaelManaged doesn't support this.

Thank you
Daniel
 
Daniel said:
Hey

I'd tried to use the RijndaelManaged-Class to encrypt some data. The
size of the encrypted data have to be exactly the same as the original
data. Is there a way to do this with RijndaelManaged? I thought I can
use the CTS-Mode, but RijndaelManaged doesn't support this.

Generally, when working with NET, you shouldn't use the cipher classes
directly. Instead, use them through CryptoStream, which takes care of
odd-length messages, etc. It's undocumented (as far as I can find) exactly
how CryptoStream uses the cipher - but presumably it's something along the
lines of OFB or CBC+CTS (hopefully the latter since it's ~8x faster).

-cd
 
Back
Top