mirror of
https://github.com/Telecominfraproject/OpenCellular.git
synced 2026-01-09 17:11:42 +00:00
DCRYPTO_HMAC_SHA256_init makes two calls to DCRYPTO_SHA256_init() without an intervening HASH_final() call. This is incorrect usage of the the hashing API, and results in the hardware SHA engine getting locked for the life-time of the process (and resulting in all future hash calls falling back to the software implementation). This bug manifested itself when introducing NVRAM encryption, which requires the hardware SHA engine to be available for key generation. BRANCH=none BUG=chrome-os-partner:55331 TEST=TCG tests pass Change-Id: Ia4ccb6a6d64636c4618ef775291442975f3f1f92 Signed-off-by: nagendra modadugu <ngm@google.com> Reviewed-on: https://chromium-review.googlesource.com/430154 Commit-Ready: Nagendra Modadugu <ngm@google.com> Tested-by: Nagendra Modadugu <ngm@google.com> Reviewed-by: Marius Schilder <mschilder@chromium.org> Reviewed-by: Vadim Bendebury <vbendeb@chromium.org>