]> git.ipfire.org Git - thirdparty/openssl.git/commit
s390x: Disable HMAC hardware acceleration when an engine is used for the digest
authorIngo Franzki <ifranzki@linux.ibm.com>
Mon, 26 Aug 2024 09:26:03 +0000 (11:26 +0200)
committerTomas Mraz <tomas@openssl.org>
Tue, 3 Sep 2024 19:15:00 +0000 (21:15 +0200)
commita75d62637aa165a7f37e39a3a36e2a8b089913bc
treeadd56d8ec1c6e6b3a4b8c4208e3f32b04babdcce
parent03b22b4d7370a3ddf2c1723c2ff4dc3d169ea897
s390x: Disable HMAC hardware acceleration when an engine is used for the digest

The TLSProxy uses the 'ossltest' engine to produce known output for digests
and HMAC calls. However, when running on a s390x system that supports
hardware acceleration of HMAC, the engine is not used for calculating HMACs,
but the s390x specific HMAC implementation is used, which does produce correct
output, but not the known output that the engine would produce. This causes
some tests (i.e. test_key_share, test_sslextension, test_sslrecords,
test_sslvertol, and test_tlsextms) to fail.

Disable the s390x HMAC hardware acceleration if an engine is used for the
digest of the HMAC calculation. This provides compatibility for engines that
provide digest implementations, and assume that these implementations are also
used when calculating an HMAC.

Signed-off-by: Ingo Franzki <ifranzki@linux.ibm.com>
Reviewed-by: Neil Horman <nhorman@openssl.org>
Reviewed-by: Tomas Mraz <tomas@openssl.org>
(Merged from https://github.com/openssl/openssl/pull/25287)
crypto/hmac/hmac_s390x.c