Choosing the Right Kind of Encryption

Given the fact that a stream cipher handles 1 byte, or even 1 bit at a time, you might think that a stream cipher is better for encrypting computer login sessions, which are more byte-oriented. As it turns out, block ciphers aren't too bad for login sessions, because the blocks are often only 64 bits (8 bytes) in size. Essentially, your choice of cipher shouldn't depend on whether it is a block or stream cipher.

The following are some of the factors that will influence your choice of encryption:

  • The amount of security required— Some encryption algorithms can be broken in a matter of hours, and some would take many years. Others would take several times the anticipated lifetime of the universe to break, given ...

Get Special Edition Using Java™ 2 Enterprise Edition now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.