From 45bf99743d7a7d63127f1bd302cf2a3a04a84067 Mon Sep 17 00:00:00 2001 From: DrBlast Date: Mon, 26 Jan 2026 16:52:39 +0300 Subject: [PATCH] bls keygen version 5 --- pom.xml | 2 +- src/main/java/com/wavesplatform/crypto/BlsUtils.java | 5 ++++- 2 files changed, 5 insertions(+), 2 deletions(-) diff --git a/pom.xml b/pom.xml index 5419d16..4591511 100644 --- a/pom.xml +++ b/pom.xml @@ -6,7 +6,7 @@ com.wavesplatform waves-crypto - 2.0.6 + 2.0.7-SNAPSHOT Waves Crypto for Java Tools to work with cryptographic primitives used in the Waves blockchain diff --git a/src/main/java/com/wavesplatform/crypto/BlsUtils.java b/src/main/java/com/wavesplatform/crypto/BlsUtils.java index c0dbfb3..b45324e 100644 --- a/src/main/java/com/wavesplatform/crypto/BlsUtils.java +++ b/src/main/java/com/wavesplatform/crypto/BlsUtils.java @@ -2,12 +2,15 @@ import supranational.blst.*; +import java.nio.charset.StandardCharsets; + public class BlsUtils { private static final String DST = "BLS_SIG_BLS12381G2_XMD:SHA-256_SSWU_RO_NUL_"; + private static final byte[] BLS_KEYGEN_SALT = "BLS-SIG-KEYGEN-SALT-".getBytes(StandardCharsets.UTF_8); public static SecretKey mkBlsSecretKey(byte[] seed) { SecretKey sk = new SecretKey(); - sk.keygen(seed); + sk.keygen_v5(seed, BLS_KEYGEN_SALT); return sk; }