1
$\begingroup$

I am planning to encrypt the different fields of a database independently, using a symmetric encryption scheme (probably 3DES). Since some of the fields are as small as an integer, may that be problematic?

$\endgroup$

1 Answer 1

2
$\begingroup$

From the point of view of security, there is no problem with a key being longer than the ciphertext – 3DES has a 168-bit keysize and a 64-bit blocksize so for small messages it results in a ciphertext shorter than the key (at least without counting an IV).

However, in most block cipher modes the message gets padded up to a multiple of the blocksize, so a single 16-bit integer would result in at least 64 bits of ciphertext. That can get a bit inefficient if you have a lot of very small fields.

$\endgroup$

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.