crypto: Use size_t for len argument in encrypt and decrpyt fn

Signed-off-by: Andreas Schneider <asn@cryptomilk.org>
This commit is contained in:
Andreas Schneider
2018-11-30 17:23:37 +01:00
parent 6d3672911b
commit c6ca62d7e1
4 changed files with 52 additions and 28 deletions

View File

@@ -165,10 +165,14 @@ struct ssh_cipher_struct {
/* sets the new key for immediate use */
int (*set_encrypt_key)(struct ssh_cipher_struct *cipher, void *key, void *IV);
int (*set_decrypt_key)(struct ssh_cipher_struct *cipher, void *key, void *IV);
void (*encrypt)(struct ssh_cipher_struct *cipher, void *in, void *out,
unsigned long len);
void (*decrypt)(struct ssh_cipher_struct *cipher, void *in, void *out,
unsigned long len);
void (*encrypt)(struct ssh_cipher_struct *cipher,
void *in,
void *out,
size_t len);
void (*decrypt)(struct ssh_cipher_struct *cipher,
void *in,
void *out,
size_t len);
void (*aead_encrypt)(struct ssh_cipher_struct *cipher, void *in, void *out,
size_t len, uint8_t *mac, uint64_t seq);
int (*aead_decrypt_length)(struct ssh_cipher_struct *cipher, void *in,