commit | 0727ca41b7418378d6d063b8ade62b7437c98d0a | [log] [tgz] |
---|---|---|
author | Hanno Becker <hanno.becker@arm.com> | Wed Oct 25 16:07:09 2017 +0100 |
committer | Hanno Becker <hanno.becker@arm.com> | Wed Oct 25 16:11:03 2017 +0100 |
tree | 20edd4f3dc46b4deda7539cb1f5ec6f1efdd503c | |
parent | a75a4591430919a6eb3d430aca396044fe3816d4 [diff] |
Make mpi_read_binary time constant This commit modifies mpi_read_binary to always allocate the minimum number of limbs required to hold the entire buffer provided to the function, regardless of its content. Previously, leading zero bytes in the input data were detected and used to reduce memory footprint and time, but this non-constant behavior turned out to be non-tolerable for the cryptographic applications this function is used for.