diff options
Diffstat (limited to 'cipher.c')
-rw-r--r-- | cipher.c | 6 |
1 files changed, 3 insertions, 3 deletions
@@ -266,7 +266,7 @@ cast_setkey(CipherContext *cc, const u_char *key, u_int keylen) | |||
266 | void | 266 | void |
267 | cast_setiv(CipherContext *cc, const u_char *iv, u_int ivlen) | 267 | cast_setiv(CipherContext *cc, const u_char *iv, u_int ivlen) |
268 | { | 268 | { |
269 | if (iv == NULL) | 269 | if (iv == NULL) |
270 | fatal("no IV for %s.", cc->cipher->name); | 270 | fatal("no IV for %s.", cc->cipher->name); |
271 | memcpy(cc->u.cast.iv, (char *)iv, 8); | 271 | memcpy(cc->u.cast.iv, (char *)iv, 8); |
272 | } | 272 | } |
@@ -295,7 +295,7 @@ rijndael_setkey(CipherContext *cc, const u_char *key, u_int keylen) | |||
295 | void | 295 | void |
296 | rijndael_setiv(CipherContext *cc, const u_char *iv, u_int ivlen) | 296 | rijndael_setiv(CipherContext *cc, const u_char *iv, u_int ivlen) |
297 | { | 297 | { |
298 | if (iv == NULL) | 298 | if (iv == NULL) |
299 | fatal("no IV for %s.", cc->cipher->name); | 299 | fatal("no IV for %s.", cc->cipher->name); |
300 | memcpy((u_char *)cc->u.rijndael.iv, iv, RIJNDAEL_BLOCKSIZE); | 300 | memcpy((u_char *)cc->u.rijndael.iv, iv, RIJNDAEL_BLOCKSIZE); |
301 | } | 301 | } |
@@ -415,7 +415,7 @@ Cipher ciphers[] = { | |||
415 | SSH_CIPHER_SSH2, 16, 32, | 415 | SSH_CIPHER_SSH2, 16, 32, |
416 | rijndael_setkey, rijndael_setiv, | 416 | rijndael_setkey, rijndael_setiv, |
417 | rijndael_cbc_encrypt, rijndael_cbc_decrypt }, | 417 | rijndael_cbc_encrypt, rijndael_cbc_decrypt }, |
418 | { NULL, SSH_CIPHER_ILLEGAL, 0, 0, NULL, NULL, NULL, NULL } | 418 | { NULL, SSH_CIPHER_ILLEGAL, 0, 0, NULL, NULL, NULL, NULL } |
419 | }; | 419 | }; |
420 | 420 | ||
421 | /*--*/ | 421 | /*--*/ |