@devtion/actions 0.0.0-c749be4 → 0.0.0-e22d20d
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/dist/index.mjs +121 -54
- package/dist/index.node.js +122 -53
- package/dist/types/src/helpers/constants.d.ts +5 -2
- package/dist/types/src/helpers/constants.d.ts.map +1 -1
- package/dist/types/src/helpers/contracts.d.ts.map +1 -1
- package/dist/types/src/helpers/crypto.d.ts +1 -0
- package/dist/types/src/helpers/crypto.d.ts.map +1 -1
- package/dist/types/src/helpers/database.d.ts +8 -0
- package/dist/types/src/helpers/database.d.ts.map +1 -1
- package/dist/types/src/helpers/utils.d.ts +15 -1
- package/dist/types/src/helpers/utils.d.ts.map +1 -1
- package/dist/types/src/helpers/verification.d.ts +3 -2
- package/dist/types/src/helpers/verification.d.ts.map +1 -1
- package/dist/types/src/helpers/vm.d.ts.map +1 -1
- package/dist/types/src/index.d.ts +2 -2
- package/dist/types/src/index.d.ts.map +1 -1
- package/dist/types/src/types/index.d.ts +7 -1
- package/dist/types/src/types/index.d.ts.map +1 -1
- package/package.json +3 -4
- package/src/helpers/constants.ts +40 -32
- package/src/helpers/contracts.ts +3 -3
- package/src/helpers/database.ts +13 -0
- package/src/helpers/utils.ts +58 -13
- package/src/helpers/verification.ts +6 -6
- package/src/helpers/vm.ts +16 -2
- package/src/index.ts +3 -1
- package/src/types/index.ts +21 -1
package/dist/index.node.js
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
/**
|
|
2
2
|
* @module @devtion/actions
|
|
3
|
-
* @version 1.
|
|
3
|
+
* @version 1.2.5
|
|
4
4
|
* @file A set of actions and helpers for CLI commands
|
|
5
5
|
* @copyright Ethereum Foundation 2022
|
|
6
6
|
* @license MIT
|
|
@@ -17,7 +17,6 @@ var firestore = require('firebase/firestore');
|
|
|
17
17
|
var snarkjs = require('snarkjs');
|
|
18
18
|
var crypto = require('crypto');
|
|
19
19
|
var blake = require('blakejs');
|
|
20
|
-
var ffjavascript = require('ffjavascript');
|
|
21
20
|
var winston = require('winston');
|
|
22
21
|
var stream = require('stream');
|
|
23
22
|
var util = require('util');
|
|
@@ -29,10 +28,10 @@ var clientEc2 = require('@aws-sdk/client-ec2');
|
|
|
29
28
|
var clientSsm = require('@aws-sdk/client-ssm');
|
|
30
29
|
var dotenv = require('dotenv');
|
|
31
30
|
|
|
32
|
-
// Main part for the
|
|
33
|
-
const potFileDownloadMainUrl = `https://
|
|
34
|
-
// Main part for the
|
|
35
|
-
const potFilenameTemplate = `
|
|
31
|
+
// Main part for the PPoT Phase 1 Trusted Setup URLs to download PoT files.
|
|
32
|
+
const potFileDownloadMainUrl = `https://pse-trusted-setup-ppot.s3.eu-central-1.amazonaws.com/pot28_0080/`;
|
|
33
|
+
// Main part for the PPoT Phase 1 Trusted Setup PoT files to be downloaded.
|
|
34
|
+
const potFilenameTemplate = `ppot_0080_`;
|
|
36
35
|
// The genesis zKey index.
|
|
37
36
|
const genesisZkeyIndex = `00000`;
|
|
38
37
|
// The number of exponential iterations to be executed by SnarkJS when finalizing the ceremony.
|
|
@@ -49,6 +48,8 @@ const verifierSmartContractAcronym = "verifier";
|
|
|
49
48
|
const ec2InstanceTag = "p0tionec2instance";
|
|
50
49
|
// The name of the VM startup script file.
|
|
51
50
|
const vmBootstrapScriptFilename = "bootstrap.sh";
|
|
51
|
+
// Match hash output by snarkjs in transcript log
|
|
52
|
+
const contribHashRegex = new RegExp("Contribution.+Hash.+\n\t\t.+\n\t\t.+\n.+\n\t\t.+\r?\n");
|
|
52
53
|
/**
|
|
53
54
|
* Define the supported VM configuration types.
|
|
54
55
|
* @dev the VM configurations can be retrieved at https://aws.amazon.com/ec2/instance-types/
|
|
@@ -106,112 +107,116 @@ const vmConfigurationTypes = {
|
|
|
106
107
|
*/
|
|
107
108
|
const powersOfTauFiles = [
|
|
108
109
|
{
|
|
109
|
-
ref: "https://
|
|
110
|
+
ref: "https://pse-trusted-setup-ppot.s3.eu-central-1.amazonaws.com/pot28_0080/ppot_0080_01.ptau",
|
|
110
111
|
size: 0.000084
|
|
111
112
|
},
|
|
112
113
|
{
|
|
113
|
-
ref: "https://
|
|
114
|
+
ref: "https://pse-trusted-setup-ppot.s3.eu-central-1.amazonaws.com/pot28_0080/ppot_0080_02.ptau",
|
|
114
115
|
size: 0.000086
|
|
115
116
|
},
|
|
116
117
|
{
|
|
117
|
-
ref: "https://
|
|
118
|
+
ref: "https://pse-trusted-setup-ppot.s3.eu-central-1.amazonaws.com/pot28_0080/ppot_0080_03.ptau",
|
|
118
119
|
size: 0.000091
|
|
119
120
|
},
|
|
120
121
|
{
|
|
121
|
-
ref: "https://
|
|
122
|
+
ref: "https://pse-trusted-setup-ppot.s3.eu-central-1.amazonaws.com/pot28_0080/ppot_0080_04.ptau",
|
|
122
123
|
size: 0.0001
|
|
123
124
|
},
|
|
124
125
|
{
|
|
125
|
-
ref: "https://
|
|
126
|
+
ref: "https://pse-trusted-setup-ppot.s3.eu-central-1.amazonaws.com/pot28_0080/ppot_0080_05.ptau",
|
|
126
127
|
size: 0.000117
|
|
127
128
|
},
|
|
128
129
|
{
|
|
129
|
-
ref: "https://
|
|
130
|
+
ref: "https://pse-trusted-setup-ppot.s3.eu-central-1.amazonaws.com/pot28_0080/ppot_0080_06.ptau",
|
|
130
131
|
size: 0.000153
|
|
131
132
|
},
|
|
132
133
|
{
|
|
133
|
-
ref: "https://
|
|
134
|
+
ref: "https://pse-trusted-setup-ppot.s3.eu-central-1.amazonaws.com/pot28_0080/ppot_0080_07.ptau",
|
|
134
135
|
size: 0.000225
|
|
135
136
|
},
|
|
136
137
|
{
|
|
137
|
-
ref: "https://
|
|
138
|
+
ref: "https://pse-trusted-setup-ppot.s3.eu-central-1.amazonaws.com/pot28_0080/ppot_0080_08.ptau",
|
|
138
139
|
size: 0.0004
|
|
139
140
|
},
|
|
140
141
|
{
|
|
141
|
-
ref: "https://
|
|
142
|
+
ref: "https://pse-trusted-setup-ppot.s3.eu-central-1.amazonaws.com/pot28_0080/ppot_0080_09.ptau",
|
|
142
143
|
size: 0.000658
|
|
143
144
|
},
|
|
144
145
|
{
|
|
145
|
-
ref: "https://
|
|
146
|
+
ref: "https://pse-trusted-setup-ppot.s3.eu-central-1.amazonaws.com/pot28_0080/ppot_0080_10.ptau",
|
|
146
147
|
size: 0.0013
|
|
147
148
|
},
|
|
148
149
|
{
|
|
149
|
-
ref: "https://
|
|
150
|
+
ref: "https://pse-trusted-setup-ppot.s3.eu-central-1.amazonaws.com/pot28_0080/ppot_0080_11.ptau",
|
|
150
151
|
size: 0.0023
|
|
151
152
|
},
|
|
152
153
|
{
|
|
153
|
-
ref: "https://
|
|
154
|
+
ref: "https://pse-trusted-setup-ppot.s3.eu-central-1.amazonaws.com/pot28_0080/ppot_0080_12.ptau",
|
|
154
155
|
size: 0.0046
|
|
155
156
|
},
|
|
156
157
|
{
|
|
157
|
-
ref: "https://
|
|
158
|
+
ref: "https://pse-trusted-setup-ppot.s3.eu-central-1.amazonaws.com/pot28_0080/ppot_0080_13.ptau",
|
|
158
159
|
size: 0.0091
|
|
159
160
|
},
|
|
160
161
|
{
|
|
161
|
-
ref: "https://
|
|
162
|
+
ref: "https://pse-trusted-setup-ppot.s3.eu-central-1.amazonaws.com/pot28_0080/ppot_0080_14.ptau",
|
|
162
163
|
size: 0.0181
|
|
163
164
|
},
|
|
164
165
|
{
|
|
165
|
-
ref: "https://
|
|
166
|
+
ref: "https://pse-trusted-setup-ppot.s3.eu-central-1.amazonaws.com/pot28_0080/ppot_0080_15.ptau",
|
|
166
167
|
size: 0.0361
|
|
167
168
|
},
|
|
168
169
|
{
|
|
169
|
-
ref: "https://
|
|
170
|
+
ref: "https://pse-trusted-setup-ppot.s3.eu-central-1.amazonaws.com/pot28_0080/ppot_0080_16.ptau",
|
|
170
171
|
size: 0.0721
|
|
171
172
|
},
|
|
172
173
|
{
|
|
173
|
-
ref: "https://
|
|
174
|
+
ref: "https://pse-trusted-setup-ppot.s3.eu-central-1.amazonaws.com/pot28_0080/ppot_0080_17.ptau",
|
|
174
175
|
size: 0.144
|
|
175
176
|
},
|
|
176
177
|
{
|
|
177
|
-
ref: "https://
|
|
178
|
+
ref: "https://pse-trusted-setup-ppot.s3.eu-central-1.amazonaws.com/pot28_0080/ppot_0080_18.ptau",
|
|
178
179
|
size: 0.288
|
|
179
180
|
},
|
|
180
181
|
{
|
|
181
|
-
ref: "https://
|
|
182
|
+
ref: "https://pse-trusted-setup-ppot.s3.eu-central-1.amazonaws.com/pot28_0080/ppot_0080_19.ptau",
|
|
182
183
|
size: 0.576
|
|
183
184
|
},
|
|
184
185
|
{
|
|
185
|
-
ref: "https://
|
|
186
|
+
ref: "https://pse-trusted-setup-ppot.s3.eu-central-1.amazonaws.com/pot28_0080/ppot_0080_20.ptau",
|
|
186
187
|
size: 1.1
|
|
187
188
|
},
|
|
188
189
|
{
|
|
189
|
-
ref: "https://
|
|
190
|
+
ref: "https://pse-trusted-setup-ppot.s3.eu-central-1.amazonaws.com/pot28_0080/ppot_0080_21.ptau",
|
|
190
191
|
size: 2.3
|
|
191
192
|
},
|
|
192
193
|
{
|
|
193
|
-
ref: "https://
|
|
194
|
+
ref: "https://pse-trusted-setup-ppot.s3.eu-central-1.amazonaws.com/pot28_0080/ppot_0080_22.ptau",
|
|
194
195
|
size: 4.5
|
|
195
196
|
},
|
|
196
197
|
{
|
|
197
|
-
ref: "https://
|
|
198
|
+
ref: "https://pse-trusted-setup-ppot.s3.eu-central-1.amazonaws.com/pot28_0080/ppot_0080_23.ptau",
|
|
198
199
|
size: 9.0
|
|
199
200
|
},
|
|
200
201
|
{
|
|
201
|
-
ref: "https://
|
|
202
|
+
ref: "https://pse-trusted-setup-ppot.s3.eu-central-1.amazonaws.com/pot28_0080/ppot_0080_24.ptau",
|
|
202
203
|
size: 18.0
|
|
203
204
|
},
|
|
204
205
|
{
|
|
205
|
-
ref: "https://
|
|
206
|
+
ref: "https://pse-trusted-setup-ppot.s3.eu-central-1.amazonaws.com/pot28_0080/ppot_0080_25.ptau",
|
|
206
207
|
size: 36.0
|
|
207
208
|
},
|
|
208
209
|
{
|
|
209
|
-
ref: "https://
|
|
210
|
+
ref: "https://pse-trusted-setup-ppot.s3.eu-central-1.amazonaws.com/pot28_0080/ppot_0080_26.ptau",
|
|
210
211
|
size: 72.0
|
|
211
212
|
},
|
|
212
213
|
{
|
|
213
|
-
ref: "https://
|
|
214
|
+
ref: "https://pse-trusted-setup-ppot.s3.eu-central-1.amazonaws.com/pot28_0080/ppot_0080_27.ptau",
|
|
214
215
|
size: 144.0
|
|
216
|
+
},
|
|
217
|
+
{
|
|
218
|
+
ref: "https://pse-trusted-setup-ppot.s3.eu-central-1.amazonaws.com/pot28_0080/ppot_0080_final.ptau",
|
|
219
|
+
size: 288.0
|
|
215
220
|
}
|
|
216
221
|
];
|
|
217
222
|
/**
|
|
@@ -341,7 +346,9 @@ const commonTerms = {
|
|
|
341
346
|
finalizeCircuit: "finalizeCircuit",
|
|
342
347
|
finalizeCeremony: "finalizeCeremony",
|
|
343
348
|
downloadCircuitArtifacts: "downloadCircuitArtifacts",
|
|
344
|
-
transferObject: "transferObject"
|
|
349
|
+
transferObject: "transferObject",
|
|
350
|
+
bandadaValidateProof: "bandadaValidateProof",
|
|
351
|
+
checkNonceOfSIWEAddress: "checkNonceOfSIWEAddress"
|
|
345
352
|
}
|
|
346
353
|
};
|
|
347
354
|
|
|
@@ -707,8 +714,8 @@ const uploadParts = async (chunksWithUrls, contentType, cloudFunctions, ceremony
|
|
|
707
714
|
// @ts-ignore
|
|
708
715
|
const response = await fetch(chunksWithUrls[i].preSignedUrl, {
|
|
709
716
|
retryOptions: {
|
|
710
|
-
retryInitialDelay: 500,
|
|
711
|
-
socketTimeout: 60000,
|
|
717
|
+
retryInitialDelay: 500, // 500 ms.
|
|
718
|
+
socketTimeout: 60000, // 60 seconds.
|
|
712
719
|
retryMaxDuration: 300000 // 5 minutes.
|
|
713
720
|
},
|
|
714
721
|
method: "PUT",
|
|
@@ -1005,6 +1012,17 @@ const getClosedCeremonies = async (firestoreDatabase) => {
|
|
|
1005
1012
|
]);
|
|
1006
1013
|
return fromQueryToFirebaseDocumentInfo(closedCeremoniesQuerySnap.docs);
|
|
1007
1014
|
};
|
|
1015
|
+
/**
|
|
1016
|
+
* Query all ceremonies
|
|
1017
|
+
* @notice get all ceremonies from the database.
|
|
1018
|
+
* @dev this is a helper for the CLI ceremony methods.
|
|
1019
|
+
* @param firestoreDatabase <Firestore> - the Firestore service instance associated to the current Firebase application.
|
|
1020
|
+
* @returns <Promise<Array<FirebaseDocumentInfo>>> - the list of all ceremonies.
|
|
1021
|
+
*/
|
|
1022
|
+
const getAllCeremonies = async (firestoreDatabase) => {
|
|
1023
|
+
const ceremoniesQuerySnap = await queryCollection(firestoreDatabase, commonTerms.collections.ceremonies.name, []);
|
|
1024
|
+
return fromQueryToFirebaseDocumentInfo(ceremoniesQuerySnap.docs);
|
|
1025
|
+
};
|
|
1008
1026
|
|
|
1009
1027
|
/**
|
|
1010
1028
|
* @hidden
|
|
@@ -1264,6 +1282,41 @@ const readBytesFromFile = (localFilePath, offset, length, position) => {
|
|
|
1264
1282
|
// Return the read bytes.
|
|
1265
1283
|
return buffer;
|
|
1266
1284
|
};
|
|
1285
|
+
/**
|
|
1286
|
+
* Given a buffer in little endian format, convert it to bigint
|
|
1287
|
+
* @param buffer
|
|
1288
|
+
* @returns
|
|
1289
|
+
*/
|
|
1290
|
+
function leBufferToBigint(buffer) {
|
|
1291
|
+
return BigInt(`0x${buffer.reverse().toString("hex")}`);
|
|
1292
|
+
}
|
|
1293
|
+
/**
|
|
1294
|
+
* Given an input containing string values, convert them
|
|
1295
|
+
* to bigint
|
|
1296
|
+
* @param input - The input to convert
|
|
1297
|
+
* @returns the input with string values converted to bigint
|
|
1298
|
+
*/
|
|
1299
|
+
const unstringifyBigInts = (input) => {
|
|
1300
|
+
if (typeof input === "string" && /^[0-9]+$/.test(input)) {
|
|
1301
|
+
return BigInt(input);
|
|
1302
|
+
}
|
|
1303
|
+
if (typeof input === "string" && /^0x[0-9a-fA-F]+$/.test(input)) {
|
|
1304
|
+
return BigInt(input);
|
|
1305
|
+
}
|
|
1306
|
+
if (Array.isArray(input)) {
|
|
1307
|
+
return input.map(unstringifyBigInts);
|
|
1308
|
+
}
|
|
1309
|
+
if (input === null) {
|
|
1310
|
+
return null;
|
|
1311
|
+
}
|
|
1312
|
+
if (typeof input === "object") {
|
|
1313
|
+
return Object.entries(input).reduce((acc, [key, value]) => {
|
|
1314
|
+
acc[key] = unstringifyBigInts(value);
|
|
1315
|
+
return acc;
|
|
1316
|
+
}, {});
|
|
1317
|
+
}
|
|
1318
|
+
return input;
|
|
1319
|
+
};
|
|
1267
1320
|
/**
|
|
1268
1321
|
* Return the info about the R1CS file.ù
|
|
1269
1322
|
* @dev this method was built taking inspiration from
|
|
@@ -1324,17 +1377,17 @@ const getR1CSInfo = (localR1CSFilePath) => {
|
|
|
1324
1377
|
let constraints = 0;
|
|
1325
1378
|
try {
|
|
1326
1379
|
// Get 'number of section' (jump magic r1cs and version1 data).
|
|
1327
|
-
const numberOfSections =
|
|
1380
|
+
const numberOfSections = leBufferToBigint(readBytesFromFile(localR1CSFilePath, 0, 4, 8));
|
|
1328
1381
|
// Jump to first section.
|
|
1329
1382
|
pointer = 12;
|
|
1330
1383
|
// For each section
|
|
1331
1384
|
for (let i = 0; i < numberOfSections; i++) {
|
|
1332
1385
|
// Read section type.
|
|
1333
|
-
const sectionType =
|
|
1386
|
+
const sectionType = leBufferToBigint(readBytesFromFile(localR1CSFilePath, 0, 4, pointer));
|
|
1334
1387
|
// Jump to section size.
|
|
1335
1388
|
pointer += 4;
|
|
1336
1389
|
// Read section size
|
|
1337
|
-
const sectionSize = Number(
|
|
1390
|
+
const sectionSize = Number(leBufferToBigint(readBytesFromFile(localR1CSFilePath, 0, 8, pointer)));
|
|
1338
1391
|
// If at header section (0x00000001 : Header Section).
|
|
1339
1392
|
if (sectionType === BigInt(1)) {
|
|
1340
1393
|
// Read info from header section.
|
|
@@ -1366,22 +1419,22 @@ const getR1CSInfo = (localR1CSFilePath) => {
|
|
|
1366
1419
|
*/
|
|
1367
1420
|
pointer += sectionSize - 20;
|
|
1368
1421
|
// Read R1CS info.
|
|
1369
|
-
wires = Number(
|
|
1422
|
+
wires = Number(leBufferToBigint(readBytesFromFile(localR1CSFilePath, 0, 4, pointer)));
|
|
1370
1423
|
pointer += 4;
|
|
1371
|
-
publicOutputs = Number(
|
|
1424
|
+
publicOutputs = Number(leBufferToBigint(readBytesFromFile(localR1CSFilePath, 0, 4, pointer)));
|
|
1372
1425
|
pointer += 4;
|
|
1373
|
-
publicInputs = Number(
|
|
1426
|
+
publicInputs = Number(leBufferToBigint(readBytesFromFile(localR1CSFilePath, 0, 4, pointer)));
|
|
1374
1427
|
pointer += 4;
|
|
1375
|
-
privateInputs = Number(
|
|
1428
|
+
privateInputs = Number(leBufferToBigint(readBytesFromFile(localR1CSFilePath, 0, 4, pointer)));
|
|
1376
1429
|
pointer += 4;
|
|
1377
|
-
labels = Number(
|
|
1430
|
+
labels = Number(leBufferToBigint(readBytesFromFile(localR1CSFilePath, 0, 8, pointer)));
|
|
1378
1431
|
pointer += 8;
|
|
1379
|
-
constraints = Number(
|
|
1432
|
+
constraints = Number(leBufferToBigint(readBytesFromFile(localR1CSFilePath, 0, 4, pointer)));
|
|
1380
1433
|
}
|
|
1381
1434
|
pointer += 8 + Number(sectionSize);
|
|
1382
1435
|
}
|
|
1383
1436
|
return {
|
|
1384
|
-
curve: "bn-128",
|
|
1437
|
+
curve: "bn-128", /// @note currently default to bn-128 as we support only Groth16 proving system.
|
|
1385
1438
|
wires,
|
|
1386
1439
|
constraints,
|
|
1387
1440
|
privateInputs,
|
|
@@ -1560,9 +1613,10 @@ const parseCeremonyFile = async (path, cleanup = false) => {
|
|
|
1560
1613
|
}
|
|
1561
1614
|
circuits.push(circuit);
|
|
1562
1615
|
// remove the local r1cs and wasm downloads (if used for verifying the config only vs setup)
|
|
1563
|
-
if (cleanup)
|
|
1616
|
+
if (cleanup) {
|
|
1564
1617
|
fs.unlinkSync(localR1csPath);
|
|
1565
|
-
|
|
1618
|
+
fs.unlinkSync(localWasmPath);
|
|
1619
|
+
}
|
|
1566
1620
|
}
|
|
1567
1621
|
const setupData = {
|
|
1568
1622
|
ceremonyInputData: {
|
|
@@ -1928,11 +1982,11 @@ const p256 = (proofPart) => {
|
|
|
1928
1982
|
*/
|
|
1929
1983
|
const formatSolidityCalldata = (circuitInput, _proof) => {
|
|
1930
1984
|
try {
|
|
1931
|
-
const proof =
|
|
1985
|
+
const proof = unstringifyBigInts(_proof);
|
|
1932
1986
|
// format the public inputs to the circuit
|
|
1933
1987
|
const formattedCircuitInput = [];
|
|
1934
1988
|
for (const cInput of circuitInput) {
|
|
1935
|
-
formattedCircuitInput.push(p256(
|
|
1989
|
+
formattedCircuitInput.push(p256(unstringifyBigInts(cInput)));
|
|
1936
1990
|
}
|
|
1937
1991
|
// construct calldata
|
|
1938
1992
|
const calldata = {
|
|
@@ -2314,8 +2368,8 @@ const createSSMClient = async () => {
|
|
|
2314
2368
|
* @returns <Array<string>> - the list of startup commands to be executed.
|
|
2315
2369
|
*/
|
|
2316
2370
|
const vmBootstrapCommand = (bucketName) => [
|
|
2317
|
-
"#!/bin/bash",
|
|
2318
|
-
`aws s3 cp s3://${bucketName}/${vmBootstrapScriptFilename} ${vmBootstrapScriptFilename}`,
|
|
2371
|
+
"#!/bin/bash", // shabang.
|
|
2372
|
+
`aws s3 cp s3://${bucketName}/${vmBootstrapScriptFilename} ${vmBootstrapScriptFilename}`, // copy file from S3 bucket to VM.
|
|
2319
2373
|
`chmod +x ${vmBootstrapScriptFilename} && bash ${vmBootstrapScriptFilename}` // grant permission and execute.
|
|
2320
2374
|
];
|
|
2321
2375
|
/**
|
|
@@ -2406,7 +2460,7 @@ const createEC2Instance = async (ec2, commands, instanceType, volumeSize, diskTy
|
|
|
2406
2460
|
DeviceName: "/dev/xvda",
|
|
2407
2461
|
Ebs: {
|
|
2408
2462
|
DeleteOnTermination: true,
|
|
2409
|
-
VolumeSize: volumeSize,
|
|
2463
|
+
VolumeSize: volumeSize, // disk size in GB.
|
|
2410
2464
|
VolumeType: diskType
|
|
2411
2465
|
}
|
|
2412
2466
|
}
|
|
@@ -2423,6 +2477,19 @@ const createEC2Instance = async (ec2, commands, instanceType, volumeSize, diskTy
|
|
|
2423
2477
|
{
|
|
2424
2478
|
Key: "Initialized",
|
|
2425
2479
|
Value: "false"
|
|
2480
|
+
},
|
|
2481
|
+
{
|
|
2482
|
+
Key: "ProjectName",
|
|
2483
|
+
Value: process.env.AWS_TAG_VALUE
|
|
2484
|
+
}
|
|
2485
|
+
]
|
|
2486
|
+
},
|
|
2487
|
+
{
|
|
2488
|
+
ResourceType: "volume",
|
|
2489
|
+
Tags: [
|
|
2490
|
+
{
|
|
2491
|
+
Key: "ProjectName",
|
|
2492
|
+
Value: process.env.AWS_TAG_VALUE
|
|
2426
2493
|
}
|
|
2427
2494
|
]
|
|
2428
2495
|
}
|
|
@@ -2606,6 +2673,7 @@ exports.completeMultiPartUpload = completeMultiPartUpload;
|
|
|
2606
2673
|
exports.computeDiskSizeForVM = computeDiskSizeForVM;
|
|
2607
2674
|
exports.computeSHA256ToHex = computeSHA256ToHex;
|
|
2608
2675
|
exports.computeSmallestPowersOfTauForCircuit = computeSmallestPowersOfTauForCircuit;
|
|
2676
|
+
exports.contribHashRegex = contribHashRegex;
|
|
2609
2677
|
exports.convertBytesOrKbToGb = convertBytesOrKbToGb;
|
|
2610
2678
|
exports.convertToDoubleDigits = convertToDoubleDigits;
|
|
2611
2679
|
exports.createCustomLoggerForFile = createCustomLoggerForFile;
|
|
@@ -2634,6 +2702,7 @@ exports.generatePreSignedUrlsParts = generatePreSignedUrlsParts;
|
|
|
2634
2702
|
exports.generateValidContributionsAttestation = generateValidContributionsAttestation;
|
|
2635
2703
|
exports.generateZkeyFromScratch = generateZkeyFromScratch;
|
|
2636
2704
|
exports.genesisZkeyIndex = genesisZkeyIndex;
|
|
2705
|
+
exports.getAllCeremonies = getAllCeremonies;
|
|
2637
2706
|
exports.getAllCollectionDocs = getAllCollectionDocs;
|
|
2638
2707
|
exports.getBucketName = getBucketName;
|
|
2639
2708
|
exports.getCeremonyCircuits = getCeremonyCircuits;
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
export declare const potFileDownloadMainUrl = "https://
|
|
2
|
-
export declare const potFilenameTemplate = "
|
|
1
|
+
export declare const potFileDownloadMainUrl = "https://pse-trusted-setup-ppot.s3.eu-central-1.amazonaws.com/pot28_0080/";
|
|
2
|
+
export declare const potFilenameTemplate = "ppot_0080_";
|
|
3
3
|
export declare const genesisZkeyIndex = "00000";
|
|
4
4
|
export declare const numExpIterations = 10;
|
|
5
5
|
export declare const solidityVersion = "0.8.0";
|
|
@@ -8,6 +8,7 @@ export declare const verificationKeyAcronym = "vkey";
|
|
|
8
8
|
export declare const verifierSmartContractAcronym = "verifier";
|
|
9
9
|
export declare const ec2InstanceTag = "p0tionec2instance";
|
|
10
10
|
export declare const vmBootstrapScriptFilename = "bootstrap.sh";
|
|
11
|
+
export declare const contribHashRegex: RegExp;
|
|
11
12
|
/**
|
|
12
13
|
* Define the supported VM configuration types.
|
|
13
14
|
* @dev the VM configurations can be retrieved at https://aws.amazon.com/ec2/instance-types/
|
|
@@ -195,6 +196,8 @@ export declare const commonTerms: {
|
|
|
195
196
|
finalizeCeremony: string;
|
|
196
197
|
downloadCircuitArtifacts: string;
|
|
197
198
|
transferObject: string;
|
|
199
|
+
bandadaValidateProof: string;
|
|
200
|
+
checkNonceOfSIWEAddress: string;
|
|
198
201
|
};
|
|
199
202
|
};
|
|
200
203
|
//# sourceMappingURL=constants.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"constants.d.ts","sourceRoot":"","sources":["../../../../src/helpers/constants.ts"],"names":[],"mappings":"AACA,eAAO,MAAM,sBAAsB
|
|
1
|
+
{"version":3,"file":"constants.d.ts","sourceRoot":"","sources":["../../../../src/helpers/constants.ts"],"names":[],"mappings":"AACA,eAAO,MAAM,sBAAsB,6EAA6E,CAAA;AAEhH,eAAO,MAAM,mBAAmB,eAAe,CAAA;AAE/C,eAAO,MAAM,gBAAgB,UAAU,CAAA;AAEvC,eAAO,MAAM,gBAAgB,KAAK,CAAA;AAElC,eAAO,MAAM,eAAe,UAAU,CAAA;AAEtC,eAAO,MAAM,sBAAsB,UAAU,CAAA;AAE7C,eAAO,MAAM,sBAAsB,SAAS,CAAA;AAE5C,eAAO,MAAM,4BAA4B,aAAa,CAAA;AAEtD,eAAO,MAAM,cAAc,sBAAsB,CAAA;AAEjD,eAAO,MAAM,yBAAyB,iBAAiB,CAAA;AAEvD,eAAO,MAAM,gBAAgB,QAAsE,CAAA;AAEnG;;;;;;GAMG;AACH,eAAO,MAAM,oBAAoB;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CA2ChC,CAAA;AAED;;;GAGG;AACH,eAAO,MAAM,gBAAgB;;;GAiH5B,CAAA;AAED;;;GAGG;AACH,eAAO,MAAM,WAAW;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CA+HvB,CAAA"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"contracts.d.ts","sourceRoot":"","sources":["../../../../src/helpers/contracts.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,QAAQ,EAAmB,MAAM,EAAE,MAAM,QAAQ,CAAA;
|
|
1
|
+
{"version":3,"file":"contracts.d.ts","sourceRoot":"","sources":["../../../../src/helpers/contracts.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,QAAQ,EAAmB,MAAM,EAAE,MAAM,QAAQ,CAAA;AAC1D,OAAO,EAAE,SAAS,EAAS,MAAM,oBAAoB,CAAA;AACrD,OAAO,EAAE,SAAS,EAAE,MAAM,oBAAoB,CAAA;AAiB9C;;;;;GAKG;AACH,eAAO,MAAM,IAAI,cAAe,GAAG,QAKlC,CAAA;AAED;;;;;;;;GAQG;AACH,eAAO,MAAM,sBAAsB,iBAAkB,MAAM,EAAE,UAAU,GAAG,KAAG,GAwB5E,CAAA;AAED;;;;;GAKG;AACH,eAAO,MAAM,yBAAyB,aAAoB,GAAG,SAAS,GAAG,KAAG,QAAQ,OAAO,CAG1F,CAAA;AAED;;;;GAIG;AACH,eAAO,MAAM,eAAe,iBAAwB,MAAM,KAAG,QAAQ,GAAG,CA6BvE,CAAA;AAED;;;;GAIG;AACH,eAAO,MAAM,sBAAsB,iBAAwB,MAAM,UAAU,MAAM,KAAG,QAAQ,QAAQ,CAOnG,CAAA;AAED;;;;;;;;;;;;;;;GAeG;AACH,eAAO,MAAM,cAAc,cACZ,SAAS,aACT,SAAS,kBACJ,MAAM,mBACL,MAAM,qBACJ,MAAM,wBACH,MAAM,UACpB,MAAM,WACL,GAAG,KACb,QAAQ,IAAI,CAkHd,CAAA"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"crypto.d.ts","sourceRoot":"","sources":["../../../../src/helpers/crypto.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,MAAM,IAAI,CAAA;AASnB;;;;GAIG;AACH,eAAO,MAAM,KAAK,WAAY,UAAU,KAAG,MAAoD,CAAA;AAE/F;;;;GAIG;AACH,eAAO,MAAM,gBAAgB,SAAgB,GAAG,QAAQ,KAAG,QAAQ,MAAM,CAaxE,CAAA;AAED;;;;GAIG;AACH,eAAO,MAAM,kBAAkB,UAAW,MAAM,KAAG,MAAiE,CAAA;AAEpH;;;;;GAKG;AACH,eAAO,MAAM,aAAa,UAAiB,MAAM,SAAS,MAAM,KAAG,QAAQ,OAAO,CAKjF,CAAA"}
|
|
1
|
+
{"version":3,"file":"crypto.d.ts","sourceRoot":"","sources":["../../../../src/helpers/crypto.ts"],"names":[],"mappings":";AAAA,OAAO,EAAE,MAAM,IAAI,CAAA;AASnB;;;;GAIG;AACH,eAAO,MAAM,KAAK,WAAY,UAAU,KAAG,MAAoD,CAAA;AAE/F;;;;GAIG;AACH,eAAO,MAAM,gBAAgB,SAAgB,GAAG,QAAQ,KAAG,QAAQ,MAAM,CAaxE,CAAA;AAED;;;;GAIG;AACH,eAAO,MAAM,kBAAkB,UAAW,MAAM,KAAG,MAAiE,CAAA;AAEpH;;;;;GAKG;AACH,eAAO,MAAM,aAAa,UAAiB,MAAM,SAAS,MAAM,KAAG,QAAQ,OAAO,CAKjF,CAAA"}
|
|
@@ -102,4 +102,12 @@ export declare const getCurrentActiveParticipantTimeout: (firestoreDatabase: Fir
|
|
|
102
102
|
* @returns <Promise<Array<FirebaseDocumentInfo>>> - the list of closed ceremonies.
|
|
103
103
|
*/
|
|
104
104
|
export declare const getClosedCeremonies: (firestoreDatabase: Firestore) => Promise<Array<FirebaseDocumentInfo>>;
|
|
105
|
+
/**
|
|
106
|
+
* Query all ceremonies
|
|
107
|
+
* @notice get all ceremonies from the database.
|
|
108
|
+
* @dev this is a helper for the CLI ceremony methods.
|
|
109
|
+
* @param firestoreDatabase <Firestore> - the Firestore service instance associated to the current Firebase application.
|
|
110
|
+
* @returns <Promise<Array<FirebaseDocumentInfo>>> - the list of all ceremonies.
|
|
111
|
+
*/
|
|
112
|
+
export declare const getAllCeremonies: (firestoreDatabase: Firestore) => Promise<Array<FirebaseDocumentInfo>>;
|
|
105
113
|
//# sourceMappingURL=database.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"database.d.ts","sourceRoot":"","sources":["../../../../src/helpers/database.ts"],"names":[],"mappings":"AAAA,OAAO,EAGH,YAAY,EACZ,gBAAgB,EAChB,SAAS,EAIT,eAAe,EACf,qBAAqB,EACrB,aAAa,EAGhB,MAAM,oBAAoB,CAAA;AAE3B,OAAO,EAAE,oBAAoB,EAAE,MAAM,gBAA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,CAAC,CAIxC,CAAA;AAED;;;;GAIG;AACH,eAAO,MAAM,mBAAmB,sBAA6B,SAAS,KAAG,QAAQ,MAAM,oBAAoB,CAAC,CAW3G,CAAA;AAED;;;;;;GAMG;AACH,eAAO,MAAM,mBAAmB,sBACT,SAAS,cAChB,MAAM,KACnB,QAAQ,MAAM,oBAAoB,CAAC,CAG6E,CAAA;AAEnH;;;;;;;;GAQG;AACH,eAAO,MAAM,sCAAsC,sBAC5B,SAAS,cAChB,MAAM,aACP,MAAM,iBACF,MAAM,KACtB,QAAQ,MAAM,oBAAoB,CAAC,CAQrC,CAAA;AAED;;;;;GAKG;AACH,eAAO,MAAM,kCAAkC,sBACxB,SAAS,cAChB,MAAM,iBACH,MAAM,KACtB,QAAQ,MAAM,oBAAoB,CAAC,CAQrC,CAAA;AAED;;;;;;GAMG;AACH,eAAO,MAAM,mBAAmB,sBAA6B,SAAS,KAAG,QAAQ,MAAM,oBAAoB,CAAC,CAW3G,CAAA;AAED;;;;;;GAMG;AACH,eAAO,MAAM,gBAAgB,sBAA6B,SAAS,KAAG,QAAQ,MAAM,oBAAoB,CAAC,CAIxG,CAAA"}
|
|
@@ -1,8 +1,9 @@
|
|
|
1
1
|
/// <reference types="node" />
|
|
2
|
+
/// <reference types="node" />
|
|
2
3
|
import { Firestore } from "firebase/firestore";
|
|
3
4
|
import { ReadPosition } from "fs";
|
|
4
5
|
import winston, { Logger } from "winston";
|
|
5
|
-
import { CircuitMetadata, Contribution, ContributionValidity, FirebaseDocumentInfo, SetupCeremonyData } from "../types/index";
|
|
6
|
+
import { CircuitMetadata, Contribution, ContributionValidity, FirebaseDocumentInfo, SetupCeremonyData, StringifiedBigInts, BigIntVariants } from "../types/index";
|
|
6
7
|
/**
|
|
7
8
|
* Return a string with double digits if the provided input is one digit only.
|
|
8
9
|
* @param in <number> - the input number to be converted.
|
|
@@ -118,6 +119,19 @@ export declare const createCustomLoggerForFile: (filename: string, level?: winst
|
|
|
118
119
|
* @returns <Buffer> - the buffer w/ the read bytes.
|
|
119
120
|
*/
|
|
120
121
|
export declare const readBytesFromFile: (localFilePath: string, offset: number, length: number, position: ReadPosition) => Buffer;
|
|
122
|
+
/**
|
|
123
|
+
* Given a buffer in little endian format, convert it to bigint
|
|
124
|
+
* @param buffer
|
|
125
|
+
* @returns
|
|
126
|
+
*/
|
|
127
|
+
export declare function leBufferToBigint(buffer: Buffer): bigint;
|
|
128
|
+
/**
|
|
129
|
+
* Given an input containing string values, convert them
|
|
130
|
+
* to bigint
|
|
131
|
+
* @param input - The input to convert
|
|
132
|
+
* @returns the input with string values converted to bigint
|
|
133
|
+
*/
|
|
134
|
+
export declare const unstringifyBigInts: (input: StringifiedBigInts) => BigIntVariants;
|
|
121
135
|
/**
|
|
122
136
|
* Return the info about the R1CS file.ù
|
|
123
137
|
* @dev this method was built taking inspiration from
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"utils.d.ts","sourceRoot":"","sources":["../../../../src/helpers/utils.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"utils.d.ts","sourceRoot":"","sources":["../../../../src/helpers/utils.ts"],"names":[],"mappings":";;AAAA,OAAO,EAAE,SAAS,EAAE,MAAM,oBAAoB,CAAA;AAC9C,OAAW,EAAE,YAAY,EAAqB,MAAM,IAAI,CAAA;AACxD,OAAO,OAAO,EAAE,EAAE,MAAM,EAAE,MAAM,SAAS,CAAA;AAIzC,OAAO,EACH,eAAe,EACf,YAAY,EAGZ,oBAAoB,EACpB,oBAAoB,EACpB,iBAAiB,EAGjB,kBAAkB,EAClB,cAAc,EACjB,MAAM,gBAAgB,CAAA;AAiBvB;;;;GAIG;AACH,eAAO,MAAM,qBAAqB,WAAY,MAAM,KAAG,MAA0D,CAAA;AAEjH;;;;;;;GAOG;AACH,eAAO,MAAM,aAAa,QAAS,MAAM,KAAG,MAEsC,CAAA;AAElF;;;;;;;GAOG;AACH,eAAO,MAAM,+BAA+B,iBAAkB,MAAM,UAAU,MAAM,KAA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AAM,GAAG,MAAM,CAEvD;AAED;;;;;GAKG;AACH,eAAO,MAAM,kBAAkB,UAAW,kBAAkB,KAAG,cAyB9D,CAAA;AAED;;;;;;;;GAQG;AACH,eAAO,MAAM,WAAW,sBAAuB,MAAM,KAAG,eA0IvD,CAAA;AAED;;;;;;GAMG;AACH,eAAO,MAAM,iBAAiB,SAAgB,MAAM,YAAW,OAAO,KAAW,QAAQ,iBAAiB,CA8NzG,CAAA"}
|
|
@@ -1,3 +1,4 @@
|
|
|
1
|
+
import { CircuitSignals, Groth16Proof, PublicSignals } from "snarkjs";
|
|
1
2
|
import { Firestore } from "firebase/firestore";
|
|
2
3
|
import { Functions } from "firebase/functions";
|
|
3
4
|
import { CeremonyArtifacts } from "../types/index";
|
|
@@ -18,7 +19,7 @@ export declare const verifyZKey: (r1csLocalFilePath: string, zkeyLocalPath: stri
|
|
|
18
19
|
* @param logger <any> Optional logger
|
|
19
20
|
* @returns <Promise<object>> The proof
|
|
20
21
|
*/
|
|
21
|
-
export declare const generateGROTH16Proof: (circuitInput:
|
|
22
|
+
export declare const generateGROTH16Proof: (circuitInput: CircuitSignals, zkeyFilePath: string, wasmFilePath: string, logger?: any) => Promise<any>;
|
|
22
23
|
/**
|
|
23
24
|
* Verifies a GROTH16 proof
|
|
24
25
|
* @param verificationKeyPath <string> Path to the verification key
|
|
@@ -26,7 +27,7 @@ export declare const generateGROTH16Proof: (circuitInput: object, zkeyFilePath:
|
|
|
26
27
|
* @param proof <object> Proof
|
|
27
28
|
* @returns <Promise<boolean>> Whether the proof is valid or not
|
|
28
29
|
*/
|
|
29
|
-
export declare const verifyGROTH16Proof: (verificationKeyPath: string, publicSignals:
|
|
30
|
+
export declare const verifyGROTH16Proof: (verificationKeyPath: string, publicSignals: PublicSignals, proof: Groth16Proof) => Promise<boolean>;
|
|
30
31
|
/**
|
|
31
32
|
* Helper method to extract the Solidity verifier
|
|
32
33
|
* from a final zKey file and save it to a local file.
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"verification.d.ts","sourceRoot":"","sources":["../../../../src/helpers/verification.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"verification.d.ts","sourceRoot":"","sources":["../../../../src/helpers/verification.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,cAAc,EAAE,YAAY,EAAE,aAAa,EAAiB,MAAM,SAAS,CAAA;AAEpF,OAAO,EAAE,SAAS,EAAS,MAAM,oBAAoB,CAAA;AACrD,OAAO,EAAE,SAAS,EAAE,MAAM,oBAAoB,CAAA;AAyB9C,OAAO,EAAE,iBAAiB,EAAE,MAAM,gBAAgB,CAAA;AAElD;;;;;;;GAOG;AACH,eAAO,MAAM,UAAU,sBACA,MAAM,iBACV,MAAM,oBACH,MAAM,WACf,GAAG,KACb,QAAQ,OAAO,CASjB,CAAA;AAED;;;;;;;GAOG;AACH,eAAO,MAAM,oBAAoB,iBACf,cAAc,gBACd,MAAM,gBACN,MAAM,WACX,GAAG,KACb,QAAQ,GAAG,CAYb,CAAA;AAED;;;;;;GAMG;AACH,eAAO,MAAM,kBAAkB,wBACN,MAAM,uCAEpB,YAAY,KACpB,QAAQ,OAAO,CAIjB,CAAA;AAED;;;;;GAKG;AACH,eAAO,MAAM,sBAAsB,kBAAyB,MAAM,gBAAgB,MAAM,iBAcvF,CAAA;AAED;;;;GAIG;AACH,eAAO,MAAM,UAAU,kBAAyB,MAAM,iBAGrD,CAAA;AAED;;;;;;;GAOG;AACH,eAAO,MAAM,qBAAqB,kBACf,MAAM,qBACF,MAAM,iBACV,MAAM,gBACP,MAAM,kBAMvB,CAAA;AAED;;;;;;;;;;GAUG;AACH,eAAO,MAAM,uBAAuB,iBAClB,OAAO,iBACN,MAAM,gBACP,MAAM,iBACL,MAAM,UACb,GAAG,mCACsB,MAAM,0BACf,MAAM,WACrB,MAAM,kBAqBlB,CAAA;AAED;;;;;;;;;;;GAWG;AACH,eAAO,MAAM,wBAAwB,sBACd,SAAS,cAChB,MAAM,cACN,MAAM,gBACJ,MAAM,gBACN,MAAM,eACP,MAAM,eACN,MAAM,WACV,OAAO,KACjB,QAAQ,OAAO,CAajB,CAAA;AAED;;;;;;;GAOG;AACH,eAAO,MAAM,4BAA4B,cAC1B,SAAS,aACT,SAAS,kBACJ,MAAM,mBACL,MAAM,KACxB,QAAQ,iBAAiB,EAAE,CAqF7B,CAAA;AAED;;;;;;;GAOG;AACH,eAAO,MAAM,0BAA0B,cACxB,SAAS,cACR,MAAM,aACP,MAAM,iBACF,MAAM,KACtB,QAAQ,MAAM,CAYhB,CAAA"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"vm.d.ts","sourceRoot":"","sources":["../../../../src/helpers/vm.ts"],"names":[],"mappings":"AAAA,OAAO,EAMH,SAAS,
|
|
1
|
+
{"version":3,"file":"vm.d.ts","sourceRoot":"","sources":["../../../../src/helpers/vm.ts"],"names":[],"mappings":"AAAA,OAAO,EAMH,SAAS,EAGZ,MAAM,qBAAqB,CAAA;AAC5B,OAAO,EAEH,SAAS,EAGZ,MAAM,qBAAqB,CAAA;AAE5B,OAAO,EAAE,aAAa,EAAE,MAAM,KAAK,CAAA;AACnC,OAAO,EAAE,WAAW,EAAE,MAAM,UAAU,CAAA;AAOtC;;;GAGG;AACH,eAAO,MAAM,eAAe,QAAa,QAAQ,SAAS,CAYzD,CAAA;AAED;;;GAGG;AACH,eAAO,MAAM,eAAe,QAAa,QAAQ,SAAS,CAYzD,CAAA;AAED;;;;;GAKG;AACH,eAAO,MAAM,kBAAkB,eAAgB,MAAM,KAAG,MAAM,MAAM,CAInE,CAAA;AAED;;;;;;;GAOG;AACH,eAAO,MAAM,sCAAsC,aACrC,MAAM,WACP,MAAM,YACL,MAAM,UACR,MAAM,KACf,MAAM,MAAM,CAyBd,CAAA;AAED;;;;;;;GAOG;AACH,eAAO,MAAM,iCAAiC,eAC9B,MAAM,uBACG,MAAM,gDACmB,MAAM,KACrD,MAAM,MAAM,CAOd,CAAA;AAED;;;;;;;GAOG;AACH,eAAO,MAAM,oBAAoB,oBAAqB,MAAM,OAAO,MAAM,KAAG,MACuB,CAAA;AAEnG;;;;;;;;GAQG;AACH,eAAO,MAAM,iBAAiB,QACrB,SAAS,YACJ,MAAM,EAAE,gBACJ,MAAM,cACR,MAAM,YACR,aAAa,KACxB,QAAQ,WAAW,CA6ErB,CAAA;AAED;;;;;GAKG;AACH,eAAO,MAAM,cAAc,cAAqB,SAAS,cAAc,MAAM,KAAG,QAAQ,OAAO,CAe9F,CAAA;AAED;;;;;GAKG;AACH,eAAO,MAAM,gBAAgB,QAAe,SAAS,cAAc,MAAM,kBAYxE,CAAA;AAED;;;;;GAKG;AACH,eAAO,MAAM,eAAe,QAAe,SAAS,cAAc,MAAM,kBAYvE,CAAA;AAED;;;;GAIG;AACH,eAAO,MAAM,oBAAoB,QAAe,SAAS,cAAc,MAAM,kBAc5E,CAAA;AAED;;;;;;;;GAQG;AACH,eAAO,MAAM,kBAAkB,QACtB,SAAS,cACF,MAAM,YACR,MAAM,MAAM,CAAC,KACxB,QAAQ,MAAM,CAwBhB,CAAA;AAED;;;;;;GAMG;AACH,eAAO,MAAM,qBAAqB,QAAe,SAAS,cAAc,MAAM,aAAa,MAAM,KAAG,QAAQ,MAAM,CAiBjH,CAAA;AAED;;;;;;GAMG;AACH,eAAO,MAAM,qBAAqB,QAAe,SAAS,cAAc,MAAM,aAAa,MAAM,KAAG,QAAQ,MAAM,CAgBjH,CAAA"}
|
|
@@ -1,9 +1,9 @@
|
|
|
1
1
|
export { downloadCeremonyArtifact, getBucketName, multiPartUpload, getR1csStorageFilePath, getPotStorageFilePath, getZkeyStorageFilePath, getVerificationKeyStorageFilePath, getVerifierContractStorageFilePath, getTranscriptStorageFilePath, getWasmStorageFilePath } from "./helpers/storage";
|
|
2
|
-
export { queryCollection, fromQueryToFirebaseDocumentInfo, getAllCollectionDocs, getCircuitContributionsFromContributor, getDocumentById, getCurrentActiveParticipantTimeout, getClosedCeremonies, getParticipantsCollectionPath, getCircuitsCollectionPath, getContributionsCollectionPath, getTimeoutsCollectionPath, getOpenedCeremonies, getCeremonyCircuits } from "./helpers/database";
|
|
2
|
+
export { queryCollection, fromQueryToFirebaseDocumentInfo, getAllCollectionDocs, getCircuitContributionsFromContributor, getDocumentById, getCurrentActiveParticipantTimeout, getClosedCeremonies, getParticipantsCollectionPath, getCircuitsCollectionPath, getContributionsCollectionPath, getTimeoutsCollectionPath, getOpenedCeremonies, getAllCeremonies, getCeremonyCircuits } from "./helpers/database";
|
|
3
3
|
export { compareCeremonyArtifacts, downloadAllCeremonyArtifacts, exportVerifierAndVKey, exportVerifierContract, exportVkey, generateGROTH16Proof, generateZkeyFromScratch, verifyGROTH16Proof, verifyZKey } from "./helpers/verification";
|
|
4
4
|
export { initializeFirebaseCoreServices } from "./helpers/services";
|
|
5
5
|
export { signInToFirebaseWithCredentials, getCurrentFirebaseAuthUser, isCoordinator } from "./helpers/authentication";
|
|
6
|
-
export { commonTerms, potFileDownloadMainUrl, potFilenameTemplate, genesisZkeyIndex, numExpIterations, solidityVersion, finalContributionIndex, verificationKeyAcronym, verifierSmartContractAcronym, ec2InstanceTag, vmConfigurationTypes, vmBootstrapScriptFilename, powersOfTauFiles } from "./helpers/constants";
|
|
6
|
+
export { commonTerms, potFileDownloadMainUrl, potFilenameTemplate, genesisZkeyIndex, numExpIterations, solidityVersion, finalContributionIndex, verificationKeyAcronym, verifierSmartContractAcronym, ec2InstanceTag, vmConfigurationTypes, vmBootstrapScriptFilename, powersOfTauFiles, contribHashRegex } from "./helpers/constants";
|
|
7
7
|
export { extractPrefix, extractPoTFromFilename, extractR1CSInfoValueForGivenKey, formatZkeyIndex, autoGenerateEntropy, getCircuitBySequencePosition, convertBytesOrKbToGb, getPublicAttestationPreambleForContributor, getContributionsValidityForContributor, generateValidContributionsAttestation, createCustomLoggerForFile, getR1CSInfo, computeSmallestPowersOfTauForCircuit, convertToDoubleDigits, parseCeremonyFile } from "./helpers/utils";
|
|
8
8
|
export { setupCeremony, checkParticipantForCeremony, progressToNextCircuitForContribution, resumeContributionAfterTimeoutExpiration, createS3Bucket, generateGetObjectPreSignedUrl, progressToNextContributionStep, permanentlyStoreCurrentContributionTimeAndHash, temporaryStoreCurrentContributionMultiPartUploadId, temporaryStoreCurrentContributionUploadedChunkData, generatePreSignedUrlsParts, completeMultiPartUpload, checkIfObjectExist, verifyContribution, checkAndPrepareCoordinatorForFinalization, finalizeCircuit, finalizeCeremony } from "./helpers/functions";
|
|
9
9
|
export { toHex, blake512FromPath, computeSHA256ToHex, compareHashes } from "./helpers/crypto";
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/index.ts"],"names":[],"mappings":"AAAA,OAAO,EACH,wBAAwB,EACxB,aAAa,EACb,eAAe,EACf,sBAAsB,EACtB,qBAAqB,EACrB,sBAAsB,EACtB,iCAAiC,EACjC,kCAAkC,EAClC,4BAA4B,EAC5B,sBAAsB,EACzB,MAAM,mBAAmB,CAAA;AAC1B,OAAO,EACH,eAAe,EACf,+BAA+B,EAC/B,oBAAoB,EACpB,sCAAsC,EACtC,eAAe,EACf,kCAAkC,EAClC,mBAAmB,EACnB,6BAA6B,EAC7B,yBAAyB,EACzB,8BAA8B,EAC9B,yBAAyB,EACzB,mBAAmB,EACnB,mBAAmB,EACtB,MAAM,oBAAoB,CAAA;AAC3B,OAAO,EACH,wBAAwB,EACxB,4BAA4B,EAC5B,qBAAqB,EACrB,sBAAsB,EACtB,UAAU,EACV,oBAAoB,EACpB,uBAAuB,EACvB,kBAAkB,EAClB,UAAU,EACb,MAAM,wBAAwB,CAAA;AAC/B,OAAO,EAAE,8BAA8B,EAAE,MAAM,oBAAoB,CAAA;AACnE,OAAO,EAAE,+BAA+B,EAAE,0BAA0B,EAAE,aAAa,EAAE,MAAM,0BAA0B,CAAA;AACrH,OAAO,EACH,WAAW,EACX,sBAAsB,EACtB,mBAAmB,EACnB,gBAAgB,EAChB,gBAAgB,EAChB,eA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AChB,YAAY,EACZ,oCAAoC,EACpC,mBAAmB,EACnB,eAAe,EACf,gBAAgB,EAChB,cAAc,EACd,mBAAmB,EACnB,eAAe,EACf,iBAAiB,EACjB,gCAAgC,EAChC,UAAU,EACV,oBAAoB,EACpB,+BAA+B,EAC/B,4BAA4B,EAC5B,gCAAgC,EAChC,mCAAmC,EACnC,iBAAiB,EACjB,oCAAoC,EACpC,gBAAgB,EAChB,mBAAmB,EACnB,YAAY,EACf,MAAM,eAAe,CAAA;AACtB,OAAO,EACH,iBAAiB,EACjB,oBAAoB,EACpB,eAAe,EACf,gBAAgB,EAChB,cAAc,EACd,kBAAkB,EAClB,sCAAsC,EACtC,qBAAqB,EACrB,oBAAoB,EACpB,eAAe,EACf,kBAAkB,EAClB,eAAe,EACf,iCAAiC,EACjC,qBAAqB,EACxB,MAAM,cAAc,CAAA"}
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/index.ts"],"names":[],"mappings":"AAAA,OAAO,EACH,wBAAwB,EACxB,aAAa,EACb,eAAe,EACf,sBAAsB,EACtB,qBAAqB,EACrB,sBAAsB,EACtB,iCAAiC,EACjC,kCAAkC,EAClC,4BAA4B,EAC5B,sBAAsB,EACzB,MAAM,mBAAmB,CAAA;AAC1B,OAAO,EACH,eAAe,EACf,+BAA+B,EAC/B,oBAAoB,EACpB,sCAAsC,EACtC,eAAe,EACf,kCAAkC,EAClC,mBAAmB,EACnB,6BAA6B,EAC7B,yBAAyB,EACzB,8BAA8B,EAC9B,yBAAyB,EACzB,mBAAmB,EACnB,gBAAgB,EAChB,mBAAmB,EACtB,MAAM,oBAAoB,CAAA;AAC3B,OAAO,EACH,wBAAwB,EACxB,4BAA4B,EAC5B,qBAAqB,EACrB,sBAAsB,EACtB,UAAU,EACV,oBAAoB,EACpB,uBAAuB,EACvB,kBAAkB,EAClB,UAAU,EACb,MAAM,wBAAwB,CAAA;AAC/B,OAAO,EAAE,8BAA8B,EAAE,MAAM,oBAAoB,C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B,MAAM,eAAe,CAAA;AACtB,OAAO,EACH,oBAAoB,EACpB,YAAY,EACZ,kBAAkB,EAClB,oBAAoB,EACpB,YAAY,EACZ,iBAAiB,EACjB,kBAAkB,EAClB,kBAAkB,EAClB,oBAAoB,EACpB,gBAAgB,EAChB,gBAAgB,EAChB,YAAY,EACZ,oCAAoC,EACpC,mBAAmB,EACnB,eAAe,EACf,gBAAgB,EAChB,cAAc,EACd,mBAAmB,EACnB,eAAe,EACf,iBAAiB,EACjB,gCAAgC,EAChC,UAAU,EACV,oBAAoB,EACpB,+BAA+B,EAC/B,4BAA4B,EAC5B,gCAAgC,EAChC,mCAAmC,EACnC,iBAAiB,EACjB,oCAAoC,EACpC,gBAAgB,EAChB,mBAAmB,EACnB,YAAY,EACf,MAAM,eAAe,CAAA;AACtB,OAAO,EACH,iBAAiB,EACjB,oBAAoB,EACpB,eAAe,EACf,gBAAgB,EAChB,cAAc,EACd,kBAAkB,EAClB,sCAAsC,EACtC,qBAAqB,EACrB,oBAAoB,EACpB,eAAe,EACf,kBAAkB,EAClB,eAAe,EACf,iCAAiC,EACjC,qBAAqB,EACxB,MAAM,cAAc,CAAA"}
|
|
@@ -170,7 +170,7 @@ export type VMConfiguration = {
|
|
|
170
170
|
/**
|
|
171
171
|
* Group information about the circuit contribution verification mechanism.
|
|
172
172
|
* @typedef {Object} CircuitContributionVerification
|
|
173
|
-
* @property {CircuitContributionVerificationMechanism} cfOrVm - the mechanism
|
|
173
|
+
* @property {CircuitContributionVerificationMechanism} cfOrVm - the mechanism chosen by the coordinator.
|
|
174
174
|
* @property {VMConfiguration} [vm] - the VM configuration specs.
|
|
175
175
|
*/
|
|
176
176
|
export type CircuitContributionVerification = {
|
|
@@ -600,4 +600,10 @@ export type CeremonySetupTemplate = {
|
|
|
600
600
|
penalty: number;
|
|
601
601
|
circuits: Array<CircuitDocument & CeremonySetupTemplateCircuitArtifacts & CeremonySetupTemplateCircuitTimeout & CeremonySetupTemplateCircuitName>;
|
|
602
602
|
};
|
|
603
|
+
export type StringifiedBigInts = StringifiedBigInts[] | string | string[] | string[][] | string[][][] | {
|
|
604
|
+
[key: string]: StringifiedBigInts;
|
|
605
|
+
} | null;
|
|
606
|
+
export type BigIntVariants = BigIntVariants[] | StringifiedBigInts | bigint | bigint[] | bigint[][] | bigint[][][] | {
|
|
607
|
+
[key: string]: BigIntVariants;
|
|
608
|
+
} | Uint8Array | null;
|
|
603
609
|
//# sourceMappingURL=index.d.ts.map
|