diff options
author | Rob Austein <sra@hactrn.net> | 2015-06-10 18:52:16 -0400 |
---|---|---|
committer | Rob Austein <sra@hactrn.net> | 2015-06-10 18:52:16 -0400 |
commit | 5d21abbc8a727b7a586a91d0fc5c704deb1a69a4 (patch) | |
tree | f24a6959d0e37fbe6d95b122d8f5bd1b87d168a7 /modexp.c | |
parent | 9cca19087b29d5678dc39fd446bd8f6a6036b097 (diff) |
Operand lengths weren't including bug-workaround padding.
Diffstat (limited to 'modexp.c')
-rw-r--r-- | modexp.c | 4 |
1 files changed, 2 insertions, 2 deletions
@@ -186,10 +186,10 @@ hal_error_t hal_modexp(const uint8_t * const msg, const size_t msg_len, /* Messa check(set_blockmem(MODEXP_MODULUS_PTR_RST, MODEXP_MODULUS_DATA, mod, mod_len, io_len)); check(set_blockmem(MODEXP_MESSAGE_PTR_RST, MODEXP_MESSAGE_DATA, msg, msg_len, io_len)); - check(set_register(MODEXP_MODULUS_LENGTH, mod_len / 4)); + check(set_register(MODEXP_MODULUS_LENGTH, /* mod_len */ io_len / 4)); check(set_blockmem(MODEXP_EXPONENT_PTR_RST, MODEXP_EXPONENT_DATA, exp, exp_len, io_len)); - check(set_register(MODEXP_EXPONENT_LENGTH, exp_len / 4)); + check(set_register(MODEXP_EXPONENT_LENGTH, /* exp_len */ io_len / 4)); check(hal_io_wait_ready(MODEXP_ADDR_STATUS)); |