aboutsummaryrefslogtreecommitdiff
path: root/src/util/crypto_symmetric.c
diff options
context:
space:
mode:
authorChristian Grothoff <christian@grothoff.org>2013-10-03 22:13:50 +0000
committerChristian Grothoff <christian@grothoff.org>2013-10-03 22:13:50 +0000
commite30660eaff5f945f92dcea5153dbafb2f11210d7 (patch)
treea92d96f1501b8b71639b442b29d0e6237ae44fc7 /src/util/crypto_symmetric.c
parent911957f3407c59707ed430a91926fce8bf0abe8c (diff)
downloadgnunet-e30660eaff5f945f92dcea5153dbafb2f11210d7.tar.gz
gnunet-e30660eaff5f945f92dcea5153dbafb2f11210d7.zip
-fix IV
Diffstat (limited to 'src/util/crypto_symmetric.c')
-rw-r--r--src/util/crypto_symmetric.c16
1 files changed, 8 insertions, 8 deletions
diff --git a/src/util/crypto_symmetric.c b/src/util/crypto_symmetric.c
index 3cc546652..97e2a4cfb 100644
--- a/src/util/crypto_symmetric.c
+++ b/src/util/crypto_symmetric.c
@@ -121,11 +121,11 @@ setup_cipher_twofish (gcry_cipher_hd_t *handle,
121 * @returns the size of the encrypted block, -1 for errors 121 * @returns the size of the encrypted block, -1 for errors
122 */ 122 */
123ssize_t 123ssize_t
124GNUNET_CRYPTO_symmetric_encrypt (const void *block, size_t len, 124GNUNET_CRYPTO_symmetric_encrypt (const void *block,
125 const struct GNUNET_CRYPTO_SymmetricSessionKey * 125 size_t len,
126 sessionkey, 126 const struct GNUNET_CRYPTO_SymmetricSessionKey *sessionkey,
127 const struct GNUNET_CRYPTO_SymmetricInitializationVector * 127 const struct GNUNET_CRYPTO_SymmetricInitializationVector *iv,
128 iv, void *result) 128 void *result)
129{ 129{
130 gcry_cipher_hd_t handle; 130 gcry_cipher_hd_t handle;
131 char tmp[len]; 131 char tmp[len];
@@ -156,9 +156,9 @@ GNUNET_CRYPTO_symmetric_encrypt (const void *block, size_t len,
156 */ 156 */
157ssize_t 157ssize_t
158GNUNET_CRYPTO_symmetric_decrypt (const void *block, size_t size, 158GNUNET_CRYPTO_symmetric_decrypt (const void *block, size_t size,
159 const struct GNUNET_CRYPTO_SymmetricSessionKey *sessionkey, 159 const struct GNUNET_CRYPTO_SymmetricSessionKey *sessionkey,
160 const struct GNUNET_CRYPTO_SymmetricInitializationVector *iv, 160 const struct GNUNET_CRYPTO_SymmetricInitializationVector *iv,
161 void *result) 161 void *result)
162{ 162{
163 gcry_cipher_hd_t handle; 163 gcry_cipher_hd_t handle;
164 char tmp[size]; 164 char tmp[size];