Caroline wrote:
> byte[] IV_128 = {1,2,3,4,5,6,7,8,9,0,1,2,3,4,5,6};
Usually the IV is used to provide nondeterministic cryptography, where
the same payload is encrypted differently each time. That property may
or may not be valuable to you, but if you need it you should choose
random IV's and store those with the encrypted data.
The usual story of importance of nondeterministic encryption is:
A general sends the message encrypt("Attack at dawn") to his troops. The
enemy intercepts the message, but cannot decrypt it -- so they don't
know when the attack will come and the general is victorious.
Two weeks later the general again sends encrypt("Attack at dawn") to his
troops in an attack on another town, the enemy intercepts the message
and cannot decrypt it -- but the sneaky enemy recognises the message
from two weeks ago and is ready to defend when the attack comes,
incurring terrible losses.
--
Helge Jensen
private.php?do=newpm&u=
sip:(E-Mail Removed)
-=> Sebastian cover-music:
http://ungdomshus.nu <=-