Gene, ----- Original Message ----- From: <Gene_Gaunt/ReviewWorks@reviewworks.com> > What is the rationale for limiting CIPHER source length to only 64 bytes? I actually missed this the first time around, I just spotted it while archiving my mail folders, so I apologise for the delay ! DES is a classic block cipher. The block size for DES is 64, i.e it encrypts blocks of data in 64 block chunks and thus this is why CIPHER 'limits' the source data to 64. This can however cause encryption problems if your data doesn't pad to fit exactly within a multiple of the block size. If this is the case, and you're real paranoid about the data, you should set the chaining flag in the CIPHER template (to add feedback from the last encrypted block) and set padding to be on, too. Also by using chaining, you will not see the performance issues you suggested. Cryptographic Support/400 (if it uses DES, and my guess is it does) will still limit you to 64 blocks, but there probably be a wrapper for the encryption API that will do the chaining of plaintext larger than 64, to save you having to do it yourself programmatically. Not setting the options (or just selecting padding, or even padding the data yourself) can reveal some information about the encryption - and given today's CPU power it *might* be enough information to discover the plaintext. Hope this helps, --phil +--- | This is the MI Programmers Mailing List! | To submit a new message, send your mail to MI400@midrange.com. | To subscribe to this list send email to MI400-SUB@midrange.com. | To unsubscribe from this list send email to MI400-UNSUB@midrange.com. | Questions should be directed to the list owner/operator: email@example.com +---
As an Amazon Associate we earn from qualifying purchases.
Operating expenses for this site are earned using the Amazon Associate program and Google Adsense.