[autotest] kernel_CryptoAPI: add tests for sha1, md5, and sha512 digests

Simple sanity tests to make sure the API is working. Compare against
Python's hashlib for reference.

Run these only >=3.8 kernels, since this API only works when we have
AF_ALG enabled.

BUG=chromium:462835
CQ-DEPEND=CL:290237,CL:290342,CL:290324,CL:290158
TEST=kernel_CryptoAPI

Change-Id: I597da68c12b9f97698f0ed45140b30dffed98e39
Signed-off-by: Brian Norris <briannorris@chromium.org>
Reviewed-on: https://chromium-review.googlesource.com/291424
Reviewed-by: Kees Cook <keescook@chromium.org>
2 files changed