@aztec/foundation 0.0.1-commit.9b94fc1 → 0.0.1-commit.c7c42ec
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/dest/array/index.d.ts +2 -1
- package/dest/array/index.d.ts.map +1 -1
- package/dest/array/index.js +1 -0
- package/dest/array/sorted_array.d.ts +10 -0
- package/dest/array/sorted_array.d.ts.map +1 -0
- package/dest/array/sorted_array.js +106 -0
- package/dest/branded-types/block_number.d.ts +53 -0
- package/dest/branded-types/block_number.d.ts.map +1 -0
- package/dest/branded-types/block_number.js +75 -0
- package/dest/branded-types/checkpoint_number.d.ts +46 -0
- package/dest/branded-types/checkpoint_number.d.ts.map +1 -0
- package/dest/branded-types/checkpoint_number.js +68 -0
- package/dest/branded-types/index.d.ts +3 -1
- package/dest/branded-types/index.d.ts.map +1 -1
- package/dest/branded-types/index.js +2 -0
- package/dest/buffer/buffer16.d.ts +2 -2
- package/dest/buffer/buffer16.d.ts.map +1 -1
- package/dest/buffer/buffer16.js +1 -1
- package/dest/buffer/buffer32.d.ts +2 -2
- package/dest/buffer/buffer32.d.ts.map +1 -1
- package/dest/buffer/buffer32.js +1 -1
- package/dest/config/env_var.d.ts +2 -2
- package/dest/config/env_var.d.ts.map +1 -1
- package/dest/config/index.d.ts +10 -2
- package/dest/config/index.d.ts.map +1 -1
- package/dest/config/index.js +16 -2
- package/dest/config/network_config.d.ts +13 -1
- package/dest/config/network_config.d.ts.map +1 -1
- package/dest/config/network_config.js +3 -1
- package/dest/crypto/bls/bn254_keystore.js +1 -1
- package/dest/crypto/bls/index.js +1 -1
- package/dest/crypto/bn254/index.d.ts +35 -51
- package/dest/crypto/bn254/index.d.ts.map +1 -1
- package/dest/crypto/bn254/index.js +51 -140
- package/dest/crypto/ecdsa/signature.d.ts +2 -2
- package/dest/crypto/ecdsa/signature.d.ts.map +1 -1
- package/dest/crypto/ecdsa/signature.js +2 -2
- package/dest/crypto/grumpkin/index.d.ts +4 -2
- package/dest/crypto/grumpkin/index.d.ts.map +1 -1
- package/dest/crypto/grumpkin/index.js +2 -1
- package/dest/crypto/keys/index.d.ts +2 -2
- package/dest/crypto/keys/index.d.ts.map +1 -1
- package/dest/crypto/keys/index.js +1 -1
- package/dest/crypto/pedersen/pedersen.wasm.d.ts +2 -2
- package/dest/crypto/pedersen/pedersen.wasm.d.ts.map +1 -1
- package/dest/crypto/pedersen/pedersen.wasm.js +1 -1
- package/dest/crypto/poseidon/index.d.ts +2 -2
- package/dest/crypto/poseidon/index.d.ts.map +1 -1
- package/dest/crypto/poseidon/index.js +1 -1
- package/dest/crypto/schnorr/index.d.ts +3 -2
- package/dest/crypto/schnorr/index.d.ts.map +1 -1
- package/dest/crypto/schnorr/index.js +1 -1
- package/dest/crypto/schnorr/signature.d.ts +2 -2
- package/dest/crypto/schnorr/signature.d.ts.map +1 -1
- package/dest/crypto/schnorr/signature.js +2 -2
- package/dest/crypto/sha256/index.d.ts +2 -2
- package/dest/crypto/sha256/index.d.ts.map +1 -1
- package/dest/crypto/sha256/index.js +1 -1
- package/dest/crypto/sha512/index.d.ts +2 -2
- package/dest/crypto/sha512/index.d.ts.map +1 -1
- package/dest/crypto/sha512/index.js +1 -1
- package/dest/crypto/signature/index.d.ts +2 -2
- package/dest/crypto/signature/index.d.ts.map +1 -1
- package/dest/crypto/sync/pedersen/index.d.ts +2 -2
- package/dest/crypto/sync/pedersen/index.d.ts.map +1 -1
- package/dest/crypto/sync/pedersen/index.js +1 -1
- package/dest/crypto/sync/poseidon/index.d.ts +2 -2
- package/dest/crypto/sync/poseidon/index.d.ts.map +1 -1
- package/dest/crypto/sync/poseidon/index.js +1 -1
- package/dest/{fields/bls12_fields.d.ts → curves/bls12/field.d.ts} +3 -3
- package/dest/curves/bls12/field.d.ts.map +1 -0
- package/dest/{fields/bls12_fields.js → curves/bls12/field.js} +6 -6
- package/dest/curves/bls12/index.d.ts +3 -0
- package/dest/curves/bls12/index.d.ts.map +1 -0
- package/dest/curves/bls12/index.js +2 -0
- package/dest/{fields/bls12_point.d.ts → curves/bls12/point.d.ts} +4 -4
- package/dest/curves/bls12/point.d.ts.map +1 -0
- package/dest/{fields/bls12_point.js → curves/bls12/point.js} +7 -7
- package/dest/{fields/fields.d.ts → curves/bn254/field.d.ts} +7 -15
- package/dest/curves/bn254/field.d.ts.map +1 -0
- package/dest/{fields/fields.js → curves/bn254/field.js} +30 -47
- package/dest/curves/bn254/index.d.ts +3 -0
- package/dest/curves/bn254/index.d.ts.map +1 -0
- package/dest/curves/bn254/index.js +2 -0
- package/dest/curves/bn254/point.d.ts +54 -0
- package/dest/curves/bn254/point.d.ts.map +1 -0
- package/dest/curves/bn254/point.js +143 -0
- package/dest/curves/grumpkin/index.d.ts +10 -0
- package/dest/curves/grumpkin/index.d.ts.map +1 -0
- package/dest/curves/grumpkin/index.js +3 -0
- package/dest/{fields → curves/grumpkin}/point.d.ts +3 -3
- package/dest/curves/grumpkin/point.d.ts.map +1 -0
- package/dest/{fields → curves/grumpkin}/point.js +7 -7
- package/dest/eth-address/index.d.ts +3 -2
- package/dest/eth-address/index.d.ts.map +1 -1
- package/dest/eth-address/index.js +6 -1
- package/dest/iterator/filter.d.ts +3 -0
- package/dest/iterator/filter.d.ts.map +1 -0
- package/dest/iterator/filter.js +7 -0
- package/dest/iterator/index.d.ts +2 -0
- package/dest/iterator/index.d.ts.map +1 -0
- package/dest/iterator/index.js +1 -0
- package/dest/schemas/schemas.d.ts +7 -3
- package/dest/schemas/schemas.d.ts.map +1 -1
- package/dest/schemas/schemas.js +9 -3
- package/dest/schemas/types.d.ts +31 -1
- package/dest/schemas/types.d.ts.map +1 -1
- package/dest/schemas/types.js +25 -1
- package/dest/serialize/field_reader.d.ts +2 -2
- package/dest/serialize/field_reader.d.ts.map +1 -1
- package/dest/serialize/field_reader.js +1 -1
- package/dest/serialize/free_funcs.d.ts +2 -2
- package/dest/serialize/free_funcs.d.ts.map +1 -1
- package/dest/serialize/free_funcs.js +1 -1
- package/dest/serialize/serialize.d.ts +2 -2
- package/dest/serialize/serialize.d.ts.map +1 -1
- package/dest/serialize/serialize.js +1 -1
- package/dest/sleep/index.d.ts +3 -1
- package/dest/sleep/index.d.ts.map +1 -1
- package/dest/sleep/index.js +4 -0
- package/dest/timer/date.d.ts +2 -1
- package/dest/timer/date.d.ts.map +1 -1
- package/dest/timer/date.js +3 -0
- package/dest/trees/balanced_merkle_tree.d.ts +1 -1
- package/dest/trees/balanced_merkle_tree.d.ts.map +1 -1
- package/dest/trees/balanced_merkle_tree.js +3 -1
- package/dest/trees/indexed_merkle_tree.js +1 -1
- package/dest/trees/membership_witness.d.ts +2 -2
- package/dest/trees/membership_witness.d.ts.map +1 -1
- package/dest/trees/membership_witness.js +1 -1
- package/dest/trees/merkle_tree_calculator.js +1 -1
- package/dest/trees/sibling_path.d.ts +2 -2
- package/dest/trees/sibling_path.d.ts.map +1 -1
- package/dest/trees/sibling_path.js +2 -2
- package/dest/types/index.d.ts +3 -1
- package/dest/types/index.d.ts.map +1 -1
- package/dest/types/index.js +3 -0
- package/package.json +25 -7
- package/src/array/index.ts +1 -0
- package/src/array/sorted_array.ts +133 -0
- package/src/branded-types/block_number.ts +112 -0
- package/src/branded-types/checkpoint_number.ts +100 -0
- package/src/branded-types/index.ts +2 -0
- package/src/buffer/buffer16.ts +2 -2
- package/src/buffer/buffer32.ts +2 -2
- package/src/config/env_var.ts +16 -6
- package/src/config/index.ts +20 -2
- package/src/config/network_config.ts +2 -0
- package/src/crypto/bls/bn254_keystore.ts +1 -1
- package/src/crypto/bls/index.ts +1 -1
- package/src/crypto/bn254/index.ts +50 -159
- package/src/crypto/ecdsa/signature.ts +2 -2
- package/src/crypto/grumpkin/index.ts +3 -1
- package/src/crypto/keys/index.ts +1 -1
- package/src/crypto/pedersen/pedersen.wasm.ts +1 -1
- package/src/crypto/poseidon/index.ts +1 -1
- package/src/crypto/schnorr/index.ts +2 -1
- package/src/crypto/schnorr/signature.ts +2 -2
- package/src/crypto/sha256/index.ts +1 -1
- package/src/crypto/sha512/index.ts +1 -1
- package/src/crypto/signature/index.ts +1 -1
- package/src/crypto/sync/pedersen/index.ts +1 -1
- package/src/crypto/sync/poseidon/index.ts +1 -1
- package/src/{fields/bls12_fields.ts → curves/bls12/field.ts} +6 -6
- package/src/curves/bls12/index.ts +2 -0
- package/src/{fields/bls12_point.ts → curves/bls12/point.ts} +7 -7
- package/src/{fields/fields.ts → curves/bn254/field.ts} +33 -56
- package/src/curves/bn254/index.ts +2 -0
- package/src/curves/bn254/point.ts +170 -0
- package/src/curves/grumpkin/index.ts +11 -0
- package/src/{fields → curves/grumpkin}/point.ts +7 -7
- package/src/eth-address/index.ts +7 -1
- package/src/iterator/filter.ts +11 -0
- package/src/iterator/index.ts +1 -0
- package/src/schemas/schemas.ts +14 -3
- package/src/schemas/types.ts +33 -0
- package/src/serialize/field_reader.ts +1 -1
- package/src/serialize/free_funcs.ts +1 -1
- package/src/serialize/serialize.ts +1 -1
- package/src/sleep/index.ts +6 -0
- package/src/timer/date.ts +4 -0
- package/src/trees/balanced_merkle_tree.ts +3 -1
- package/src/trees/indexed_merkle_tree.ts +1 -1
- package/src/trees/membership_witness.ts +1 -1
- package/src/trees/merkle_tree_calculator.ts +1 -1
- package/src/trees/sibling_path.ts +2 -2
- package/src/types/index.ts +5 -0
- package/dest/crypto/bn254/bn254_utils.d.ts +0 -39
- package/dest/crypto/bn254/bn254_utils.d.ts.map +0 -1
- package/dest/crypto/bn254/bn254_utils.js +0 -56
- package/dest/crypto/index.d.ts +0 -17
- package/dest/crypto/index.d.ts.map +0 -1
- package/dest/crypto/index.js +0 -16
- package/dest/fields/bls12_fields.d.ts.map +0 -1
- package/dest/fields/bls12_point.d.ts.map +0 -1
- package/dest/fields/coordinate.d.ts +0 -63
- package/dest/fields/coordinate.d.ts.map +0 -1
- package/dest/fields/coordinate.js +0 -96
- package/dest/fields/fields.d.ts.map +0 -1
- package/dest/fields/index.d.ts +0 -6
- package/dest/fields/index.d.ts.map +0 -1
- package/dest/fields/index.js +0 -5
- package/dest/fields/point.d.ts.map +0 -1
- package/dest/index.d.ts +0 -31
- package/dest/index.d.ts.map +0 -1
- package/dest/index.js +0 -31
- package/src/crypto/bn254/bn254_utils.ts +0 -64
- package/src/crypto/index.ts +0 -16
- package/src/fields/coordinate.ts +0 -104
- package/src/fields/index.ts +0 -5
- package/src/index.ts +0 -31
|
@@ -0,0 +1,100 @@
|
|
|
1
|
+
import { z } from 'zod';
|
|
2
|
+
|
|
3
|
+
import type { BlockNumber } from './block_number.js';
|
|
4
|
+
import type { Branded } from './types.js';
|
|
5
|
+
|
|
6
|
+
/**
|
|
7
|
+
* A branded type representing an checkpoint number.
|
|
8
|
+
* Checkpoints are used in the Aztec protocol to group L2 blocks.
|
|
9
|
+
*
|
|
10
|
+
* This is a nominal type backed by a number, but TypeScript will treat it as
|
|
11
|
+
* incompatible with plain numbers and other branded numeric types (like Slot, BlockNumber, etc.).
|
|
12
|
+
*
|
|
13
|
+
* @example
|
|
14
|
+
* ```ts
|
|
15
|
+
* const checkpoint = CheckpointNumber(5);
|
|
16
|
+
* const plainNumber: number = checkpoint; // OK - CheckpointNumber is assignable to number
|
|
17
|
+
* const checkpointFromNumber: CheckpointNumber = 5; // ERROR - number is not assignable to CheckpointNumber
|
|
18
|
+
* ```
|
|
19
|
+
*/
|
|
20
|
+
export type CheckpointNumber = Branded<number, 'CheckpointNumber'>;
|
|
21
|
+
|
|
22
|
+
/**
|
|
23
|
+
* Creates an CheckpointNumber from a number.
|
|
24
|
+
* @param value - The checkpoint number (must be a non-negative integer)
|
|
25
|
+
* @returns The branded CheckpointNumber value
|
|
26
|
+
* @throws If the value is negative or not an integer
|
|
27
|
+
*/
|
|
28
|
+
export function CheckpointNumber(value: number): CheckpointNumber {
|
|
29
|
+
if (!Number.isInteger(value)) {
|
|
30
|
+
throw new Error(`CheckpointNumber must be an integer, got ${value}`);
|
|
31
|
+
}
|
|
32
|
+
if (value < 0) {
|
|
33
|
+
throw new Error(`CheckpointNumber must be non-negative, got ${value}`);
|
|
34
|
+
}
|
|
35
|
+
return value as CheckpointNumber;
|
|
36
|
+
}
|
|
37
|
+
|
|
38
|
+
/**
|
|
39
|
+
* @param value - The block number
|
|
40
|
+
* @returns The branded CheckpointNumber value
|
|
41
|
+
*
|
|
42
|
+
* @deprecated Checkpoint number and block number should no longer convert to each other once we support multiple blocks
|
|
43
|
+
* per checkpoint everywhere.
|
|
44
|
+
*/
|
|
45
|
+
CheckpointNumber.fromBlockNumber = function (value: BlockNumber): CheckpointNumber {
|
|
46
|
+
return CheckpointNumber(value);
|
|
47
|
+
};
|
|
48
|
+
|
|
49
|
+
/**
|
|
50
|
+
* Creates an CheckpointNumber from a bigint.
|
|
51
|
+
* @param value - The checkpoint number as bigint (must be a non-negative integer within safe integer range)
|
|
52
|
+
* @returns The branded CheckpointNumber value
|
|
53
|
+
* @throws If the value is negative or exceeds Number.MAX_SAFE_INTEGER
|
|
54
|
+
*/
|
|
55
|
+
CheckpointNumber.fromBigInt = function (value: bigint): CheckpointNumber {
|
|
56
|
+
if (value < 0n) {
|
|
57
|
+
throw new Error(`CheckpointNumber must be non-negative, got ${value}`);
|
|
58
|
+
}
|
|
59
|
+
if (value > BigInt(Number.MAX_SAFE_INTEGER)) {
|
|
60
|
+
throw new Error(`CheckpointNumber ${value} exceeds MAX_SAFE_INTEGER`);
|
|
61
|
+
}
|
|
62
|
+
return Number(value) as CheckpointNumber;
|
|
63
|
+
};
|
|
64
|
+
|
|
65
|
+
/**
|
|
66
|
+
* Creates an CheckpointNumber from a string.
|
|
67
|
+
* @param value - The checkpoint number as a string
|
|
68
|
+
* @returns The branded CheckpointNumber value
|
|
69
|
+
* @throws If the string cannot be parsed as a valid checkpoint
|
|
70
|
+
*/
|
|
71
|
+
CheckpointNumber.fromString = function (value: string): CheckpointNumber {
|
|
72
|
+
const parsed = parseInt(value, 10);
|
|
73
|
+
if (isNaN(parsed)) {
|
|
74
|
+
throw new Error(`Cannot parse CheckpointNumber from string: ${value}`);
|
|
75
|
+
}
|
|
76
|
+
return CheckpointNumber(parsed);
|
|
77
|
+
};
|
|
78
|
+
|
|
79
|
+
/**
|
|
80
|
+
* Type guard to check if a value is a valid CheckpointNumber.
|
|
81
|
+
* Note: At runtime, an CheckpointNumber is just a number, so this checks if the value
|
|
82
|
+
* is a non-negative integer.
|
|
83
|
+
*/
|
|
84
|
+
CheckpointNumber.isValid = function (value: unknown): value is CheckpointNumber {
|
|
85
|
+
return typeof value === 'number' && Number.isInteger(value) && value >= 0;
|
|
86
|
+
};
|
|
87
|
+
|
|
88
|
+
/**
|
|
89
|
+
* The zero checkpoint value.
|
|
90
|
+
*/
|
|
91
|
+
CheckpointNumber.ZERO = CheckpointNumber(0);
|
|
92
|
+
|
|
93
|
+
/**
|
|
94
|
+
* Zod schema for parsing and validating CheckpointNumber values.
|
|
95
|
+
* Accepts numbers, bigints, or strings and coerces them to CheckpointNumber.
|
|
96
|
+
*/
|
|
97
|
+
export const CheckpointNumberSchema = z
|
|
98
|
+
.union([z.number(), z.bigint(), z.string()])
|
|
99
|
+
.pipe(z.coerce.number().int().min(0))
|
|
100
|
+
.transform(value => CheckpointNumber(value));
|
|
@@ -1,3 +1,5 @@
|
|
|
1
|
+
export { BlockNumber, BlockNumberSchema, BlockNumberPositiveSchema } from './block_number.js';
|
|
2
|
+
export { CheckpointNumber, CheckpointNumberSchema } from './checkpoint_number.js';
|
|
1
3
|
export { EpochNumber, EpochNumberSchema } from './epoch.js';
|
|
2
4
|
export { SlotNumber, SlotNumberSchema } from './slot.js';
|
|
3
5
|
|
package/src/buffer/buffer16.ts
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { randomBytes } from '@aztec/foundation/crypto';
|
|
2
|
-
import type { Fr } from '@aztec/foundation/
|
|
1
|
+
import { randomBytes } from '@aztec/foundation/crypto/random';
|
|
2
|
+
import type { Fr } from '@aztec/foundation/curves/bn254';
|
|
3
3
|
import { BufferReader, deserializeBigInt, serializeBigInt } from '@aztec/foundation/serialize';
|
|
4
4
|
|
|
5
5
|
import { inspect } from 'util';
|
package/src/buffer/buffer32.ts
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { randomBytes } from '@aztec/foundation/crypto';
|
|
2
|
-
import type { Fr } from '@aztec/foundation/
|
|
1
|
+
import { randomBytes } from '@aztec/foundation/crypto/random';
|
|
2
|
+
import type { Fr } from '@aztec/foundation/curves/bn254';
|
|
3
3
|
import { BufferReader, deserializeBigInt, serializeBigInt } from '@aztec/foundation/serialize';
|
|
4
4
|
|
|
5
5
|
import { inspect } from 'util';
|
package/src/config/env_var.ts
CHANGED
|
@@ -24,6 +24,9 @@ export type EnvVar =
|
|
|
24
24
|
| 'BLOB_SINK_ARCHIVE_API_URL'
|
|
25
25
|
| 'BLOB_SINK_PORT'
|
|
26
26
|
| 'BLOB_SINK_URL'
|
|
27
|
+
| 'BLOB_FILE_STORE_URLS'
|
|
28
|
+
| 'BLOB_FILE_STORE_UPLOAD_URL'
|
|
29
|
+
| 'BLOB_HEALTHCHECK_UPLOAD_INTERVAL_MINUTES'
|
|
27
30
|
| 'BOT_DA_GAS_LIMIT'
|
|
28
31
|
| 'BOT_FEE_PAYMENT_METHOD'
|
|
29
32
|
| 'BOT_BASE_FEE_PADDING'
|
|
@@ -63,8 +66,9 @@ export type EnvVar =
|
|
|
63
66
|
| 'PUBLIC_DATA_TREE_MAP_SIZE_KB'
|
|
64
67
|
| 'DEBUG'
|
|
65
68
|
| 'DEBUG_P2P_DISABLE_COLOCATION_PENALTY'
|
|
66
|
-
| 'DEPLOY_AZTEC_CONTRACTS_SALT'
|
|
67
69
|
| 'ETHEREUM_HOSTS'
|
|
70
|
+
| 'ETHEREUM_DEBUG_HOSTS'
|
|
71
|
+
| 'ETHEREUM_ALLOW_NO_DEBUG_HOSTS'
|
|
68
72
|
| 'FEE_RECIPIENT'
|
|
69
73
|
| 'FORCE_COLOR'
|
|
70
74
|
| 'GOVERNANCE_PROPOSER_PAYLOAD_ADDRESS'
|
|
@@ -131,8 +135,7 @@ export type EnvVar =
|
|
|
131
135
|
| 'P2P_TRUSTED_PEERS'
|
|
132
136
|
| 'P2P_PRIVATE_PEERS'
|
|
133
137
|
| 'P2P_PREFERRED_PEERS'
|
|
134
|
-
| '
|
|
135
|
-
| 'P2P_TX_POOL_OVERFLOW_FACTOR'
|
|
138
|
+
| 'P2P_MAX_PENDING_TX_COUNT'
|
|
136
139
|
| 'P2P_SEEN_MSG_CACHE_SIZE'
|
|
137
140
|
| 'P2P_DROP_TX'
|
|
138
141
|
| 'P2P_DROP_TX_CHANCE'
|
|
@@ -166,6 +169,7 @@ export type EnvVar =
|
|
|
166
169
|
| 'PROVER_PUBLISHER_PRIVATE_KEYS'
|
|
167
170
|
| 'PROVER_PUBLISHER_ADDRESSES'
|
|
168
171
|
| 'PROVER_PUBLISHER_ALLOW_INVALID_STATES'
|
|
172
|
+
| 'PROVER_PUBLISHER_FORWARDER_ADDRESS'
|
|
169
173
|
| 'PROVER_REAL_PROOFS'
|
|
170
174
|
| 'PROVER_TEST_DELAY_FACTOR'
|
|
171
175
|
| 'PROVER_TEST_DELAY_MS'
|
|
@@ -190,10 +194,13 @@ export type EnvVar =
|
|
|
190
194
|
| 'SEQ_PUBLISHER_PRIVATE_KEYS'
|
|
191
195
|
| 'SEQ_PUBLISHER_ADDRESSES'
|
|
192
196
|
| 'SEQ_PUBLISHER_ALLOW_INVALID_STATES'
|
|
193
|
-
| '
|
|
197
|
+
| 'SEQ_PUBLISHER_FORWARDER_ADDRESS'
|
|
198
|
+
| 'SEQ_POLLING_INTERVAL_MS'
|
|
194
199
|
| 'SEQ_ENFORCE_TIME_TABLE'
|
|
195
|
-
| '
|
|
200
|
+
| 'SEQ_L1_PUBLISHING_TIME_ALLOWANCE_IN_SLOT'
|
|
196
201
|
| 'SEQ_ATTESTATION_PROPAGATION_TIME'
|
|
202
|
+
| 'SEQ_BLOCK_DURATION_MS'
|
|
203
|
+
| 'SEQ_BUILD_CHECKPOINT_IF_EMPTY'
|
|
197
204
|
| 'SEQ_SECONDS_BEFORE_INVALIDATING_BLOCK_AS_COMMITTEE_MEMBER'
|
|
198
205
|
| 'SEQ_SECONDS_BEFORE_INVALIDATING_BLOCK_AS_NON_COMMITTEE_MEMBER'
|
|
199
206
|
| 'SLASH_MIN_PENALTY_PERCENTAGE'
|
|
@@ -252,6 +259,7 @@ export type EnvVar =
|
|
|
252
259
|
| 'AZTEC_TARGET_COMMITTEE_SIZE'
|
|
253
260
|
| 'AZTEC_LAG_IN_EPOCHS_FOR_VALIDATOR_SET'
|
|
254
261
|
| 'AZTEC_LAG_IN_EPOCHS_FOR_RANDAO'
|
|
262
|
+
| 'AZTEC_INBOX_LAG'
|
|
255
263
|
| 'AZTEC_PROOF_SUBMISSION_EPOCHS'
|
|
256
264
|
| 'AZTEC_ACTIVATION_THRESHOLD'
|
|
257
265
|
| 'AZTEC_EJECTION_THRESHOLD'
|
|
@@ -279,6 +287,7 @@ export type EnvVar =
|
|
|
279
287
|
| 'L1_BLOB_FEE_PER_GAS_GWEI_MAX'
|
|
280
288
|
| 'L1_PRIORITY_FEE_BUMP_PERCENTAGE'
|
|
281
289
|
| 'L1_PRIORITY_FEE_RETRY_BUMP_PERCENTAGE'
|
|
290
|
+
| 'L1_MINIMUM_PRIORITY_FEE_PER_GAS_GWEI'
|
|
282
291
|
| 'L1_FIXED_PRIORITY_FEE_PER_GAS'
|
|
283
292
|
| 'L1_FIXED_PRIORITY_FEE_PER_GAS_GWEI'
|
|
284
293
|
| 'L1_TX_MONITOR_MAX_ATTEMPTS'
|
|
@@ -304,4 +313,5 @@ export type EnvVar =
|
|
|
304
313
|
| 'BLOB_ALLOW_EMPTY_SOURCES'
|
|
305
314
|
| 'FISHERMAN_MODE'
|
|
306
315
|
| 'MAX_ALLOWED_ETH_CLIENT_DRIFT_SECONDS'
|
|
307
|
-
| 'LEGACY_BLS_CLI'
|
|
316
|
+
| 'LEGACY_BLS_CLI'
|
|
317
|
+
| 'DEBUG_FORCE_TX_PROOF_VERIFICATION';
|
package/src/config/index.ts
CHANGED
|
@@ -1,4 +1,5 @@
|
|
|
1
|
-
import { Fq, Fr } from '../
|
|
1
|
+
import { Fq, Fr } from '../curves/bn254/field.js';
|
|
2
|
+
import { createConsoleLogger } from '../log/console.js';
|
|
2
3
|
import type { EnvVar } from './env_var.js';
|
|
3
4
|
import { type NetworkNames, getActiveNetworkName } from './network_name.js';
|
|
4
5
|
import { SecretValue } from './secret_value.js';
|
|
@@ -17,6 +18,11 @@ export interface ConfigMapping {
|
|
|
17
18
|
isBoolean?: boolean;
|
|
18
19
|
nested?: Record<string, ConfigMapping>;
|
|
19
20
|
fallback?: EnvVar[];
|
|
21
|
+
/**
|
|
22
|
+
* List of deprecated env vars that are still supported but will log a warning.
|
|
23
|
+
* These should also be included in the fallback array for parsing.
|
|
24
|
+
*/
|
|
25
|
+
deprecatedFallback?: { env: EnvVar; message?: string }[];
|
|
20
26
|
}
|
|
21
27
|
|
|
22
28
|
export function isBooleanConfigValue<T>(obj: T, key: keyof T): boolean {
|
|
@@ -72,12 +78,24 @@ export function getConfigFromMappings<T>(configMappings: ConfigMappingsType<T>):
|
|
|
72
78
|
const config = {} as T;
|
|
73
79
|
|
|
74
80
|
for (const key in configMappings) {
|
|
75
|
-
const { env, parseEnv, defaultValue, nested, fallback } = configMappings[key];
|
|
81
|
+
const { env, parseEnv, defaultValue, nested, fallback, deprecatedFallback } = configMappings[key];
|
|
76
82
|
if (nested) {
|
|
77
83
|
(config as any)[key] = getConfigFromMappings(nested);
|
|
78
84
|
} else {
|
|
79
85
|
// Use the shared utility function
|
|
80
86
|
(config as any)[key] = getValueFromEnvWithFallback(env, parseEnv, defaultValue, fallback);
|
|
87
|
+
|
|
88
|
+
// Check for deprecated env vars and warn if logger is set
|
|
89
|
+
if (deprecatedFallback?.length) {
|
|
90
|
+
const userLog = createConsoleLogger('[DEPRECATED]');
|
|
91
|
+
for (const { env: deprecatedEnv, message } of deprecatedFallback) {
|
|
92
|
+
if (process.env[deprecatedEnv]) {
|
|
93
|
+
const warningMessage =
|
|
94
|
+
message ?? `Environment variable ${deprecatedEnv} is deprecated. Please use ${env} instead.`;
|
|
95
|
+
userLog(warningMessage, { deprecatedEnvVar: deprecatedEnv, newEnvVar: env });
|
|
96
|
+
}
|
|
97
|
+
}
|
|
98
|
+
}
|
|
81
99
|
}
|
|
82
100
|
}
|
|
83
101
|
|
|
@@ -4,9 +4,11 @@ export const NetworkConfigSchema = z
|
|
|
4
4
|
.object({
|
|
5
5
|
bootnodes: z.array(z.string()),
|
|
6
6
|
snapshots: z.array(z.string()),
|
|
7
|
+
blobFileStoreUrls: z.array(z.string()).optional(),
|
|
7
8
|
registryAddress: z.string(),
|
|
8
9
|
feeAssetHandlerAddress: z.string().optional(),
|
|
9
10
|
l1ChainId: z.number(),
|
|
11
|
+
blockDurationMs: z.number().positive().optional(),
|
|
10
12
|
})
|
|
11
13
|
.passthrough(); // Allow additional unknown fields to pass through
|
|
12
14
|
|
package/src/crypto/bls/index.ts
CHANGED
|
@@ -1,173 +1,64 @@
|
|
|
1
|
-
import {
|
|
2
|
-
|
|
3
|
-
BN254_G2_GENERATOR,
|
|
4
|
-
BarretenbergSync,
|
|
5
|
-
type Bn254G1Point as BbApiBn254G1Point,
|
|
6
|
-
type Bn254G2Point as BbApiBn254G2Point,
|
|
7
|
-
} from '@aztec/bb.js';
|
|
8
|
-
|
|
9
|
-
import { Fq, Fr } from '../../fields/fields.js';
|
|
1
|
+
import { Fr } from '../../curves/bn254/field.js';
|
|
2
|
+
import { Bn254G1Point, Bn254G2Point } from '../../curves/bn254/point.js';
|
|
10
3
|
|
|
11
4
|
/**
|
|
12
|
-
* BN254
|
|
13
|
-
*
|
|
5
|
+
* BN254 utility functions for point operations.
|
|
6
|
+
* Provides compression, decompression, and public key generation for the BN254 curve.
|
|
7
|
+
* Uses the bb.js Barretenberg backend for point operations.
|
|
14
8
|
*/
|
|
15
|
-
export class Bn254G1Point {
|
|
16
|
-
constructor(
|
|
17
|
-
public readonly x: Fq,
|
|
18
|
-
public readonly y: Fq,
|
|
19
|
-
) {}
|
|
20
|
-
|
|
21
|
-
private toBbApiPoint(): BbApiBn254G1Point {
|
|
22
|
-
return {
|
|
23
|
-
x: this.x.toBuffer(),
|
|
24
|
-
y: this.y.toBuffer(),
|
|
25
|
-
};
|
|
26
|
-
}
|
|
27
|
-
|
|
28
|
-
private static fromBbApiPoint(point: BbApiBn254G1Point): Bn254G1Point {
|
|
29
|
-
return new Bn254G1Point(Fq.fromBuffer(Buffer.from(point.x)), Fq.fromBuffer(Buffer.from(point.y)));
|
|
30
|
-
}
|
|
31
|
-
|
|
32
|
-
async isOnCurve(): Promise<boolean> {
|
|
33
|
-
await BarretenbergSync.initSingleton();
|
|
34
|
-
const api = BarretenbergSync.getSingleton();
|
|
35
|
-
|
|
36
|
-
const apiPoint = this.toBbApiPoint();
|
|
37
|
-
const response = api.bn254G1IsOnCurve({ point: apiPoint });
|
|
38
|
-
return response.isOnCurve;
|
|
39
|
-
}
|
|
40
|
-
|
|
41
|
-
/**
|
|
42
|
-
* Get the generator point for BN254 G1, or perform scalar multiplication.
|
|
43
|
-
* When called without arguments, returns the base generator point.
|
|
44
|
-
* When called with a scalar, returns scalar * generator (useful for public key derivation).
|
|
45
|
-
*/
|
|
46
|
-
static async generator(scalar?: Fr): Promise<Bn254G1Point> {
|
|
47
|
-
if (!scalar) {
|
|
48
|
-
return new Bn254G1Point(
|
|
49
|
-
Fq.fromBuffer(Buffer.from(BN254_G1_GENERATOR.x)),
|
|
50
|
-
Fq.fromBuffer(Buffer.from(BN254_G1_GENERATOR.y)),
|
|
51
|
-
);
|
|
52
|
-
}
|
|
53
|
-
|
|
54
|
-
await BarretenbergSync.initSingleton();
|
|
55
|
-
const api = BarretenbergSync.getSingleton();
|
|
56
|
-
|
|
57
|
-
const response = api.bn254G1Mul({
|
|
58
|
-
point: BN254_G1_GENERATOR,
|
|
59
|
-
scalar: scalar.toBuffer(),
|
|
60
|
-
});
|
|
61
|
-
|
|
62
|
-
return Bn254G1Point.fromBbApiPoint(response.point);
|
|
63
|
-
}
|
|
64
|
-
|
|
65
|
-
/**
|
|
66
|
-
* Decompress a BN254 G1 point from compressed form (32 bytes).
|
|
67
|
-
* The compressed format encodes the x-coordinate and the sign bit of the y-coordinate
|
|
68
|
-
* in the most significant bit.
|
|
69
|
-
*/
|
|
70
|
-
static async fromCompressed(compressed: Buffer): Promise<Bn254G1Point> {
|
|
71
|
-
if (compressed.length !== 32) {
|
|
72
|
-
throw new Error('Invalid compressed point length');
|
|
73
|
-
}
|
|
74
|
-
await BarretenbergSync.initSingleton();
|
|
75
|
-
const api = BarretenbergSync.getSingleton();
|
|
76
|
-
|
|
77
|
-
const response = api.bn254G1FromCompressed({
|
|
78
|
-
compressed: new Uint8Array(compressed),
|
|
79
|
-
});
|
|
80
|
-
|
|
81
|
-
return Bn254G1Point.fromBbApiPoint(response.point);
|
|
82
|
-
}
|
|
83
9
|
|
|
84
|
-
|
|
85
|
-
|
|
86
|
-
|
|
87
|
-
|
|
88
|
-
|
|
89
|
-
|
|
90
|
-
|
|
91
|
-
|
|
92
|
-
|
|
93
|
-
// If y is odd, set the most significant bit (bit 255) of the output
|
|
94
|
-
if (yLsb === 1n) {
|
|
95
|
-
xBytes[0] |= 0x80;
|
|
96
|
-
}
|
|
97
|
-
return xBytes;
|
|
98
|
-
}
|
|
10
|
+
/**
|
|
11
|
+
* Generate a compressed BN254 G1 public key from a private key.
|
|
12
|
+
*
|
|
13
|
+
* @param privateKeyHex - Private key as 0x-prefixed hex string
|
|
14
|
+
* @returns Compressed G1 point (32 bytes with sign bit in MSB)
|
|
15
|
+
*/
|
|
16
|
+
export async function computeBn254G1PublicKeyCompressed(privateKeyHex: string): Promise<string> {
|
|
17
|
+
const sk = BigInt(privateKeyHex);
|
|
18
|
+
const skReduced = sk % Fr.MODULUS;
|
|
99
19
|
|
|
100
|
-
|
|
101
|
-
|
|
102
|
-
|
|
20
|
+
// Generate G1 point on BN254 curve using bb.js
|
|
21
|
+
const scalar = Fr.fromString(skReduced.toString());
|
|
22
|
+
const pk1 = await Bn254G1Point.generator(scalar);
|
|
103
23
|
|
|
104
|
-
|
|
105
|
-
|
|
106
|
-
}
|
|
24
|
+
// Compress the point using the primitive method
|
|
25
|
+
return '0x' + pk1.compress().toString('hex');
|
|
107
26
|
}
|
|
108
27
|
|
|
109
28
|
/**
|
|
110
|
-
* BN254
|
|
111
|
-
*
|
|
112
|
-
*
|
|
29
|
+
* Generate uncompressed BN254 G1 public key from a private key.
|
|
30
|
+
*
|
|
31
|
+
* @param privateKeyHex - Private key as 0x-prefixed hex string
|
|
32
|
+
* @returns G1 point in affine coordinates
|
|
113
33
|
*/
|
|
114
|
-
export
|
|
115
|
-
|
|
116
|
-
|
|
117
|
-
public readonly y: [Fq, Fq],
|
|
118
|
-
) {}
|
|
119
|
-
|
|
120
|
-
private toBbApiPoint(): BbApiBn254G2Point {
|
|
121
|
-
return {
|
|
122
|
-
x: [this.x[0].toBuffer(), this.x[1].toBuffer()],
|
|
123
|
-
y: [this.y[0].toBuffer(), this.y[1].toBuffer()],
|
|
124
|
-
};
|
|
125
|
-
}
|
|
126
|
-
|
|
127
|
-
private static fromBbApiPoint(point: BbApiBn254G2Point): Bn254G2Point {
|
|
128
|
-
return new Bn254G2Point(
|
|
129
|
-
[Fq.fromBuffer(Buffer.from(point.x[0])), Fq.fromBuffer(Buffer.from(point.x[1]))],
|
|
130
|
-
[Fq.fromBuffer(Buffer.from(point.y[0])), Fq.fromBuffer(Buffer.from(point.y[1]))],
|
|
131
|
-
);
|
|
132
|
-
}
|
|
133
|
-
|
|
134
|
-
/**
|
|
135
|
-
* Get the generator point for BN254 G2, or perform scalar multiplication.
|
|
136
|
-
* When called without arguments, returns the base generator point.
|
|
137
|
-
* When called with a scalar, returns scalar * generator.
|
|
138
|
-
*/
|
|
139
|
-
static async generator(scalar?: Fr): Promise<Bn254G2Point> {
|
|
140
|
-
if (!scalar) {
|
|
141
|
-
return new Bn254G2Point(
|
|
142
|
-
[Fq.fromBuffer(Buffer.from(BN254_G2_GENERATOR.x[0])), Fq.fromBuffer(Buffer.from(BN254_G2_GENERATOR.x[1]))],
|
|
143
|
-
[Fq.fromBuffer(Buffer.from(BN254_G2_GENERATOR.y[0])), Fq.fromBuffer(Buffer.from(BN254_G2_GENERATOR.y[1]))],
|
|
144
|
-
);
|
|
145
|
-
}
|
|
146
|
-
|
|
147
|
-
await BarretenbergSync.initSingleton();
|
|
148
|
-
const api = BarretenbergSync.getSingleton();
|
|
34
|
+
export async function computeBn254G1PublicKey(privateKeyHex: string): Promise<{ x: bigint; y: bigint }> {
|
|
35
|
+
const sk = BigInt(privateKeyHex);
|
|
36
|
+
const skReduced = sk % Fr.MODULUS;
|
|
149
37
|
|
|
150
|
-
|
|
151
|
-
|
|
152
|
-
scalar: scalar.toBuffer(),
|
|
153
|
-
});
|
|
38
|
+
const scalar = Fr.fromString(skReduced.toString());
|
|
39
|
+
const pk1 = await Bn254G1Point.generator(scalar);
|
|
154
40
|
|
|
155
|
-
|
|
156
|
-
}
|
|
157
|
-
|
|
158
|
-
equals(other: Bn254G2Point): boolean {
|
|
159
|
-
return (
|
|
160
|
-
this.x[0].equals(other.x[0]) &&
|
|
161
|
-
this.x[1].equals(other.x[1]) &&
|
|
162
|
-
this.y[0].equals(other.y[0]) &&
|
|
163
|
-
this.y[1].equals(other.y[1])
|
|
164
|
-
);
|
|
165
|
-
}
|
|
166
|
-
|
|
167
|
-
toString(): string {
|
|
168
|
-
return `Bn254G2Point(x: (${this.x[0].toString()}, ${this.x[1].toString()}), y: (${this.y[0].toString()}, ${this.y[1].toString()}))`;
|
|
169
|
-
}
|
|
41
|
+
return { x: pk1.x.toBigInt(), y: pk1.y.toBigInt() };
|
|
170
42
|
}
|
|
171
43
|
|
|
172
|
-
|
|
173
|
-
|
|
44
|
+
/**
|
|
45
|
+
* Generate BN254 G2 public key from a private key.
|
|
46
|
+
*
|
|
47
|
+
* @param privateKeyHex - Private key as 0x-prefixed hex string
|
|
48
|
+
* @returns G2 point in affine coordinates
|
|
49
|
+
*/
|
|
50
|
+
export async function computeBn254G2PublicKey(privateKeyHex: string): Promise<{
|
|
51
|
+
x: { c0: bigint; c1: bigint };
|
|
52
|
+
y: { c0: bigint; c1: bigint };
|
|
53
|
+
}> {
|
|
54
|
+
const sk = BigInt(privateKeyHex);
|
|
55
|
+
const skReduced = sk % Fr.MODULUS;
|
|
56
|
+
|
|
57
|
+
const scalar = Fr.fromString(skReduced.toString());
|
|
58
|
+
const pk2 = await Bn254G2Point.generator(scalar);
|
|
59
|
+
|
|
60
|
+
return {
|
|
61
|
+
x: { c0: pk2.x[0].toBigInt(), c1: pk2.x[1].toBigInt() },
|
|
62
|
+
y: { c0: pk2.y[0].toBigInt(), c1: pk2.y[1].toBigInt() },
|
|
63
|
+
};
|
|
64
|
+
}
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { toBufferBE } from '@aztec/foundation/bigint-buffer';
|
|
2
|
-
import { randomBytes } from '@aztec/foundation/crypto';
|
|
3
|
-
import { Fr } from '@aztec/foundation/
|
|
2
|
+
import { randomBytes } from '@aztec/foundation/crypto/random';
|
|
3
|
+
import { Fr } from '@aztec/foundation/curves/bn254';
|
|
4
4
|
import { mapTuple } from '@aztec/foundation/serialize';
|
|
5
5
|
|
|
6
6
|
import type { Signature } from '../signature/index.js';
|
|
@@ -1,5 +1,7 @@
|
|
|
1
1
|
import { BarretenbergSync } from '@aztec/bb.js';
|
|
2
|
-
import { Fr
|
|
2
|
+
import { Fr } from '@aztec/foundation/curves/bn254';
|
|
3
|
+
import type { GrumpkinScalar } from '@aztec/foundation/curves/grumpkin';
|
|
4
|
+
import { Point } from '@aztec/foundation/curves/grumpkin';
|
|
3
5
|
|
|
4
6
|
/**
|
|
5
7
|
* Grumpkin elliptic curve operations.
|
package/src/crypto/keys/index.ts
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { BarretenbergSync } from '@aztec/bb.js';
|
|
2
2
|
|
|
3
|
-
import { Fr } from '../../
|
|
3
|
+
import { Fr } from '../../curves/bn254/field.js';
|
|
4
4
|
|
|
5
5
|
export async function vkAsFieldsMegaHonk(input: Buffer): Promise<Fr[]> {
|
|
6
6
|
await BarretenbergSync.initSingleton();
|
|
@@ -1,5 +1,6 @@
|
|
|
1
1
|
import { BarretenbergSync } from '@aztec/bb.js';
|
|
2
|
-
import {
|
|
2
|
+
import type { GrumpkinScalar } from '@aztec/foundation/curves/grumpkin';
|
|
3
|
+
import { Point } from '@aztec/foundation/curves/grumpkin';
|
|
3
4
|
|
|
4
5
|
import { SchnorrSignature } from './signature.js';
|
|
5
6
|
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { randomBytes } from '@aztec/foundation/crypto';
|
|
2
|
-
import { Fr } from '@aztec/foundation/
|
|
1
|
+
import { randomBytes } from '@aztec/foundation/crypto/random';
|
|
2
|
+
import { Fr } from '@aztec/foundation/curves/bn254';
|
|
3
3
|
import { BufferReader, mapTuple } from '@aztec/foundation/serialize';
|
|
4
4
|
|
|
5
5
|
import type { Signature } from '../signature/index.js';
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
/* eslint-disable camelcase */
|
|
2
2
|
import { default as hash } from 'hash.js';
|
|
3
3
|
|
|
4
|
-
import { Fr } from '../../
|
|
4
|
+
import { Fr } from '../../curves/bn254/field.js';
|
|
5
5
|
import { truncateAndPad } from '../../serialize/free_funcs.js';
|
|
6
6
|
import { type Bufferable, serializeToBuffer } from '../../serialize/serialize.js';
|
|
7
7
|
import type { Hasher } from '../../trees/hasher.js';
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { default as hash } from 'hash.js';
|
|
2
2
|
|
|
3
|
-
import { GrumpkinScalar } from '../../
|
|
3
|
+
import { GrumpkinScalar } from '../../curves/grumpkin/index.js';
|
|
4
4
|
import { type Bufferable, serializeToBuffer } from '../../serialize/serialize.js';
|
|
5
5
|
|
|
6
6
|
export const sha512 = (data: Buffer) => Buffer.from(hash.sha512().update(data).digest());
|
|
@@ -2,12 +2,12 @@
|
|
|
2
2
|
import { bls12_381 } from '@noble/curves/bls12-381';
|
|
3
3
|
import { inspect } from 'util';
|
|
4
4
|
|
|
5
|
-
import { toBigIntBE, toBufferBE } from '
|
|
6
|
-
import { randomBytes } from '
|
|
7
|
-
import { hexSchemaFor } from '
|
|
8
|
-
import { BufferReader } from '
|
|
9
|
-
import { TypeRegistry } from '
|
|
10
|
-
import { Fr } from '
|
|
5
|
+
import { toBigIntBE, toBufferBE } from '../../bigint-buffer/index.js';
|
|
6
|
+
import { randomBytes } from '../../crypto/random/index.js';
|
|
7
|
+
import { hexSchemaFor } from '../../schemas/utils.js';
|
|
8
|
+
import { BufferReader } from '../../serialize/buffer_reader.js';
|
|
9
|
+
import { TypeRegistry } from '../../serialize/type_registry.js';
|
|
10
|
+
import { Fr } from '../bn254/field.js';
|
|
11
11
|
|
|
12
12
|
/**
|
|
13
13
|
* Represents a field derived from BLS12Field.
|
|
@@ -3,13 +3,13 @@ import type { ProjPointType } from '@noble/curves/abstract/weierstrass';
|
|
|
3
3
|
import { bls12_381 } from '@noble/curves/bls12-381';
|
|
4
4
|
import { inspect } from 'util';
|
|
5
5
|
|
|
6
|
-
import { toBufferBE } from '
|
|
7
|
-
import { randomBoolean } from '
|
|
8
|
-
import { hexSchemaFor } from '
|
|
9
|
-
import { BufferReader, serializeToBuffer } from '
|
|
10
|
-
import { bufferToHex, hexToBuffer } from '
|
|
11
|
-
import {
|
|
12
|
-
import {
|
|
6
|
+
import { toBufferBE } from '../../bigint-buffer/index.js';
|
|
7
|
+
import { randomBoolean } from '../../crypto/random/index.js';
|
|
8
|
+
import { hexSchemaFor } from '../../schemas/utils.js';
|
|
9
|
+
import { BufferReader, serializeToBuffer } from '../../serialize/index.js';
|
|
10
|
+
import { bufferToHex, hexToBuffer } from '../../string/index.js';
|
|
11
|
+
import { Fr } from '../bn254/field.js';
|
|
12
|
+
import { BLS12Fq, BLS12Fr } from './field.js';
|
|
13
13
|
|
|
14
14
|
/**
|
|
15
15
|
* Represents a Point on an elliptic curve with x and y coordinates.
|