comparison libtomcrypt/src/modes/cfb/cfb_encrypt.c @ 1471:6dba84798cd5

Update to libtomcrypt 1.18.1, merged with Dropbear changes
author Matt Johnston <matt@ucc.asn.au>
date Fri, 09 Feb 2018 21:44:05 +0800
parents f849a5ca2efc
children
comparison
equal deleted inserted replaced
1470:8bba51a55704 1471:6dba84798cd5
3 * LibTomCrypt is a library that provides various cryptographic 3 * LibTomCrypt is a library that provides various cryptographic
4 * algorithms in a highly modular and flexible manner. 4 * algorithms in a highly modular and flexible manner.
5 * 5 *
6 * The library is free for all purposes without any express 6 * The library is free for all purposes without any express
7 * guarantee it works. 7 * guarantee it works.
8 *
9 * Tom St Denis, [email protected], http://libtom.org
10 */ 8 */
11 #include "tomcrypt.h" 9 #include "tomcrypt.h"
12 10
13 /** 11 /**
14 @file cfb_encrypt.c 12 @file cfb_encrypt.c
49 return err; 47 return err;
50 } 48 }
51 cfb->padlen = 0; 49 cfb->padlen = 0;
52 } 50 }
53 cfb->pad[cfb->padlen] = (*ct = *pt ^ cfb->IV[cfb->padlen]); 51 cfb->pad[cfb->padlen] = (*ct = *pt ^ cfb->IV[cfb->padlen]);
54 ++pt; 52 ++pt;
55 ++ct; 53 ++ct;
56 ++(cfb->padlen); 54 ++(cfb->padlen);
57 } 55 }
58 return CRYPT_OK; 56 return CRYPT_OK;
59 } 57 }
60 58
61 #endif 59 #endif
62 60
63 /* $Source$ */ 61 /* ref: $Format:%D$ */
64 /* $Revision$ */ 62 /* git commit: $Format:%H$ */
65 /* $Date$ */ 63 /* commit time: $Format:%ai$ */