|
12 | 12 | import com.hedera.cryptography.wraps.WRAPSLibraryBridge; |
13 | 13 | import com.hedera.node.app.history.HistoryLibrary; |
14 | 14 | import edu.umd.cs.findbugs.annotations.NonNull; |
15 | | -import java.util.Arrays; |
16 | 15 | import java.util.Set; |
17 | 16 | import java.util.SplittableRandom; |
18 | | -import org.apache.logging.log4j.LogManager; |
19 | | -import org.apache.logging.log4j.Logger; |
20 | | -import org.hiero.base.utility.CommonUtils; |
21 | 17 |
|
22 | 18 | /** |
23 | 19 | * Default implementation of the {@link HistoryLibrary}. |
24 | 20 | */ |
25 | 21 | public class HistoryLibraryImpl implements HistoryLibrary { |
26 | | - private static final Logger logger = LogManager.getLogger(HistoryLibraryImpl.class); |
27 | | - |
28 | 22 | public static final SplittableRandom RANDOM = new SplittableRandom(); |
29 | 23 | public static final WRAPSLibraryBridge WRAPS = WRAPSLibraryBridge.getInstance(); |
30 | 24 |
|
@@ -129,45 +123,6 @@ public Proof constructGenesisWrapsProof( |
129 | 123 | requireNonNull(aggregatedSignature); |
130 | 124 | requireNonNull(signers); |
131 | 125 | requireNonNull(addressBook); |
132 | | - |
133 | | - final var prevSchnorrPublicKeys = addressBook.publicKeys(); |
134 | | - final var prevWeights = addressBook.weights(); |
135 | | - final var nextSchnorrPublicKeys = addressBook.publicKeys(); |
136 | | - final var nextWeights = addressBook.weights(); |
137 | | - final var mask = addressBook.signersMask(signers); |
138 | | - final var tssVerificationKey = GENESIS_WRAPS_METADATA; |
139 | | - logger.info(" genesisAddressBookHash == null ? {}", genesisAddressBookHash == null); |
140 | | - logger.info(" genesisAddressBookHash.length == 0 ? {}", genesisAddressBookHash.length == 0); |
141 | | - logger.info(" prevSchnorrPublicKeys == null ? {}", prevSchnorrPublicKeys == null); |
142 | | - logger.info(" prevWeights == null ? {}", prevWeights == null); |
143 | | - logger.info(" prevSchnorrPublicKeys.length == 0 ? {}", prevSchnorrPublicKeys.length == 0); |
144 | | - logger.info( |
145 | | - " prevSchnorrPublicKeys.length != prevWeights.length ? {}", |
146 | | - prevSchnorrPublicKeys.length != prevWeights.length); |
147 | | - logger.info(" !WRAPSLibraryBridge.validateWeightsSum(prevWeights) ? {}", !validateWeightsSum(prevWeights)); |
148 | | - logger.info(" nextSchnorrPublicKeys == null ? {}", nextSchnorrPublicKeys == null); |
149 | | - logger.info(" nextWeights == null ? {}", nextWeights == null); |
150 | | - logger.info(" nextSchnorrPublicKeys.length == 0 ? {}", nextSchnorrPublicKeys.length == 0); |
151 | | - logger.info( |
152 | | - " nextSchnorrPublicKeys.length != nextWeights.length ? {}", |
153 | | - nextSchnorrPublicKeys.length != nextWeights.length); |
154 | | - logger.info(" !WRAPSLibraryBridge.validateWeightsSum(nextWeights) ? {}", !validateWeightsSum(nextWeights)); |
155 | | - logger.info(" tssVerificationKey == null ? {}", tssVerificationKey == null); |
156 | | - logger.info(" tssVerificationKey.length == 0 ? {}", tssVerificationKey.length == 0); |
157 | | - logger.info(" aggregateSignature == null ? {}", aggregatedSignature == null); |
158 | | - logger.info(" aggregateSignature.length == 0 ? {}", aggregatedSignature.length == 0); |
159 | | - logger.info(" signers == null ? {}", mask == null); |
160 | | - logger.info( |
161 | | - " signers.length != prevSchnorrPublicKeys.length ? {}", mask.length != prevSchnorrPublicKeys.length); |
162 | | - logger.info( |
163 | | - " !WRAPSLibraryBridge.validateSchnorrPublicKeys(prevSchnorrPublicKeys) ? {}", |
164 | | - !validateSchnorrPublicKeys(prevSchnorrPublicKeys)); |
165 | | - logger.info( |
166 | | - ") !WRAPSLibraryBridge.validateSchnorrPublicKeys(nextSchnorrPublicKeys) ? {}", |
167 | | - !validateSchnorrPublicKeys(nextSchnorrPublicKeys)); |
168 | | - logger.info("Is proof supported? {}", WRAPSLibraryBridge.isProofSupported()); |
169 | | - logger.info("Genesis hash: " + CommonUtils.hex(genesisAddressBookHash)); |
170 | | - logger.info("Signers: " + Arrays.toString(mask)); |
171 | 126 | return WRAPS.constructWrapsProof( |
172 | 127 | genesisAddressBookHash, |
173 | 128 | addressBook.publicKeys(), |
|
0 commit comments