From 420fdb7df8faf03fb31bf17c938285bb155e0998 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Stefan=20Negovanovi=C4=87?= Date: Wed, 11 Oct 2023 16:55:22 +0200 Subject: [PATCH] Remove MarshalMessageToBigInt (unused) --- consensus/polybft/signer/utils.go | 16 ---------------- 1 file changed, 16 deletions(-) diff --git a/consensus/polybft/signer/utils.go b/consensus/polybft/signer/utils.go index 0117714517..42d6ccb308 100644 --- a/consensus/polybft/signer/utils.go +++ b/consensus/polybft/signer/utils.go @@ -40,22 +40,6 @@ func CreateRandomBlsKeys(total int) ([]*PrivateKey, error) { return blsKeys, nil } -// MarshalMessageToBigInt marshalls message into two big ints -// first we must convert message bytes to point and than for each coordinate we create big int -func MarshalMessageToBigInt(message, domain []byte) ([2]*big.Int, error) { - point, err := hashToPoint(message, domain) - if err != nil { - return [2]*big.Int{}, err - } - - buf := point.Marshal() - - return [2]*big.Int{ - new(big.Int).SetBytes(buf[0:32]), - new(big.Int).SetBytes(buf[32:64]), - }, nil -} - // MakeKOSKSignature creates KOSK signature which prevents rogue attack func MakeKOSKSignature(privateKey *PrivateKey, address types.Address, chainID int64, domain []byte, supernetManagerAddr types.Address) (*Signature, error) {