From f06f27e7bc098e334024c365004f9303e79997d9 Mon Sep 17 00:00:00 2001 From: Jakob Unterwurzacher Date: Thu, 6 Jun 2024 10:07:08 +0200 Subject: stupidgcm: detect AES-GCM acceleration like crypto/tls Instead of just looking for AES, also look for PCLMULQDQ, like crypto/tls does. Fixes: https://github.com/rfjakob/gocryptfs/issues/822 --- internal/speed/speed.go | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'internal/speed') diff --git a/internal/speed/speed.go b/internal/speed/speed.go index a361cf5..d6fa12e 100644 --- a/internal/speed/speed.go +++ b/internal/speed/speed.go @@ -31,9 +31,9 @@ func Run() { if cpu == "" { cpu = "unknown" } - aes := "; no AES acceleration" - if stupidgcm.CpuHasAES() { - aes = "; with AES acceleration" + aes := "; no AES-GCM acceleration" + if stupidgcm.HasAESGCMHardwareSupport() { + aes = "; with AES-GCM acceleration" } fmt.Printf("cpu: %s%s\n", cpu, aes) -- cgit v1.2.3