Search in sources :

Example 1 with PrecheckVerifier

use of com.hedera.services.sigs.verification.PrecheckVerifier in project hedera-services by hashgraph.

the class SigVerifierRegressionTest method setupFor.

private void setupFor(TxnHandlingScenario scenario) throws Throwable {
    accounts = scenario.accounts();
    platformTxn = scenario.platformTxn();
    aliasManager = mock(AliasManager.class);
    keyOrder = new SigRequirements(defaultLookupsFor(aliasManager, null, () -> accounts, () -> null, ref -> null, ref -> null), mockSignatureWaivers);
    final var nodeInfo = mock(NodeInfo.class);
    given(nodeInfo.selfAccount()).willReturn(DEFAULT_NODE);
    isQueryPayment = PrecheckUtils.queryPaymentTestFor(nodeInfo);
    SyncVerifier syncVerifier = new CryptoEngine()::verifySync;
    precheckKeyReqs = new PrecheckKeyReqs(keyOrder, isQueryPayment);
    precheckVerifier = new PrecheckVerifier(syncVerifier, precheckKeyReqs);
}
Also used : SyncVerifier(com.hedera.services.sigs.verification.SyncVerifier) AliasManager(com.hedera.services.ledger.accounts.AliasManager) SigRequirements(com.hedera.services.sigs.order.SigRequirements) PrecheckKeyReqs(com.hedera.services.sigs.verification.PrecheckKeyReqs) PrecheckVerifier(com.hedera.services.sigs.verification.PrecheckVerifier) CryptoEngine(com.swirlds.common.crypto.engine.CryptoEngine)

Aggregations

AliasManager (com.hedera.services.ledger.accounts.AliasManager)1 SigRequirements (com.hedera.services.sigs.order.SigRequirements)1 PrecheckKeyReqs (com.hedera.services.sigs.verification.PrecheckKeyReqs)1 PrecheckVerifier (com.hedera.services.sigs.verification.PrecheckVerifier)1 SyncVerifier (com.hedera.services.sigs.verification.SyncVerifier)1 CryptoEngine (com.swirlds.common.crypto.engine.CryptoEngine)1