From: Michael Vrable Date: Sun, 17 Oct 2010 23:17:40 +0000 (-0700) Subject: When decrypting a log item also clear out the IV field. X-Git-Url: http://git.vrable.net/?p=bluesky.git;a=commitdiff_plain;h=e8d8d9a530c94f1fabc43c0222212296732fa874 When decrypting a log item also clear out the IV field. Not really needed, but this way the IV field being zero should be synonymous with an unencrypted log item. --- diff --git a/bluesky/crypto.c b/bluesky/crypto.c index 1dc5e0d..f34b8b7 100644 --- a/bluesky/crypto.c +++ b/bluesky/crypto.c @@ -244,6 +244,7 @@ gboolean bluesky_crypt_block_decrypt(gchar *cloud_block, size_t len, gcry_strerror(status)); } header->magic[3] ^= 0x10; + memset(header->crypt_iv, 0, sizeof(header->crypt_iv)); gcry_cipher_close(handle); }