From 08a926d991a03ff2fd60d580774b0b9b167b6924 Mon Sep 17 00:00:00 2001 From: Paragon Initiative Enterprises Date: Tue, 3 Sep 2024 19:33:47 -0400 Subject: [PATCH] Use the corresponding hash algorithm, rather than always sha384 This has no security impact, but may violate the principle of least astonishment for people using, e.g., secp256k1 --- src/EasyECC.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/EasyECC.php b/src/EasyECC.php index 3bc909b..ed9f532 100644 --- a/src/EasyECC.php +++ b/src/EasyECC.php @@ -221,7 +221,7 @@ public function sign( EccFactory::getAdapter(), $privateKey, $hash, - 'sha384' + $this->hashAlgo ); $k = $kGen->generate($this->generator->getOrder());