@aztec/validator-client 0.0.1-commit.ef17749e1 → 0.0.1-commit.f1b29a41e
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +9 -12
- package/dest/checkpoint_builder.d.ts +10 -7
- package/dest/checkpoint_builder.d.ts.map +1 -1
- package/dest/checkpoint_builder.js +64 -41
- package/dest/config.d.ts +1 -1
- package/dest/config.d.ts.map +1 -1
- package/dest/config.js +0 -5
- package/dest/duties/validation_service.js +1 -1
- package/dest/factory.d.ts +7 -4
- package/dest/factory.d.ts.map +1 -1
- package/dest/factory.js +5 -5
- package/dest/index.d.ts +2 -2
- package/dest/index.d.ts.map +1 -1
- package/dest/index.js +1 -1
- package/dest/key_store/ha_key_store.js +1 -1
- package/dest/metrics.d.ts +2 -2
- package/dest/metrics.d.ts.map +1 -1
- package/dest/proposal_handler.d.ts +107 -0
- package/dest/proposal_handler.d.ts.map +1 -0
- package/dest/{block_proposal_handler.js → proposal_handler.js} +425 -13
- package/dest/validator.d.ts +8 -13
- package/dest/validator.d.ts.map +1 -1
- package/dest/validator.js +43 -215
- package/package.json +19 -19
- package/src/checkpoint_builder.ts +79 -52
- package/src/config.ts +0 -5
- package/src/duties/validation_service.ts +1 -1
- package/src/factory.ts +9 -4
- package/src/index.ts +1 -1
- package/src/key_store/ha_key_store.ts +1 -1
- package/src/metrics.ts +1 -1
- package/src/{block_proposal_handler.ts → proposal_handler.ts} +487 -14
- package/src/validator.ts +60 -234
- package/dest/block_proposal_handler.d.ts +0 -63
- package/dest/block_proposal_handler.d.ts.map +0 -1
package/src/validator.ts
CHANGED
|
@@ -1,7 +1,6 @@
|
|
|
1
1
|
import type { BlobClientInterface } from '@aztec/blob-client/client';
|
|
2
2
|
import { type Blob, getBlobsPerL1Block } from '@aztec/blob-lib';
|
|
3
3
|
import type { EpochCache } from '@aztec/epoch-cache';
|
|
4
|
-
import { validateFeeAssetPriceModifier } from '@aztec/ethereum/contracts';
|
|
5
4
|
import {
|
|
6
5
|
BlockNumber,
|
|
7
6
|
CheckpointNumber,
|
|
@@ -10,11 +9,9 @@ import {
|
|
|
10
9
|
SlotNumber,
|
|
11
10
|
} from '@aztec/foundation/branded-types';
|
|
12
11
|
import { Fr } from '@aztec/foundation/curves/bn254';
|
|
13
|
-
import { TimeoutError } from '@aztec/foundation/error';
|
|
14
12
|
import type { EthAddress } from '@aztec/foundation/eth-address';
|
|
15
13
|
import type { Signature } from '@aztec/foundation/eth-signature';
|
|
16
14
|
import { type LogData, type Logger, createLogger } from '@aztec/foundation/log';
|
|
17
|
-
import { retryUntil } from '@aztec/foundation/retry';
|
|
18
15
|
import { RunningPromise } from '@aztec/foundation/running-promise';
|
|
19
16
|
import { sleep } from '@aztec/foundation/sleep';
|
|
20
17
|
import { DateProvider } from '@aztec/foundation/timer';
|
|
@@ -23,9 +20,8 @@ import type { DuplicateAttestationInfo, DuplicateProposalInfo, P2P, PeerId } fro
|
|
|
23
20
|
import { AuthRequest, AuthResponse, BlockProposalValidator, ReqRespSubProtocol } from '@aztec/p2p';
|
|
24
21
|
import { OffenseType, WANT_TO_SLASH_EVENT, type Watcher, type WatcherEmitter } from '@aztec/slasher';
|
|
25
22
|
import type { AztecAddress } from '@aztec/stdlib/aztec-address';
|
|
26
|
-
import type { CommitteeAttestationsAndSigners,
|
|
27
|
-
import {
|
|
28
|
-
import { getEpochAtSlot, getTimestampForSlot } from '@aztec/stdlib/epoch-helpers';
|
|
23
|
+
import type { CommitteeAttestationsAndSigners, L2BlockSink, L2BlockSource } from '@aztec/stdlib/block';
|
|
24
|
+
import { getEpochAtSlot } from '@aztec/stdlib/epoch-helpers';
|
|
29
25
|
import type {
|
|
30
26
|
CreateCheckpointProposalLastBlockData,
|
|
31
27
|
ITxProvider,
|
|
@@ -33,7 +29,7 @@ import type {
|
|
|
33
29
|
ValidatorClientFullConfig,
|
|
34
30
|
WorldStateSynchronizer,
|
|
35
31
|
} from '@aztec/stdlib/interfaces/server';
|
|
36
|
-
import {
|
|
32
|
+
import type { L1ToL2MessageSource } from '@aztec/stdlib/messaging';
|
|
37
33
|
import {
|
|
38
34
|
type BlockProposal,
|
|
39
35
|
type BlockProposalOptions,
|
|
@@ -43,23 +39,27 @@ import {
|
|
|
43
39
|
type CheckpointProposalOptions,
|
|
44
40
|
} from '@aztec/stdlib/p2p';
|
|
45
41
|
import type { CheckpointHeader } from '@aztec/stdlib/rollup';
|
|
46
|
-
import type { BlockHeader,
|
|
42
|
+
import type { BlockHeader, Tx } from '@aztec/stdlib/tx';
|
|
47
43
|
import { AttestationTimeoutError } from '@aztec/stdlib/validators';
|
|
48
44
|
import { type TelemetryClient, type Tracer, getTelemetryClient } from '@aztec/telemetry-client';
|
|
49
|
-
import {
|
|
50
|
-
|
|
45
|
+
import {
|
|
46
|
+
createHASigner,
|
|
47
|
+
createLocalSignerWithProtection,
|
|
48
|
+
createSignerFromSharedDb,
|
|
49
|
+
} from '@aztec/validator-ha-signer/factory';
|
|
50
|
+
import { DutyType, type SigningContext, type SlashingProtectionDatabase } from '@aztec/validator-ha-signer/types';
|
|
51
51
|
import type { ValidatorHASigner } from '@aztec/validator-ha-signer/validator-ha-signer';
|
|
52
52
|
|
|
53
53
|
import { EventEmitter } from 'events';
|
|
54
54
|
import type { TypedDataDefinition } from 'viem';
|
|
55
55
|
|
|
56
|
-
import { BlockProposalHandler, type BlockProposalValidationFailureReason } from './block_proposal_handler.js';
|
|
57
56
|
import type { FullNodeCheckpointsBuilder } from './checkpoint_builder.js';
|
|
58
57
|
import { ValidationService } from './duties/validation_service.js';
|
|
59
58
|
import { HAKeyStore } from './key_store/ha_key_store.js';
|
|
60
59
|
import type { ExtendedValidatorKeyStore } from './key_store/interface.js';
|
|
61
60
|
import { NodeKeystoreAdapter } from './key_store/node_keystore_adapter.js';
|
|
62
61
|
import { ValidatorMetrics } from './metrics.js';
|
|
62
|
+
import { type BlockProposalValidationFailureReason, ProposalHandler } from './proposal_handler.js';
|
|
63
63
|
|
|
64
64
|
// We maintain a set of proposers who have proposed invalid blocks.
|
|
65
65
|
// Just cap the set to avoid unbounded growth.
|
|
@@ -102,7 +102,7 @@ export class ValidatorClient extends (EventEmitter as new () => WatcherEmitter)
|
|
|
102
102
|
private keyStore: ExtendedValidatorKeyStore,
|
|
103
103
|
private epochCache: EpochCache,
|
|
104
104
|
private p2pClient: P2P,
|
|
105
|
-
private
|
|
105
|
+
private proposalHandler: ProposalHandler,
|
|
106
106
|
private blockSource: L2BlockSource,
|
|
107
107
|
private checkpointsBuilder: FullNodeCheckpointsBuilder,
|
|
108
108
|
private worldState: WorldStateSynchronizer,
|
|
@@ -197,13 +197,14 @@ export class ValidatorClient extends (EventEmitter as new () => WatcherEmitter)
|
|
|
197
197
|
blobClient: BlobClientInterface,
|
|
198
198
|
dateProvider: DateProvider = new DateProvider(),
|
|
199
199
|
telemetry: TelemetryClient = getTelemetryClient(),
|
|
200
|
+
slashingProtectionDb?: SlashingProtectionDatabase,
|
|
200
201
|
) {
|
|
201
202
|
const metrics = new ValidatorMetrics(telemetry);
|
|
202
203
|
const blockProposalValidator = new BlockProposalValidator(epochCache, {
|
|
203
204
|
txsPermitted: !config.disableTransactions,
|
|
204
205
|
maxTxsPerBlock: config.validateMaxTxsPerBlock,
|
|
205
206
|
});
|
|
206
|
-
const
|
|
207
|
+
const proposalHandler = new ProposalHandler(
|
|
207
208
|
checkpointsBuilder,
|
|
208
209
|
worldState,
|
|
209
210
|
blockSource,
|
|
@@ -212,6 +213,7 @@ export class ValidatorClient extends (EventEmitter as new () => WatcherEmitter)
|
|
|
212
213
|
blockProposalValidator,
|
|
213
214
|
epochCache,
|
|
214
215
|
config,
|
|
216
|
+
blobClient,
|
|
215
217
|
metrics,
|
|
216
218
|
dateProvider,
|
|
217
219
|
telemetry,
|
|
@@ -219,7 +221,13 @@ export class ValidatorClient extends (EventEmitter as new () => WatcherEmitter)
|
|
|
219
221
|
|
|
220
222
|
const nodeKeystoreAdapter = NodeKeystoreAdapter.fromKeyStoreManager(keyStoreManager);
|
|
221
223
|
let slashingProtectionSigner: ValidatorHASigner;
|
|
222
|
-
if (
|
|
224
|
+
if (slashingProtectionDb) {
|
|
225
|
+
// Shared database mode: use a pre-existing database (e.g. for testing HA setups).
|
|
226
|
+
({ signer: slashingProtectionSigner } = createSignerFromSharedDb(slashingProtectionDb, config, {
|
|
227
|
+
telemetryClient: telemetry,
|
|
228
|
+
dateProvider,
|
|
229
|
+
}));
|
|
230
|
+
} else if (config.haSigningEnabled) {
|
|
223
231
|
// Multi-node HA mode: use PostgreSQL-backed distributed locking.
|
|
224
232
|
// If maxStuckDutiesAgeMs is not explicitly set, compute it from Aztec slot duration
|
|
225
233
|
const haConfig = {
|
|
@@ -244,7 +252,7 @@ export class ValidatorClient extends (EventEmitter as new () => WatcherEmitter)
|
|
|
244
252
|
validatorKeyStore,
|
|
245
253
|
epochCache,
|
|
246
254
|
p2pClient,
|
|
247
|
-
|
|
255
|
+
proposalHandler,
|
|
248
256
|
blockSource,
|
|
249
257
|
checkpointsBuilder,
|
|
250
258
|
worldState,
|
|
@@ -265,8 +273,8 @@ export class ValidatorClient extends (EventEmitter as new () => WatcherEmitter)
|
|
|
265
273
|
.filter(addr => !this.config.disabledValidators.some(disabled => disabled.equals(addr)));
|
|
266
274
|
}
|
|
267
275
|
|
|
268
|
-
public
|
|
269
|
-
return this.
|
|
276
|
+
public getProposalHandler() {
|
|
277
|
+
return this.proposalHandler;
|
|
270
278
|
}
|
|
271
279
|
|
|
272
280
|
public signWithAddress(addr: EthAddress, msg: TypedDataDefinition, context: SigningContext) {
|
|
@@ -339,7 +347,7 @@ export class ValidatorClient extends (EventEmitter as new () => WatcherEmitter)
|
|
|
339
347
|
checkpoint: CheckpointProposalCore,
|
|
340
348
|
proposalSender: PeerId,
|
|
341
349
|
): Promise<CheckpointAttestation[] | undefined> => this.attestToCheckpointProposal(checkpoint, proposalSender);
|
|
342
|
-
this.p2pClient.
|
|
350
|
+
this.p2pClient.registerValidatorCheckpointProposalHandler(checkpointHandler);
|
|
343
351
|
|
|
344
352
|
// Duplicate proposal handler - triggers slashing for equivocation
|
|
345
353
|
this.p2pClient.registerDuplicateProposalCallback((info: DuplicateProposalInfo) => {
|
|
@@ -378,13 +386,12 @@ export class ValidatorClient extends (EventEmitter as new () => WatcherEmitter)
|
|
|
378
386
|
return false;
|
|
379
387
|
}
|
|
380
388
|
|
|
381
|
-
//
|
|
389
|
+
// Log self-proposals from HA peers (same validator key on different nodes)
|
|
382
390
|
if (this.getValidatorAddresses().some(addr => addr.equals(proposer))) {
|
|
383
|
-
this.log.
|
|
391
|
+
this.log.verbose(`Processing block proposal from HA peer for slot ${slotNumber}`, {
|
|
384
392
|
proposer: proposer.toString(),
|
|
385
393
|
slotNumber,
|
|
386
394
|
});
|
|
387
|
-
return false;
|
|
388
395
|
}
|
|
389
396
|
|
|
390
397
|
// Check if we're in the committee (for metrics purposes)
|
|
@@ -400,25 +407,25 @@ export class ValidatorClient extends (EventEmitter as new () => WatcherEmitter)
|
|
|
400
407
|
|
|
401
408
|
// Reexecute txs if we are part of the committee, or if slashing is enabled, or if we are configured to always reexecute.
|
|
402
409
|
// In fisherman mode, we always reexecute to validate proposals.
|
|
403
|
-
const {
|
|
404
|
-
this.config;
|
|
410
|
+
const { slashBroadcastedInvalidBlockPenalty, alwaysReexecuteBlockProposals, fishermanMode } = this.config;
|
|
405
411
|
const shouldReexecute =
|
|
406
412
|
fishermanMode ||
|
|
407
|
-
|
|
408
|
-
|
|
413
|
+
slashBroadcastedInvalidBlockPenalty > 0n ||
|
|
414
|
+
partOfCommittee ||
|
|
409
415
|
alwaysReexecuteBlockProposals ||
|
|
410
416
|
this.blobClient.canUpload();
|
|
411
417
|
|
|
412
|
-
const validationResult = await this.
|
|
418
|
+
const validationResult = await this.proposalHandler.handleBlockProposal(
|
|
413
419
|
proposal,
|
|
414
420
|
proposalSender,
|
|
415
421
|
!!shouldReexecute && !escapeHatchOpen,
|
|
416
422
|
);
|
|
417
423
|
|
|
418
424
|
if (!validationResult.isValid) {
|
|
419
|
-
this.log.warn(`Block proposal validation failed: ${validationResult.reason}`, proposalInfo);
|
|
420
|
-
|
|
421
425
|
const reason = validationResult.reason || 'unknown';
|
|
426
|
+
|
|
427
|
+
this.log.warn(`Block proposal validation failed: ${reason}`, proposalInfo);
|
|
428
|
+
|
|
422
429
|
// Classify failure reason: bad proposal vs node issue
|
|
423
430
|
const badProposalReasons: BlockProposalValidationFailureReason[] = [
|
|
424
431
|
'invalid_proposal',
|
|
@@ -473,68 +480,50 @@ export class ValidatorClient extends (EventEmitter as new () => WatcherEmitter)
|
|
|
473
480
|
proposal: CheckpointProposalCore,
|
|
474
481
|
_proposalSender: PeerId,
|
|
475
482
|
): Promise<CheckpointAttestation[] | undefined> {
|
|
476
|
-
const
|
|
483
|
+
const proposalSlotNumber = proposal.slotNumber;
|
|
477
484
|
const proposer = proposal.getSender();
|
|
478
485
|
|
|
479
486
|
// If escape hatch is open for this slot's epoch, do not attest.
|
|
480
|
-
if (await this.epochCache.isEscapeHatchOpenAtSlot(
|
|
481
|
-
this.log.warn(`Escape hatch open for slot ${
|
|
482
|
-
return undefined;
|
|
483
|
-
}
|
|
484
|
-
|
|
485
|
-
// Reject proposals with invalid signatures
|
|
486
|
-
if (!proposer) {
|
|
487
|
-
this.log.warn(`Received checkpoint proposal with invalid signature for slot ${slotNumber}`);
|
|
487
|
+
if (await this.epochCache.isEscapeHatchOpenAtSlot(proposalSlotNumber)) {
|
|
488
|
+
this.log.warn(`Escape hatch open for slot ${proposalSlotNumber}, skipping checkpoint attestation handling`);
|
|
488
489
|
return undefined;
|
|
489
490
|
}
|
|
490
491
|
|
|
491
492
|
// Ignore proposals from ourselves (may happen in HA setups)
|
|
492
|
-
if (this.getValidatorAddresses().some(addr => addr.equals(proposer))) {
|
|
493
|
-
this.log.
|
|
493
|
+
if (proposer && this.getValidatorAddresses().some(addr => addr.equals(proposer))) {
|
|
494
|
+
this.log.debug(`Ignoring block proposal from self for slot ${proposalSlotNumber}`, {
|
|
494
495
|
proposer: proposer.toString(),
|
|
495
|
-
|
|
496
|
+
proposalSlotNumber,
|
|
496
497
|
});
|
|
497
498
|
return undefined;
|
|
498
499
|
}
|
|
499
500
|
|
|
500
|
-
//
|
|
501
|
-
|
|
502
|
-
this.log.warn(
|
|
503
|
-
`Received checkpoint proposal with invalid feeAssetPriceModifier ${proposal.feeAssetPriceModifier} for slot ${slotNumber}`,
|
|
504
|
-
);
|
|
505
|
-
return undefined;
|
|
506
|
-
}
|
|
507
|
-
|
|
508
|
-
// Check that I have any address in current committee before attesting
|
|
509
|
-
const inCommittee = await this.epochCache.filterInCommittee(slotNumber, this.getValidatorAddresses());
|
|
501
|
+
// Check that I have any address in the committee where this checkpoint will land before attesting
|
|
502
|
+
const inCommittee = await this.epochCache.filterInCommittee(proposalSlotNumber, this.getValidatorAddresses());
|
|
510
503
|
const partOfCommittee = inCommittee.length > 0;
|
|
511
504
|
|
|
512
505
|
const proposalInfo = {
|
|
513
|
-
|
|
506
|
+
proposalSlotNumber,
|
|
514
507
|
archive: proposal.archive.toString(),
|
|
515
|
-
proposer: proposer
|
|
508
|
+
proposer: proposer?.toString(),
|
|
516
509
|
};
|
|
517
|
-
this.log.info(`Received checkpoint proposal for slot ${
|
|
510
|
+
this.log.info(`Received checkpoint proposal for slot ${proposalSlotNumber}`, {
|
|
518
511
|
...proposalInfo,
|
|
519
512
|
fishermanMode: this.config.fishermanMode || false,
|
|
520
513
|
});
|
|
521
514
|
|
|
522
|
-
// Validate the checkpoint proposal before attesting (unless skipCheckpointProposalValidation is set)
|
|
515
|
+
// Validate the checkpoint proposal before attesting (unless skipCheckpointProposalValidation is set).
|
|
516
|
+
// Uses the cached result from the all-nodes callback if available (avoids double validation).
|
|
523
517
|
if (this.config.skipCheckpointProposalValidation) {
|
|
524
|
-
this.log.warn(`Skipping checkpoint proposal validation for slot ${
|
|
518
|
+
this.log.warn(`Skipping checkpoint proposal validation for slot ${proposalSlotNumber}`, proposalInfo);
|
|
525
519
|
} else {
|
|
526
|
-
const validationResult = await this.
|
|
520
|
+
const validationResult = await this.proposalHandler.handleCheckpointProposal(proposal, proposalInfo);
|
|
527
521
|
if (!validationResult.isValid) {
|
|
528
522
|
this.log.warn(`Checkpoint proposal validation failed: ${validationResult.reason}`, proposalInfo);
|
|
529
523
|
return undefined;
|
|
530
524
|
}
|
|
531
525
|
}
|
|
532
526
|
|
|
533
|
-
// Upload blobs to filestore if we can (fire and forget)
|
|
534
|
-
if (this.blobClient.canUpload()) {
|
|
535
|
-
void this.uploadBlobsForCheckpoint(proposal, proposalInfo);
|
|
536
|
-
}
|
|
537
|
-
|
|
538
527
|
// Check that I have any address in current committee before attesting
|
|
539
528
|
// In fisherman mode, we still create attestations for validation even if not in committee
|
|
540
529
|
if (!partOfCommittee && !this.config.fishermanMode) {
|
|
@@ -543,16 +532,19 @@ export class ValidatorClient extends (EventEmitter as new () => WatcherEmitter)
|
|
|
543
532
|
}
|
|
544
533
|
|
|
545
534
|
// Provided all of the above checks pass, we can attest to the proposal
|
|
546
|
-
this.log.info(
|
|
547
|
-
|
|
548
|
-
|
|
549
|
-
|
|
550
|
-
|
|
535
|
+
this.log.info(
|
|
536
|
+
`${partOfCommittee ? 'Attesting to' : 'Validated'} checkpoint proposal for slot ${proposalSlotNumber}`,
|
|
537
|
+
{
|
|
538
|
+
...proposalInfo,
|
|
539
|
+
inCommittee: partOfCommittee,
|
|
540
|
+
fishermanMode: this.config.fishermanMode || false,
|
|
541
|
+
},
|
|
542
|
+
);
|
|
551
543
|
|
|
552
544
|
this.metrics.incSuccessfulAttestations(inCommittee.length);
|
|
553
545
|
|
|
554
546
|
// Track epoch participation per attester: count each (attester, epoch) pair at most once
|
|
555
|
-
const proposalEpoch = getEpochAtSlot(
|
|
547
|
+
const proposalEpoch = getEpochAtSlot(proposalSlotNumber, this.epochCache.getL1Constants());
|
|
556
548
|
for (const attester of inCommittee) {
|
|
557
549
|
const key = attester.toString();
|
|
558
550
|
const lastEpoch = this.lastAttestedEpochByAttester.get(key);
|
|
@@ -580,7 +572,7 @@ export class ValidatorClient extends (EventEmitter as new () => WatcherEmitter)
|
|
|
580
572
|
|
|
581
573
|
if (this.config.fishermanMode) {
|
|
582
574
|
// bail out early and don't save attestations to the pool in fisherman mode
|
|
583
|
-
this.log.info(`Creating checkpoint attestations for slot ${
|
|
575
|
+
this.log.info(`Creating checkpoint attestations for slot ${proposalSlotNumber}`, {
|
|
584
576
|
...proposalInfo,
|
|
585
577
|
attestors: attestors.map(a => a.toString()),
|
|
586
578
|
});
|
|
@@ -629,172 +621,6 @@ export class ValidatorClient extends (EventEmitter as new () => WatcherEmitter)
|
|
|
629
621
|
return attestations;
|
|
630
622
|
}
|
|
631
623
|
|
|
632
|
-
/**
|
|
633
|
-
* Validates a checkpoint proposal by building the full checkpoint and comparing it with the proposal.
|
|
634
|
-
* @returns Validation result with isValid flag and reason if invalid.
|
|
635
|
-
*/
|
|
636
|
-
private async validateCheckpointProposal(
|
|
637
|
-
proposal: CheckpointProposalCore,
|
|
638
|
-
proposalInfo: LogData,
|
|
639
|
-
): Promise<{ isValid: true } | { isValid: false; reason: string }> {
|
|
640
|
-
const slot = proposal.slotNumber;
|
|
641
|
-
|
|
642
|
-
// Timeout block syncing at the start of the next slot
|
|
643
|
-
const config = this.checkpointsBuilder.getConfig();
|
|
644
|
-
const nextSlotTimestampSeconds = Number(getTimestampForSlot(SlotNumber(slot + 1), config));
|
|
645
|
-
const timeoutSeconds = Math.max(1, nextSlotTimestampSeconds - Math.floor(this.dateProvider.now() / 1000));
|
|
646
|
-
|
|
647
|
-
// Wait for last block to sync by archive
|
|
648
|
-
let lastBlockHeader: BlockHeader | undefined;
|
|
649
|
-
try {
|
|
650
|
-
lastBlockHeader = await retryUntil(
|
|
651
|
-
async () => {
|
|
652
|
-
await this.blockSource.syncImmediate();
|
|
653
|
-
return this.blockSource.getBlockHeaderByArchive(proposal.archive);
|
|
654
|
-
},
|
|
655
|
-
`waiting for block with archive ${proposal.archive.toString()} for slot ${slot}`,
|
|
656
|
-
timeoutSeconds,
|
|
657
|
-
0.5,
|
|
658
|
-
);
|
|
659
|
-
} catch (err) {
|
|
660
|
-
if (err instanceof TimeoutError) {
|
|
661
|
-
this.log.warn(`Timed out waiting for block with archive matching checkpoint proposal`, proposalInfo);
|
|
662
|
-
return { isValid: false, reason: 'last_block_not_found' };
|
|
663
|
-
}
|
|
664
|
-
this.log.error(`Error fetching last block for checkpoint proposal`, err, proposalInfo);
|
|
665
|
-
return { isValid: false, reason: 'block_fetch_error' };
|
|
666
|
-
}
|
|
667
|
-
|
|
668
|
-
if (!lastBlockHeader) {
|
|
669
|
-
this.log.warn(`Last block not found for checkpoint proposal`, proposalInfo);
|
|
670
|
-
return { isValid: false, reason: 'last_block_not_found' };
|
|
671
|
-
}
|
|
672
|
-
|
|
673
|
-
// Get all full blocks for the slot and checkpoint
|
|
674
|
-
const blocks = await this.blockSource.getBlocksForSlot(slot);
|
|
675
|
-
if (blocks.length === 0) {
|
|
676
|
-
this.log.warn(`No blocks found for slot ${slot}`, proposalInfo);
|
|
677
|
-
return { isValid: false, reason: 'no_blocks_for_slot' };
|
|
678
|
-
}
|
|
679
|
-
|
|
680
|
-
// Ensure the last block for this slot matches the archive in the checkpoint proposal
|
|
681
|
-
if (!blocks.at(-1)?.archive.root.equals(proposal.archive)) {
|
|
682
|
-
this.log.warn(`Last block archive mismatch for checkpoint proposal`, proposalInfo);
|
|
683
|
-
return { isValid: false, reason: 'last_block_archive_mismatch' };
|
|
684
|
-
}
|
|
685
|
-
|
|
686
|
-
this.log.debug(`Found ${blocks.length} blocks for slot ${slot}`, {
|
|
687
|
-
...proposalInfo,
|
|
688
|
-
blockNumbers: blocks.map(b => b.number),
|
|
689
|
-
});
|
|
690
|
-
|
|
691
|
-
// Get checkpoint constants from first block
|
|
692
|
-
const firstBlock = blocks[0];
|
|
693
|
-
const constants = this.extractCheckpointConstants(firstBlock);
|
|
694
|
-
const checkpointNumber = firstBlock.checkpointNumber;
|
|
695
|
-
|
|
696
|
-
// Get L1-to-L2 messages for this checkpoint
|
|
697
|
-
const l1ToL2Messages = await this.l1ToL2MessageSource.getL1ToL2Messages(checkpointNumber);
|
|
698
|
-
|
|
699
|
-
// Collect the out hashes of all the checkpoints before this one in the same epoch
|
|
700
|
-
const epoch = getEpochAtSlot(slot, this.epochCache.getL1Constants());
|
|
701
|
-
const previousCheckpointOutHashes = (await this.blockSource.getCheckpointsDataForEpoch(epoch))
|
|
702
|
-
.filter(c => c.checkpointNumber < checkpointNumber)
|
|
703
|
-
.map(c => c.checkpointOutHash);
|
|
704
|
-
|
|
705
|
-
// Fork world state at the block before the first block
|
|
706
|
-
const parentBlockNumber = BlockNumber(firstBlock.number - 1);
|
|
707
|
-
const fork = await this.worldState.fork(parentBlockNumber);
|
|
708
|
-
|
|
709
|
-
try {
|
|
710
|
-
// Create checkpoint builder with all existing blocks
|
|
711
|
-
const checkpointBuilder = await this.checkpointsBuilder.openCheckpoint(
|
|
712
|
-
checkpointNumber,
|
|
713
|
-
constants,
|
|
714
|
-
proposal.feeAssetPriceModifier,
|
|
715
|
-
l1ToL2Messages,
|
|
716
|
-
previousCheckpointOutHashes,
|
|
717
|
-
fork,
|
|
718
|
-
blocks,
|
|
719
|
-
this.log.getBindings(),
|
|
720
|
-
);
|
|
721
|
-
|
|
722
|
-
// Complete the checkpoint to get computed values
|
|
723
|
-
const computedCheckpoint = await checkpointBuilder.completeCheckpoint();
|
|
724
|
-
|
|
725
|
-
// Compare checkpoint header with proposal
|
|
726
|
-
if (!computedCheckpoint.header.equals(proposal.checkpointHeader)) {
|
|
727
|
-
this.log.warn(`Checkpoint header mismatch`, {
|
|
728
|
-
...proposalInfo,
|
|
729
|
-
computed: computedCheckpoint.header.toInspect(),
|
|
730
|
-
proposal: proposal.checkpointHeader.toInspect(),
|
|
731
|
-
});
|
|
732
|
-
return { isValid: false, reason: 'checkpoint_header_mismatch' };
|
|
733
|
-
}
|
|
734
|
-
|
|
735
|
-
// Compare archive root with proposal
|
|
736
|
-
if (!computedCheckpoint.archive.root.equals(proposal.archive)) {
|
|
737
|
-
this.log.warn(`Archive root mismatch`, {
|
|
738
|
-
...proposalInfo,
|
|
739
|
-
computed: computedCheckpoint.archive.root.toString(),
|
|
740
|
-
proposal: proposal.archive.toString(),
|
|
741
|
-
});
|
|
742
|
-
return { isValid: false, reason: 'archive_mismatch' };
|
|
743
|
-
}
|
|
744
|
-
|
|
745
|
-
// Check that the accumulated epoch out hash matches the value in the proposal.
|
|
746
|
-
// The epoch out hash is the accumulated hash of all checkpoint out hashes in the epoch.
|
|
747
|
-
const checkpointOutHash = computedCheckpoint.getCheckpointOutHash();
|
|
748
|
-
const computedEpochOutHash = accumulateCheckpointOutHashes([...previousCheckpointOutHashes, checkpointOutHash]);
|
|
749
|
-
const proposalEpochOutHash = proposal.checkpointHeader.epochOutHash;
|
|
750
|
-
if (!computedEpochOutHash.equals(proposalEpochOutHash)) {
|
|
751
|
-
this.log.warn(`Epoch out hash mismatch`, {
|
|
752
|
-
proposalEpochOutHash: proposalEpochOutHash.toString(),
|
|
753
|
-
computedEpochOutHash: computedEpochOutHash.toString(),
|
|
754
|
-
checkpointOutHash: checkpointOutHash.toString(),
|
|
755
|
-
previousCheckpointOutHashes: previousCheckpointOutHashes.map(h => h.toString()),
|
|
756
|
-
...proposalInfo,
|
|
757
|
-
});
|
|
758
|
-
return { isValid: false, reason: 'out_hash_mismatch' };
|
|
759
|
-
}
|
|
760
|
-
|
|
761
|
-
// Final round of validations on the checkpoint, just in case.
|
|
762
|
-
try {
|
|
763
|
-
validateCheckpoint(computedCheckpoint, {
|
|
764
|
-
rollupManaLimit: this.checkpointsBuilder.getConfig().rollupManaLimit,
|
|
765
|
-
maxDABlockGas: this.config.validateMaxDABlockGas,
|
|
766
|
-
maxL2BlockGas: this.config.validateMaxL2BlockGas,
|
|
767
|
-
maxTxsPerBlock: this.config.validateMaxTxsPerBlock,
|
|
768
|
-
maxTxsPerCheckpoint: this.config.validateMaxTxsPerCheckpoint,
|
|
769
|
-
});
|
|
770
|
-
} catch (err) {
|
|
771
|
-
this.log.warn(`Checkpoint validation failed: ${err}`, proposalInfo);
|
|
772
|
-
return { isValid: false, reason: 'checkpoint_validation_failed' };
|
|
773
|
-
}
|
|
774
|
-
|
|
775
|
-
this.log.verbose(`Checkpoint proposal validation successful for slot ${slot}`, proposalInfo);
|
|
776
|
-
return { isValid: true };
|
|
777
|
-
} finally {
|
|
778
|
-
await fork.close();
|
|
779
|
-
}
|
|
780
|
-
}
|
|
781
|
-
|
|
782
|
-
/**
|
|
783
|
-
* Extract checkpoint global variables from a block.
|
|
784
|
-
*/
|
|
785
|
-
private extractCheckpointConstants(block: L2Block): CheckpointGlobalVariables {
|
|
786
|
-
const gv = block.header.globalVariables;
|
|
787
|
-
return {
|
|
788
|
-
chainId: gv.chainId,
|
|
789
|
-
version: gv.version,
|
|
790
|
-
slotNumber: gv.slotNumber,
|
|
791
|
-
timestamp: gv.timestamp,
|
|
792
|
-
coinbase: gv.coinbase,
|
|
793
|
-
feeRecipient: gv.feeRecipient,
|
|
794
|
-
gasFees: gv.gasFees,
|
|
795
|
-
};
|
|
796
|
-
}
|
|
797
|
-
|
|
798
624
|
/**
|
|
799
625
|
* Uploads blobs for a checkpoint to the filestore (fire and forget).
|
|
800
626
|
*/
|
|
@@ -1,63 +0,0 @@
|
|
|
1
|
-
import type { EpochCache } from '@aztec/epoch-cache';
|
|
2
|
-
import { BlockNumber, CheckpointNumber } from '@aztec/foundation/branded-types';
|
|
3
|
-
import { Fr } from '@aztec/foundation/curves/bn254';
|
|
4
|
-
import { DateProvider } from '@aztec/foundation/timer';
|
|
5
|
-
import type { P2P, PeerId } from '@aztec/p2p';
|
|
6
|
-
import { BlockProposalValidator } from '@aztec/p2p/msg_validators';
|
|
7
|
-
import type { L2Block, L2BlockSink, L2BlockSource } from '@aztec/stdlib/block';
|
|
8
|
-
import type { ITxProvider, ValidatorClientFullConfig, WorldStateSynchronizer } from '@aztec/stdlib/interfaces/server';
|
|
9
|
-
import { type L1ToL2MessageSource } from '@aztec/stdlib/messaging';
|
|
10
|
-
import type { BlockProposal } from '@aztec/stdlib/p2p';
|
|
11
|
-
import type { FailedTx, Tx } from '@aztec/stdlib/tx';
|
|
12
|
-
import { type TelemetryClient, type Tracer } from '@aztec/telemetry-client';
|
|
13
|
-
import type { FullNodeCheckpointsBuilder } from './checkpoint_builder.js';
|
|
14
|
-
import type { ValidatorMetrics } from './metrics.js';
|
|
15
|
-
export type BlockProposalValidationFailureReason = 'invalid_proposal' | 'parent_block_not_found' | 'parent_block_wrong_slot' | 'in_hash_mismatch' | 'global_variables_mismatch' | 'block_number_already_exists' | 'txs_not_available' | 'state_mismatch' | 'failed_txs' | 'timeout' | 'unknown_error';
|
|
16
|
-
type ReexecuteTransactionsResult = {
|
|
17
|
-
block: L2Block;
|
|
18
|
-
failedTxs: FailedTx[];
|
|
19
|
-
reexecutionTimeMs: number;
|
|
20
|
-
totalManaUsed: number;
|
|
21
|
-
};
|
|
22
|
-
export type BlockProposalValidationSuccessResult = {
|
|
23
|
-
isValid: true;
|
|
24
|
-
blockNumber: BlockNumber;
|
|
25
|
-
reexecutionResult?: ReexecuteTransactionsResult;
|
|
26
|
-
};
|
|
27
|
-
export type BlockProposalValidationFailureResult = {
|
|
28
|
-
isValid: false;
|
|
29
|
-
reason: BlockProposalValidationFailureReason;
|
|
30
|
-
blockNumber?: BlockNumber;
|
|
31
|
-
reexecutionResult?: ReexecuteTransactionsResult;
|
|
32
|
-
};
|
|
33
|
-
export type BlockProposalValidationResult = BlockProposalValidationSuccessResult | BlockProposalValidationFailureResult;
|
|
34
|
-
export declare class BlockProposalHandler {
|
|
35
|
-
private checkpointsBuilder;
|
|
36
|
-
private worldState;
|
|
37
|
-
private blockSource;
|
|
38
|
-
private l1ToL2MessageSource;
|
|
39
|
-
private txProvider;
|
|
40
|
-
private blockProposalValidator;
|
|
41
|
-
private epochCache;
|
|
42
|
-
private config;
|
|
43
|
-
private metrics?;
|
|
44
|
-
private dateProvider;
|
|
45
|
-
private log;
|
|
46
|
-
readonly tracer: Tracer;
|
|
47
|
-
constructor(checkpointsBuilder: FullNodeCheckpointsBuilder, worldState: WorldStateSynchronizer, blockSource: L2BlockSource & L2BlockSink, l1ToL2MessageSource: L1ToL2MessageSource, txProvider: ITxProvider, blockProposalValidator: BlockProposalValidator, epochCache: EpochCache, config: ValidatorClientFullConfig, metrics?: ValidatorMetrics | undefined, dateProvider?: DateProvider, telemetry?: TelemetryClient, log?: import("@aztec/foundation/log").Logger);
|
|
48
|
-
register(p2pClient: P2P, shouldReexecute: boolean): BlockProposalHandler;
|
|
49
|
-
handleBlockProposal(proposal: BlockProposal, proposalSender: PeerId, shouldReexecute: boolean): Promise<BlockProposalValidationResult>;
|
|
50
|
-
private getParentBlock;
|
|
51
|
-
private computeCheckpointNumber;
|
|
52
|
-
/**
|
|
53
|
-
* Validates that a non-first block in a checkpoint has consistent global variables with its parent.
|
|
54
|
-
* For blocks with indexWithinCheckpoint > 0, all global variables except blockNumber must match the parent.
|
|
55
|
-
* @returns A failure result if validation fails, undefined if validation passes
|
|
56
|
-
*/
|
|
57
|
-
private validateNonFirstBlockInCheckpoint;
|
|
58
|
-
private getReexecutionDeadline;
|
|
59
|
-
private getReexecuteFailureReason;
|
|
60
|
-
reexecuteTransactions(proposal: BlockProposal, blockNumber: BlockNumber, checkpointNumber: CheckpointNumber, txs: Tx[], l1ToL2Messages: Fr[], previousCheckpointOutHashes: Fr[]): Promise<ReexecuteTransactionsResult>;
|
|
61
|
-
}
|
|
62
|
-
export {};
|
|
63
|
-
//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiYmxvY2tfcHJvcG9zYWxfaGFuZGxlci5kLnRzIiwic291cmNlUm9vdCI6IiIsInNvdXJjZXMiOlsiLi4vc3JjL2Jsb2NrX3Byb3Bvc2FsX2hhbmRsZXIudHMiXSwibmFtZXMiOltdLCJtYX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