@semaphore-protocol/utils 4.0.0-beta.8 → 4.0.0

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.cjs CHANGED
@@ -1,6 +1,6 @@
1
1
  /**
2
2
  * @module @semaphore-protocol/utils
3
- * @version 4.0.0-beta.8
3
+ * @version 4.0.0
4
4
  * @file A library to provide utility functions to the other Semaphore packages.
5
5
  * @copyright Ethereum Foundation 2024
6
6
  * @license MIT
@@ -8,17 +8,940 @@
8
8
  */
9
9
  'use strict';
10
10
 
11
- var abi = require('ethers/abi');
11
+ var abi$1 = require('ethers/abi');
12
12
  var utils = require('ethers/utils');
13
13
 
14
- // TODO: Support all tree depths after trusted-setup. MAX_DEPTH would be 32.
14
+ var _format = "hh-sol-artifact-1";
15
+ var contractName = "Semaphore";
16
+ var sourceName = "contracts/Semaphore.sol";
17
+ var abi = [
18
+ {
19
+ inputs: [
20
+ {
21
+ internalType: "contract ISemaphoreVerifier",
22
+ name: "_verifier",
23
+ type: "address"
24
+ }
25
+ ],
26
+ stateMutability: "nonpayable",
27
+ type: "constructor"
28
+ },
29
+ {
30
+ inputs: [
31
+ ],
32
+ name: "LeafAlreadyExists",
33
+ type: "error"
34
+ },
35
+ {
36
+ inputs: [
37
+ ],
38
+ name: "LeafCannotBeZero",
39
+ type: "error"
40
+ },
41
+ {
42
+ inputs: [
43
+ ],
44
+ name: "LeafDoesNotExist",
45
+ type: "error"
46
+ },
47
+ {
48
+ inputs: [
49
+ ],
50
+ name: "LeafGreaterThanSnarkScalarField",
51
+ type: "error"
52
+ },
53
+ {
54
+ inputs: [
55
+ ],
56
+ name: "Semaphore__CallerIsNotTheGroupAdmin",
57
+ type: "error"
58
+ },
59
+ {
60
+ inputs: [
61
+ ],
62
+ name: "Semaphore__CallerIsNotThePendingGroupAdmin",
63
+ type: "error"
64
+ },
65
+ {
66
+ inputs: [
67
+ ],
68
+ name: "Semaphore__GroupDoesNotExist",
69
+ type: "error"
70
+ },
71
+ {
72
+ inputs: [
73
+ ],
74
+ name: "Semaphore__GroupHasNoMembers",
75
+ type: "error"
76
+ },
77
+ {
78
+ inputs: [
79
+ ],
80
+ name: "Semaphore__InvalidProof",
81
+ type: "error"
82
+ },
83
+ {
84
+ inputs: [
85
+ ],
86
+ name: "Semaphore__MerkleTreeDepthIsNotSupported",
87
+ type: "error"
88
+ },
89
+ {
90
+ inputs: [
91
+ ],
92
+ name: "Semaphore__MerkleTreeRootIsExpired",
93
+ type: "error"
94
+ },
95
+ {
96
+ inputs: [
97
+ ],
98
+ name: "Semaphore__MerkleTreeRootIsNotPartOfTheGroup",
99
+ type: "error"
100
+ },
101
+ {
102
+ inputs: [
103
+ ],
104
+ name: "Semaphore__YouAreUsingTheSameNullifierTwice",
105
+ type: "error"
106
+ },
107
+ {
108
+ inputs: [
109
+ ],
110
+ name: "WrongSiblingNodes",
111
+ type: "error"
112
+ },
113
+ {
114
+ anonymous: false,
115
+ inputs: [
116
+ {
117
+ indexed: true,
118
+ internalType: "uint256",
119
+ name: "groupId",
120
+ type: "uint256"
121
+ },
122
+ {
123
+ indexed: true,
124
+ internalType: "address",
125
+ name: "oldAdmin",
126
+ type: "address"
127
+ },
128
+ {
129
+ indexed: true,
130
+ internalType: "address",
131
+ name: "newAdmin",
132
+ type: "address"
133
+ }
134
+ ],
135
+ name: "GroupAdminPending",
136
+ type: "event"
137
+ },
138
+ {
139
+ anonymous: false,
140
+ inputs: [
141
+ {
142
+ indexed: true,
143
+ internalType: "uint256",
144
+ name: "groupId",
145
+ type: "uint256"
146
+ },
147
+ {
148
+ indexed: true,
149
+ internalType: "address",
150
+ name: "oldAdmin",
151
+ type: "address"
152
+ },
153
+ {
154
+ indexed: true,
155
+ internalType: "address",
156
+ name: "newAdmin",
157
+ type: "address"
158
+ }
159
+ ],
160
+ name: "GroupAdminUpdated",
161
+ type: "event"
162
+ },
163
+ {
164
+ anonymous: false,
165
+ inputs: [
166
+ {
167
+ indexed: true,
168
+ internalType: "uint256",
169
+ name: "groupId",
170
+ type: "uint256"
171
+ }
172
+ ],
173
+ name: "GroupCreated",
174
+ type: "event"
175
+ },
176
+ {
177
+ anonymous: false,
178
+ inputs: [
179
+ {
180
+ indexed: true,
181
+ internalType: "uint256",
182
+ name: "groupId",
183
+ type: "uint256"
184
+ },
185
+ {
186
+ indexed: false,
187
+ internalType: "uint256",
188
+ name: "oldMerkleTreeDuration",
189
+ type: "uint256"
190
+ },
191
+ {
192
+ indexed: false,
193
+ internalType: "uint256",
194
+ name: "newMerkleTreeDuration",
195
+ type: "uint256"
196
+ }
197
+ ],
198
+ name: "GroupMerkleTreeDurationUpdated",
199
+ type: "event"
200
+ },
201
+ {
202
+ anonymous: false,
203
+ inputs: [
204
+ {
205
+ indexed: true,
206
+ internalType: "uint256",
207
+ name: "groupId",
208
+ type: "uint256"
209
+ },
210
+ {
211
+ indexed: false,
212
+ internalType: "uint256",
213
+ name: "index",
214
+ type: "uint256"
215
+ },
216
+ {
217
+ indexed: false,
218
+ internalType: "uint256",
219
+ name: "identityCommitment",
220
+ type: "uint256"
221
+ },
222
+ {
223
+ indexed: false,
224
+ internalType: "uint256",
225
+ name: "merkleTreeRoot",
226
+ type: "uint256"
227
+ }
228
+ ],
229
+ name: "MemberAdded",
230
+ type: "event"
231
+ },
232
+ {
233
+ anonymous: false,
234
+ inputs: [
235
+ {
236
+ indexed: true,
237
+ internalType: "uint256",
238
+ name: "groupId",
239
+ type: "uint256"
240
+ },
241
+ {
242
+ indexed: false,
243
+ internalType: "uint256",
244
+ name: "index",
245
+ type: "uint256"
246
+ },
247
+ {
248
+ indexed: false,
249
+ internalType: "uint256",
250
+ name: "identityCommitment",
251
+ type: "uint256"
252
+ },
253
+ {
254
+ indexed: false,
255
+ internalType: "uint256",
256
+ name: "merkleTreeRoot",
257
+ type: "uint256"
258
+ }
259
+ ],
260
+ name: "MemberRemoved",
261
+ type: "event"
262
+ },
263
+ {
264
+ anonymous: false,
265
+ inputs: [
266
+ {
267
+ indexed: true,
268
+ internalType: "uint256",
269
+ name: "groupId",
270
+ type: "uint256"
271
+ },
272
+ {
273
+ indexed: false,
274
+ internalType: "uint256",
275
+ name: "index",
276
+ type: "uint256"
277
+ },
278
+ {
279
+ indexed: false,
280
+ internalType: "uint256",
281
+ name: "identityCommitment",
282
+ type: "uint256"
283
+ },
284
+ {
285
+ indexed: false,
286
+ internalType: "uint256",
287
+ name: "newIdentityCommitment",
288
+ type: "uint256"
289
+ },
290
+ {
291
+ indexed: false,
292
+ internalType: "uint256",
293
+ name: "merkleTreeRoot",
294
+ type: "uint256"
295
+ }
296
+ ],
297
+ name: "MemberUpdated",
298
+ type: "event"
299
+ },
300
+ {
301
+ anonymous: false,
302
+ inputs: [
303
+ {
304
+ indexed: true,
305
+ internalType: "uint256",
306
+ name: "groupId",
307
+ type: "uint256"
308
+ },
309
+ {
310
+ indexed: false,
311
+ internalType: "uint256",
312
+ name: "startIndex",
313
+ type: "uint256"
314
+ },
315
+ {
316
+ indexed: false,
317
+ internalType: "uint256[]",
318
+ name: "identityCommitments",
319
+ type: "uint256[]"
320
+ },
321
+ {
322
+ indexed: false,
323
+ internalType: "uint256",
324
+ name: "merkleTreeRoot",
325
+ type: "uint256"
326
+ }
327
+ ],
328
+ name: "MembersAdded",
329
+ type: "event"
330
+ },
331
+ {
332
+ anonymous: false,
333
+ inputs: [
334
+ {
335
+ indexed: true,
336
+ internalType: "uint256",
337
+ name: "groupId",
338
+ type: "uint256"
339
+ },
340
+ {
341
+ indexed: false,
342
+ internalType: "uint256",
343
+ name: "merkleTreeDepth",
344
+ type: "uint256"
345
+ },
346
+ {
347
+ indexed: true,
348
+ internalType: "uint256",
349
+ name: "merkleTreeRoot",
350
+ type: "uint256"
351
+ },
352
+ {
353
+ indexed: false,
354
+ internalType: "uint256",
355
+ name: "nullifier",
356
+ type: "uint256"
357
+ },
358
+ {
359
+ indexed: false,
360
+ internalType: "uint256",
361
+ name: "message",
362
+ type: "uint256"
363
+ },
364
+ {
365
+ indexed: true,
366
+ internalType: "uint256",
367
+ name: "scope",
368
+ type: "uint256"
369
+ },
370
+ {
371
+ indexed: false,
372
+ internalType: "uint256[8]",
373
+ name: "points",
374
+ type: "uint256[8]"
375
+ }
376
+ ],
377
+ name: "ProofValidated",
378
+ type: "event"
379
+ },
380
+ {
381
+ inputs: [
382
+ {
383
+ internalType: "uint256",
384
+ name: "groupId",
385
+ type: "uint256"
386
+ }
387
+ ],
388
+ name: "acceptGroupAdmin",
389
+ outputs: [
390
+ ],
391
+ stateMutability: "nonpayable",
392
+ type: "function"
393
+ },
394
+ {
395
+ inputs: [
396
+ {
397
+ internalType: "uint256",
398
+ name: "groupId",
399
+ type: "uint256"
400
+ },
401
+ {
402
+ internalType: "uint256",
403
+ name: "identityCommitment",
404
+ type: "uint256"
405
+ }
406
+ ],
407
+ name: "addMember",
408
+ outputs: [
409
+ ],
410
+ stateMutability: "nonpayable",
411
+ type: "function"
412
+ },
413
+ {
414
+ inputs: [
415
+ {
416
+ internalType: "uint256",
417
+ name: "groupId",
418
+ type: "uint256"
419
+ },
420
+ {
421
+ internalType: "uint256[]",
422
+ name: "identityCommitments",
423
+ type: "uint256[]"
424
+ }
425
+ ],
426
+ name: "addMembers",
427
+ outputs: [
428
+ ],
429
+ stateMutability: "nonpayable",
430
+ type: "function"
431
+ },
432
+ {
433
+ inputs: [
434
+ {
435
+ internalType: "address",
436
+ name: "admin",
437
+ type: "address"
438
+ },
439
+ {
440
+ internalType: "uint256",
441
+ name: "merkleTreeDuration",
442
+ type: "uint256"
443
+ }
444
+ ],
445
+ name: "createGroup",
446
+ outputs: [
447
+ {
448
+ internalType: "uint256",
449
+ name: "groupId",
450
+ type: "uint256"
451
+ }
452
+ ],
453
+ stateMutability: "nonpayable",
454
+ type: "function"
455
+ },
456
+ {
457
+ inputs: [
458
+ ],
459
+ name: "createGroup",
460
+ outputs: [
461
+ {
462
+ internalType: "uint256",
463
+ name: "groupId",
464
+ type: "uint256"
465
+ }
466
+ ],
467
+ stateMutability: "nonpayable",
468
+ type: "function"
469
+ },
470
+ {
471
+ inputs: [
472
+ {
473
+ internalType: "address",
474
+ name: "admin",
475
+ type: "address"
476
+ }
477
+ ],
478
+ name: "createGroup",
479
+ outputs: [
480
+ {
481
+ internalType: "uint256",
482
+ name: "groupId",
483
+ type: "uint256"
484
+ }
485
+ ],
486
+ stateMutability: "nonpayable",
487
+ type: "function"
488
+ },
489
+ {
490
+ inputs: [
491
+ {
492
+ internalType: "uint256",
493
+ name: "groupId",
494
+ type: "uint256"
495
+ }
496
+ ],
497
+ name: "getGroupAdmin",
498
+ outputs: [
499
+ {
500
+ internalType: "address",
501
+ name: "",
502
+ type: "address"
503
+ }
504
+ ],
505
+ stateMutability: "view",
506
+ type: "function"
507
+ },
508
+ {
509
+ inputs: [
510
+ {
511
+ internalType: "uint256",
512
+ name: "groupId",
513
+ type: "uint256"
514
+ }
515
+ ],
516
+ name: "getMerkleTreeDepth",
517
+ outputs: [
518
+ {
519
+ internalType: "uint256",
520
+ name: "",
521
+ type: "uint256"
522
+ }
523
+ ],
524
+ stateMutability: "view",
525
+ type: "function"
526
+ },
527
+ {
528
+ inputs: [
529
+ {
530
+ internalType: "uint256",
531
+ name: "groupId",
532
+ type: "uint256"
533
+ }
534
+ ],
535
+ name: "getMerkleTreeRoot",
536
+ outputs: [
537
+ {
538
+ internalType: "uint256",
539
+ name: "",
540
+ type: "uint256"
541
+ }
542
+ ],
543
+ stateMutability: "view",
544
+ type: "function"
545
+ },
546
+ {
547
+ inputs: [
548
+ {
549
+ internalType: "uint256",
550
+ name: "groupId",
551
+ type: "uint256"
552
+ }
553
+ ],
554
+ name: "getMerkleTreeSize",
555
+ outputs: [
556
+ {
557
+ internalType: "uint256",
558
+ name: "",
559
+ type: "uint256"
560
+ }
561
+ ],
562
+ stateMutability: "view",
563
+ type: "function"
564
+ },
565
+ {
566
+ inputs: [
567
+ ],
568
+ name: "groupCounter",
569
+ outputs: [
570
+ {
571
+ internalType: "uint256",
572
+ name: "",
573
+ type: "uint256"
574
+ }
575
+ ],
576
+ stateMutability: "view",
577
+ type: "function"
578
+ },
579
+ {
580
+ inputs: [
581
+ {
582
+ internalType: "uint256",
583
+ name: "",
584
+ type: "uint256"
585
+ }
586
+ ],
587
+ name: "groups",
588
+ outputs: [
589
+ {
590
+ internalType: "uint256",
591
+ name: "merkleTreeDuration",
592
+ type: "uint256"
593
+ }
594
+ ],
595
+ stateMutability: "view",
596
+ type: "function"
597
+ },
598
+ {
599
+ inputs: [
600
+ {
601
+ internalType: "uint256",
602
+ name: "groupId",
603
+ type: "uint256"
604
+ },
605
+ {
606
+ internalType: "uint256",
607
+ name: "identityCommitment",
608
+ type: "uint256"
609
+ }
610
+ ],
611
+ name: "hasMember",
612
+ outputs: [
613
+ {
614
+ internalType: "bool",
615
+ name: "",
616
+ type: "bool"
617
+ }
618
+ ],
619
+ stateMutability: "view",
620
+ type: "function"
621
+ },
622
+ {
623
+ inputs: [
624
+ {
625
+ internalType: "uint256",
626
+ name: "groupId",
627
+ type: "uint256"
628
+ },
629
+ {
630
+ internalType: "uint256",
631
+ name: "identityCommitment",
632
+ type: "uint256"
633
+ }
634
+ ],
635
+ name: "indexOf",
636
+ outputs: [
637
+ {
638
+ internalType: "uint256",
639
+ name: "",
640
+ type: "uint256"
641
+ }
642
+ ],
643
+ stateMutability: "view",
644
+ type: "function"
645
+ },
646
+ {
647
+ inputs: [
648
+ {
649
+ internalType: "uint256",
650
+ name: "groupId",
651
+ type: "uint256"
652
+ },
653
+ {
654
+ internalType: "uint256",
655
+ name: "identityCommitment",
656
+ type: "uint256"
657
+ },
658
+ {
659
+ internalType: "uint256[]",
660
+ name: "merkleProofSiblings",
661
+ type: "uint256[]"
662
+ }
663
+ ],
664
+ name: "removeMember",
665
+ outputs: [
666
+ ],
667
+ stateMutability: "nonpayable",
668
+ type: "function"
669
+ },
670
+ {
671
+ inputs: [
672
+ {
673
+ internalType: "uint256",
674
+ name: "groupId",
675
+ type: "uint256"
676
+ },
677
+ {
678
+ internalType: "address",
679
+ name: "newAdmin",
680
+ type: "address"
681
+ }
682
+ ],
683
+ name: "updateGroupAdmin",
684
+ outputs: [
685
+ ],
686
+ stateMutability: "nonpayable",
687
+ type: "function"
688
+ },
689
+ {
690
+ inputs: [
691
+ {
692
+ internalType: "uint256",
693
+ name: "groupId",
694
+ type: "uint256"
695
+ },
696
+ {
697
+ internalType: "uint256",
698
+ name: "newMerkleTreeDuration",
699
+ type: "uint256"
700
+ }
701
+ ],
702
+ name: "updateGroupMerkleTreeDuration",
703
+ outputs: [
704
+ ],
705
+ stateMutability: "nonpayable",
706
+ type: "function"
707
+ },
708
+ {
709
+ inputs: [
710
+ {
711
+ internalType: "uint256",
712
+ name: "groupId",
713
+ type: "uint256"
714
+ },
715
+ {
716
+ internalType: "uint256",
717
+ name: "identityCommitment",
718
+ type: "uint256"
719
+ },
720
+ {
721
+ internalType: "uint256",
722
+ name: "newIdentityCommitment",
723
+ type: "uint256"
724
+ },
725
+ {
726
+ internalType: "uint256[]",
727
+ name: "merkleProofSiblings",
728
+ type: "uint256[]"
729
+ }
730
+ ],
731
+ name: "updateMember",
732
+ outputs: [
733
+ ],
734
+ stateMutability: "nonpayable",
735
+ type: "function"
736
+ },
737
+ {
738
+ inputs: [
739
+ {
740
+ internalType: "uint256",
741
+ name: "groupId",
742
+ type: "uint256"
743
+ },
744
+ {
745
+ components: [
746
+ {
747
+ internalType: "uint256",
748
+ name: "merkleTreeDepth",
749
+ type: "uint256"
750
+ },
751
+ {
752
+ internalType: "uint256",
753
+ name: "merkleTreeRoot",
754
+ type: "uint256"
755
+ },
756
+ {
757
+ internalType: "uint256",
758
+ name: "nullifier",
759
+ type: "uint256"
760
+ },
761
+ {
762
+ internalType: "uint256",
763
+ name: "message",
764
+ type: "uint256"
765
+ },
766
+ {
767
+ internalType: "uint256",
768
+ name: "scope",
769
+ type: "uint256"
770
+ },
771
+ {
772
+ internalType: "uint256[8]",
773
+ name: "points",
774
+ type: "uint256[8]"
775
+ }
776
+ ],
777
+ internalType: "struct ISemaphore.SemaphoreProof",
778
+ name: "proof",
779
+ type: "tuple"
780
+ }
781
+ ],
782
+ name: "validateProof",
783
+ outputs: [
784
+ ],
785
+ stateMutability: "nonpayable",
786
+ type: "function"
787
+ },
788
+ {
789
+ inputs: [
790
+ ],
791
+ name: "verifier",
792
+ outputs: [
793
+ {
794
+ internalType: "contract ISemaphoreVerifier",
795
+ name: "",
796
+ type: "address"
797
+ }
798
+ ],
799
+ stateMutability: "view",
800
+ type: "function"
801
+ },
802
+ {
803
+ inputs: [
804
+ {
805
+ internalType: "uint256",
806
+ name: "groupId",
807
+ type: "uint256"
808
+ },
809
+ {
810
+ components: [
811
+ {
812
+ internalType: "uint256",
813
+ name: "merkleTreeDepth",
814
+ type: "uint256"
815
+ },
816
+ {
817
+ internalType: "uint256",
818
+ name: "merkleTreeRoot",
819
+ type: "uint256"
820
+ },
821
+ {
822
+ internalType: "uint256",
823
+ name: "nullifier",
824
+ type: "uint256"
825
+ },
826
+ {
827
+ internalType: "uint256",
828
+ name: "message",
829
+ type: "uint256"
830
+ },
831
+ {
832
+ internalType: "uint256",
833
+ name: "scope",
834
+ type: "uint256"
835
+ },
836
+ {
837
+ internalType: "uint256[8]",
838
+ name: "points",
839
+ type: "uint256[8]"
840
+ }
841
+ ],
842
+ internalType: "struct ISemaphore.SemaphoreProof",
843
+ name: "proof",
844
+ type: "tuple"
845
+ }
846
+ ],
847
+ name: "verifyProof",
848
+ outputs: [
849
+ {
850
+ internalType: "bool",
851
+ name: "",
852
+ type: "bool"
853
+ }
854
+ ],
855
+ stateMutability: "view",
856
+ type: "function"
857
+ }
858
+ ];
859
+ var bytecode = "0x608060405234801561001057600080fd5b5060405161201538038061201583398101604081905261002f91610054565b600380546001600160a01b0319166001600160a01b0392909216919091179055610084565b60006020828403121561006657600080fd5b81516001600160a01b038116811461007d57600080fd5b9392505050565b611f82806100936000396000f3fe608060405234801561001057600080fd5b50600436106101375760003560e01c80636389e107116100b8578063a9961c941161007c578063a9961c94146102b5578063d0d898dd146102de578063d24924fe146102f1578063da3cda52146102fa578063dabc4d511461030d578063fcf0b6ec1461032057600080fd5b80636389e1071461022c5780636cdd32fe1461024f5780637ee35a0c1461026257806390509d441461028257806396324bd41461029557600080fd5b80634178c4d5116100ff5780634178c4d5146101c8578063456f4188146101db578063568ee826146101fe578063575185ed146102115780635c3f3b601461021957600080fd5b8063042453711461013c57806306dd8485146101515780631783efc3146101775780632b7ac3f31461018a5780632c880363146101b5575b600080fd5b61014f61014a3660046119e2565b610333565b005b61016461015f366004611a2e565b610366565b6040519081526020015b60405180910390f35b61014f610185366004611a2e565b610387565b60035461019d906001600160a01b031681565b6040516001600160a01b03909116815260200161016e565b6101646101c3366004611a6c565b6103b8565b61014f6101d6366004611a96565b6103f0565b6101ee6101e9366004611af7565b610427565b604051901515815260200161016e565b61014f61020c366004611b31565b61068c565b61016461069a565b610164610227366004611b5d565b6106d1565b61016461023a366004611b78565b60009081526020819052604090206001015490565b61014f61025d366004611b91565b61070a565b610164610270366004611b78565b60009081526020819052604090205490565b6101ee610290366004611a2e565b61073f565b6101646102a3366004611b78565b60046020526000908152604090205481565b61019d6102c3366004611b78565b6000908152600160205260409020546001600160a01b031690565b61014f6102ec366004611af7565b610761565b61016460055481565b61014f610308366004611b78565b61084b565b61016461031b366004611b78565b610857565b61014f61032e366004611a2e565b61087b565b600061034084848461090b565b600094855260046020908152604080872092875260019092019052909320429055505050565b600082815260208190526040812061037e90836109a9565b90505b92915050565b600061039383836109f6565b6000938452600460209081526040808620928652600190920190529092204290555050565b60058054600091826103c983611bfa565b9190505590506103d98184610a98565b600081815260046020526040902091909155919050565b60006103ff8686868686610b22565b6000968752600460209081526040808920928952600190920190529095204290555050505050565b60008281526001602052604081205483906001600160a01b031661045e5760405163029f057960e01b815260040160405180910390fd5b60018335108061046f575060208335115b1561048d5760405163767b278960e11b815260040160405180910390fd5b600084815260208190526040812054908190036104bd5760405163c8b02e0160e01b815260040160405180910390fd5b60006104c886610857565b90508085602001351461054d576000868152600460208181526040808420898301358552600181018352908420548a855292909152549091829003610520576040516326994ac360e11b815260040160405180910390fd5b61052a8183611c13565b42111561054a576040516309581a9960e41b815260040160405180910390fd5b50505b60035460408051808201825260a0880135815260c088013560208083019190915282516080808201855260e08b01358286019081526101008c0135606080850191909152908352855180870187526101208d013581526101408d01358186015283850152855180870187526101608d013581526101808d01358186015286519283018752848d013583528c870135948301949094526001600160a01b039096169563a23f019995929392820190610606908d0135610be9565b81526020016106188c60800135610be9565b90526040516001600160e01b031960e087901b16815261064194939291908c3590600401611c88565b602060405180830381865afa15801561065e573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906106829190611d1b565b9695505050505050565b6106968282610c20565b5050565b60058054600091826106ab83611bfa565b9190505590506106bb8133610a98565b6000818152600460205260409020610e10905590565b60058054600091826106e283611bfa565b9190505590506106f28183610a98565b6000818152600460205260409020610e109055919050565b600061071885858585610cb4565b60009586526004602090815260408088209288526001909201905290942042905550505050565b600082815260208181526040808320848452600301909152812054151561037e565b600082815260046020908152604080832084820135845260020190915290205460ff16156107a25760405163041162bd60e31b815260040160405180910390fd5b6107ac8282610427565b6107c95760405163012a9af160e61b815260040160405180910390fd5b6000828152600460209081526040808320848201358085526002909101835292819020805460ff1916600117905551608084013592918401359185917f0c32e14cfe81a05d371c248d22de6b7ae849e981b76a1f8842e7b6da73fc405a9161083f918735919060608901359060a08a0190611d44565b60405180910390a45050565b61085481610d72565b50565b60008181526020818152604080832060018101548452600201909152812054610381565b60008281526001602052604090205482906001600160a01b031633146108b4576040516317737e4f60e31b815260040160405180910390fd5b60008381526004602090815260409182902080549085905582518181529182018590529185917f264b2a8f6763c084235fe832ba903482b2ef1a521336881fc75b987c2dfd29c5910160405180910390a250505050565b60008381526001602052604081205484906001600160a01b03163314610944576040516317737e4f60e31b815260040160405180910390fd5b6000858152602081905260409020805490610960908686610e17565b9250857f61e5e8054e3daf084a0c6c646c065e8bf5e7ca4d5567bda942309bd1652f349d828787876040516109989493929190611d6c565b60405180910390a250509392505050565b600081815260038301602052604081205481036109d957604051631c811d5b60e21b815260040160405180910390fd5b600082815260038401602052604090205461037e90600190611db2565b60008281526001602052604081205483906001600160a01b03163314610a2f576040516317737e4f60e31b815260040160405180910390fd5b6000848152602081905260409020805490610a4a9085611344565b604080518381526020810187905290810182905290935085907f19239b3f93cd10558aaf11423af70c77763bf54f52bcc75bfa74d4d13548cde99060600160405180910390a2505092915050565b60008281526001602052604080822080546001600160a01b0319166001600160a01b0385161790555183917ff0adfb94eab6daf835deb69c5738fe636150c3dfd08094a76f39b963dc8cb05a91a26040516001600160a01b0382169060009084907f0ba83579a0e79193ef649b9f5a8759d35af086ba62a3e207b52e4a8ae30d49e3908390a45050565b60008581526001602052604081205486906001600160a01b03163314610b5b576040516317737e4f60e31b815260040160405180910390fd5b6000878152602081905260408120610b7390886109a9565b6000898152602081905260409020909150610b91908888888861150d565b60408051838152602081018a90529081018890526060810182905290935088907fea3588e4a2a0c93d6a0e69dfeaf7496f43ccccf02ad9ce0a5b7627cbca4b61b19060800160405180910390a2505095945050505050565b6000600882604051602001610c0091815260200190565b60408051601f198184030181529190528051602090910120901c92915050565b60008281526001602052604090205482906001600160a01b03163314610c59576040516317737e4f60e31b815260040160405180910390fd5b60008381526002602052604080822080546001600160a01b0319166001600160a01b03861690811790915590519091339186917f1018365553cce55d9cb02ef73e18cc9311894f3fe1d1eafd235ac2d26cd8ba5891a4505050565b60008481526001602052604081205485906001600160a01b03163314610ced576040516317737e4f60e31b815260040160405180910390fd5b6000868152602081905260408120610d0590876109a9565b6000888152602081905260409020909150610d229087878761197d565b604080518381526020810189905290810182905290935087907f3108849c053c77b8073a11256dffb5ffd5b55e93e105a355e1c9061db890d8719060600160405180910390a25050949350505050565b6000818152600260205260409020546001600160a01b03163314610da9576040516334c4245d60e01b815260040160405180910390fd5b60008181526001602090815260408083208054336001600160a01b031980831682179093556002909452828520805490921690915590516001600160a01b0390911692839185917f0ba83579a0e79193ef649b9f5a8759d35af086ba62a3e207b52e4a8ae30d49e391a45050565b8254600090815b83811015610f4857600080516020611f2d833981519152858583818110610e4757610e47611c26565b9050602002013510610e6c576040516361c0541760e11b815260040160405180910390fd5b848482818110610e7e57610e7e611c26565b90506020020135600003610ea5576040516314b48df160e11b815260040160405180910390fd5b610eda86868684818110610ebb57610ebb611c26565b9050602002013560009081526003919091016020526040902054151590565b15610ef8576040516312c50cad60e11b815260040160405180910390fd5b80610f04836001611c13565b610f0e9190611c13565b866003016000878785818110610f2657610f26611c26565b6020908102929092013583525081019190915260400160002055600101610e1e565b50606084848080602002602001604051908101604052809392919081815260200183836020028082843760009201919091525050506001880154919250505b610f918584611c13565b610f9c826002611ea9565b1015610fb257610fab81611bfa565b9050610f87565b60018701819055826000610fc68783611c13565b9050600182811c90600090610fdb8185611db2565b610fe7911c6001611c13565b905060005b858110156112d85760006110008484611db2565b905060008167ffffffffffffffff81111561101d5761101d611eb5565b604051908082528060200260200182016040528015611046578160200160208202803683370190505b50905060005b82811015611203576000886110618884611c13565b61106c906002611ecb565b101561108f578f60020160008681526020019081526020016000205490506110cb565b8a8961109b8985611c13565b6110a6906002611ecb565b6110b09190611db2565b815181106110c0576110c0611c26565b602002602001015190505b6000886110d88985611c13565b6110e3906002611ecb565b6110ee906001611c13565b101561113b578b8a6111008a86611c13565b61110b906002611ecb565b611116906001611c13565b6111209190611db2565b8151811061113057611130611c26565b602002602001015190505b600081156111d357604080518082018252848152602081018490529051632b0aac7f60e11b815273__$75f79a42d9bcbdbb69ad79ebd80f556f39$__9163561558fe9161118b9190600401611ee2565b602060405180830381865af41580156111a8573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906111cc9190611f13565b90506111d6565b50815b808585815181106111e9576111e9611c26565b60200260200101818152505083600101935050505061104c565b5085600116600103611254578860018a5161121e9190611db2565b8151811061122e5761122e611c26565b60200260200101518e60020160008581526020019081526020016000208190555061129f565b60018951111561129f578860028a5161126d9190611db2565b8151811061127d5761127d611c26565b60200260200101518e6002016000858152602001908152602001600020819055505b849650600185901c9450809850839550600180856112bd9190611db2565b6112c9911c6001611c13565b93508260010192505050610fec565b506112e38988611c13565b8b55855186906000906112f8576112f8611c26565b60200260200101518b6002016000878152602001908152602001600020819055508560008151811061132c5761132c611c26565b60200260200101519750505050505050509392505050565b6000600080516020611f2d8339815191528210611374576040516361c0541760e11b815260040160405180910390fd5b81600003611395576040516314b48df160e11b815260040160405180910390fd5b6000828152600384016020526040902054156113c4576040516312c50cad60e11b815260040160405180910390fd5b8254600180850154906113d8908390611c13565b6113e3826002611ea9565b10156113f5576113f281611bfa565b90505b600185018190558360005b828110156114d2578084901c6001166001036114b657604080518082018252600083815260028a0160209081529083902054825281018490529051632b0aac7f60e11b815273__$75f79a42d9bcbdbb69ad79ebd80f556f39$__9163561558fe9161146e9190600401611ee2565b602060405180830381865af415801561148b573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906114af9190611f13565b91506114ca565b600081815260028801602052604090208290555b600101611400565b506114dc83611bfa565b8087556000928352600287016020908152604080852084905596845260039097019096529390209390935550919050565b6000600080516020611f2d833981519152841061153d576040516361c0541760e11b815260040160405180910390fd5b600085815260038701602052604090205461156b57604051631c811d5b60e21b815260040160405180910390fd5b60008481526003870160205260409020541561159a576040516312c50cad60e11b815260040160405180910390fd5b60006115a687876109a9565b8754909150859087906000906115be90600190611db2565b60018b0154909150600090815b818110156118f4578087901c60011660010361177e57600080516020611f2d8339815191528a8a8581811061160257611602611c26565b9050602002013510611627576040516361c0541760e11b815260040160405180910390fd5b73__$75f79a42d9bcbdbb69ad79ebd80f556f39$__63561558fe60405180604001604052808d8d8881811061165e5761165e611c26565b905060200201358152602001898152506040518263ffffffff1660e01b815260040161168a9190611ee2565b602060405180830381865af41580156116a7573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906116cb9190611f13565b955073__$75f79a42d9bcbdbb69ad79ebd80f556f39$__63561558fe60405180604001604052808d8d8881811061170457611704611c26565b905060200201358152602001888152506040518263ffffffff1660e01b81526004016117309190611ee2565b602060405180830381865af415801561174d573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906117719190611f13565b94508260010192506118ec565b86811c84821c146118d857600080516020611f2d8339815191528a8a858181106117aa576117aa611c26565b90506020020135106117cf576040516361c0541760e11b815260040160405180910390fd5b73__$75f79a42d9bcbdbb69ad79ebd80f556f39$__63561558fe60405180604001604052808981526020018d8d8881811061180c5761180c611c26565b905060200201358152506040518263ffffffff1660e01b81526004016118329190611ee2565b602060405180830381865af415801561184f573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906118739190611f13565b955073__$75f79a42d9bcbdbb69ad79ebd80f556f39$__63561558fe60405180604001604052808881526020018d8d888181106118b2576118b2611c26565b905060200201358152506040518263ffffffff1660e01b81526004016117309190611ee2565b600083815260028e01602052604090208690555b6001016115cb565b5060018c0154600090815260028d016020526040902054841461192a57604051631fd4986360e11b815260040160405180910390fd5b600081815260028d0160205260409020859055891561195c5760008b815260038d016020526040808220548c83529120555b505050600088815260038a0160205260408120555091505095945050505050565b600061198d85856000868661150d565b95945050505050565b60008083601f8401126119a857600080fd5b50813567ffffffffffffffff8111156119c057600080fd5b6020830191508360208260051b85010111156119db57600080fd5b9250929050565b6000806000604084860312156119f757600080fd5b83359250602084013567ffffffffffffffff811115611a1557600080fd5b611a2186828701611996565b9497909650939450505050565b60008060408385031215611a4157600080fd5b50508035926020909101359150565b80356001600160a01b0381168114611a6757600080fd5b919050565b60008060408385031215611a7f57600080fd5b611a8883611a50565b946020939093013593505050565b600080600080600060808688031215611aae57600080fd5b853594506020860135935060408601359250606086013567ffffffffffffffff811115611ada57600080fd5b611ae688828901611996565b969995985093965092949392505050565b6000808284036101c0811215611b0c57600080fd5b833592506101a0601f1982011215611b2357600080fd5b506020830190509250929050565b60008060408385031215611b4457600080fd5b82359150611b5460208401611a50565b90509250929050565b600060208284031215611b6f57600080fd5b61037e82611a50565b600060208284031215611b8a57600080fd5b5035919050565b60008060008060608587031215611ba757600080fd5b8435935060208501359250604085013567ffffffffffffffff811115611bcc57600080fd5b611bd887828801611996565b95989497509550505050565b634e487b7160e01b600052601160045260246000fd5b600060018201611c0c57611c0c611be4565b5060010190565b8082018082111561038157610381611be4565b634e487b7160e01b600052603260045260246000fd5b8060005b6002811015611c5f578151845260209384019390910190600101611c40565b50505050565b8060005b6004811015611c5f578151845260209384019390910190600101611c69565b6101a08101611c978288611c3c565b6040808301876000805b6002808210611cb05750611cea565b835185845b83811015611cd3578251825260209283019290910190600101611cb5565b505050938501935060209290920191600101611ca1565b5050505050611cfc60c0830186611c3c565b611d0a610100830185611c65565b826101808301529695505050505050565b600060208284031215611d2d57600080fd5b81518015158114611d3d57600080fd5b9392505050565b8481526020810184905260408101839052610160810161010083606084013795945050505050565b848152606060208201819052810183905260006001600160fb1b03841115611d9357600080fd5b8360051b80866080850137604083019390935250016080019392505050565b8181038181111561038157610381611be4565b600181815b80851115611e00578160001904821115611de657611de6611be4565b80851615611df357918102915b93841c9390800290611dca565b509250929050565b600082611e1757506001610381565b81611e2457506000610381565b8160018114611e3a5760028114611e4457611e60565b6001915050610381565b60ff841115611e5557611e55611be4565b50506001821b610381565b5060208310610133831016604e8410600b8410161715611e83575081810a610381565b611e8d8383611dc5565b8060001904821115611ea157611ea1611be4565b029392505050565b600061037e8383611e08565b634e487b7160e01b600052604160045260246000fd5b808202811582820484141761038157610381611be4565b60408101818360005b6002811015611f0a578151835260209283019290910190600101611eeb565b50505092915050565b600060208284031215611f2557600080fd5b505191905056fe30644e72e131a029b85045b68181585d2833e84879b9709143e1f593f0000001a2646970667358221220164ddea4e67fb9956ad9d73065c0b85ecf9b8062f67bcc5be446364b9475660664736f6c63430008170033";
860
+ var deployedBytecode = "0x608060405234801561001057600080fd5b50600436106101375760003560e01c80636389e107116100b8578063a9961c941161007c578063a9961c94146102b5578063d0d898dd146102de578063d24924fe146102f1578063da3cda52146102fa578063dabc4d511461030d578063fcf0b6ec1461032057600080fd5b80636389e1071461022c5780636cdd32fe1461024f5780637ee35a0c1461026257806390509d441461028257806396324bd41461029557600080fd5b80634178c4d5116100ff5780634178c4d5146101c8578063456f4188146101db578063568ee826146101fe578063575185ed146102115780635c3f3b601461021957600080fd5b8063042453711461013c57806306dd8485146101515780631783efc3146101775780632b7ac3f31461018a5780632c880363146101b5575b600080fd5b61014f61014a3660046119e2565b610333565b005b61016461015f366004611a2e565b610366565b6040519081526020015b60405180910390f35b61014f610185366004611a2e565b610387565b60035461019d906001600160a01b031681565b6040516001600160a01b03909116815260200161016e565b6101646101c3366004611a6c565b6103b8565b61014f6101d6366004611a96565b6103f0565b6101ee6101e9366004611af7565b610427565b604051901515815260200161016e565b61014f61020c366004611b31565b61068c565b61016461069a565b610164610227366004611b5d565b6106d1565b61016461023a366004611b78565b60009081526020819052604090206001015490565b61014f61025d366004611b91565b61070a565b610164610270366004611b78565b60009081526020819052604090205490565b6101ee610290366004611a2e565b61073f565b6101646102a3366004611b78565b60046020526000908152604090205481565b61019d6102c3366004611b78565b6000908152600160205260409020546001600160a01b031690565b61014f6102ec366004611af7565b610761565b61016460055481565b61014f610308366004611b78565b61084b565b61016461031b366004611b78565b610857565b61014f61032e366004611a2e565b61087b565b600061034084848461090b565b600094855260046020908152604080872092875260019092019052909320429055505050565b600082815260208190526040812061037e90836109a9565b90505b92915050565b600061039383836109f6565b6000938452600460209081526040808620928652600190920190529092204290555050565b60058054600091826103c983611bfa565b9190505590506103d98184610a98565b600081815260046020526040902091909155919050565b60006103ff8686868686610b22565b6000968752600460209081526040808920928952600190920190529095204290555050505050565b60008281526001602052604081205483906001600160a01b031661045e5760405163029f057960e01b815260040160405180910390fd5b60018335108061046f575060208335115b1561048d5760405163767b278960e11b815260040160405180910390fd5b600084815260208190526040812054908190036104bd5760405163c8b02e0160e01b815260040160405180910390fd5b60006104c886610857565b90508085602001351461054d576000868152600460208181526040808420898301358552600181018352908420548a855292909152549091829003610520576040516326994ac360e11b815260040160405180910390fd5b61052a8183611c13565b42111561054a576040516309581a9960e41b815260040160405180910390fd5b50505b60035460408051808201825260a0880135815260c088013560208083019190915282516080808201855260e08b01358286019081526101008c0135606080850191909152908352855180870187526101208d013581526101408d01358186015283850152855180870187526101608d013581526101808d01358186015286519283018752848d013583528c870135948301949094526001600160a01b039096169563a23f019995929392820190610606908d0135610be9565b81526020016106188c60800135610be9565b90526040516001600160e01b031960e087901b16815261064194939291908c3590600401611c88565b602060405180830381865afa15801561065e573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906106829190611d1b565b9695505050505050565b6106968282610c20565b5050565b60058054600091826106ab83611bfa565b9190505590506106bb8133610a98565b6000818152600460205260409020610e10905590565b60058054600091826106e283611bfa565b9190505590506106f28183610a98565b6000818152600460205260409020610e109055919050565b600061071885858585610cb4565b60009586526004602090815260408088209288526001909201905290942042905550505050565b600082815260208181526040808320848452600301909152812054151561037e565b600082815260046020908152604080832084820135845260020190915290205460ff16156107a25760405163041162bd60e31b815260040160405180910390fd5b6107ac8282610427565b6107c95760405163012a9af160e61b815260040160405180910390fd5b6000828152600460209081526040808320848201358085526002909101835292819020805460ff1916600117905551608084013592918401359185917f0c32e14cfe81a05d371c248d22de6b7ae849e981b76a1f8842e7b6da73fc405a9161083f918735919060608901359060a08a0190611d44565b60405180910390a45050565b61085481610d72565b50565b60008181526020818152604080832060018101548452600201909152812054610381565b60008281526001602052604090205482906001600160a01b031633146108b4576040516317737e4f60e31b815260040160405180910390fd5b60008381526004602090815260409182902080549085905582518181529182018590529185917f264b2a8f6763c084235fe832ba903482b2ef1a521336881fc75b987c2dfd29c5910160405180910390a250505050565b60008381526001602052604081205484906001600160a01b03163314610944576040516317737e4f60e31b815260040160405180910390fd5b6000858152602081905260409020805490610960908686610e17565b9250857f61e5e8054e3daf084a0c6c646c065e8bf5e7ca4d5567bda942309bd1652f349d828787876040516109989493929190611d6c565b60405180910390a250509392505050565b600081815260038301602052604081205481036109d957604051631c811d5b60e21b815260040160405180910390fd5b600082815260038401602052604090205461037e90600190611db2565b60008281526001602052604081205483906001600160a01b03163314610a2f576040516317737e4f60e31b815260040160405180910390fd5b6000848152602081905260409020805490610a4a9085611344565b604080518381526020810187905290810182905290935085907f19239b3f93cd10558aaf11423af70c77763bf54f52bcc75bfa74d4d13548cde99060600160405180910390a2505092915050565b60008281526001602052604080822080546001600160a01b0319166001600160a01b0385161790555183917ff0adfb94eab6daf835deb69c5738fe636150c3dfd08094a76f39b963dc8cb05a91a26040516001600160a01b0382169060009084907f0ba83579a0e79193ef649b9f5a8759d35af086ba62a3e207b52e4a8ae30d49e3908390a45050565b60008581526001602052604081205486906001600160a01b03163314610b5b576040516317737e4f60e31b815260040160405180910390fd5b6000878152602081905260408120610b7390886109a9565b6000898152602081905260409020909150610b91908888888861150d565b60408051838152602081018a90529081018890526060810182905290935088907fea3588e4a2a0c93d6a0e69dfeaf7496f43ccccf02ad9ce0a5b7627cbca4b61b19060800160405180910390a2505095945050505050565b6000600882604051602001610c0091815260200190565b60408051601f198184030181529190528051602090910120901c92915050565b60008281526001602052604090205482906001600160a01b03163314610c59576040516317737e4f60e31b815260040160405180910390fd5b60008381526002602052604080822080546001600160a01b0319166001600160a01b03861690811790915590519091339186917f1018365553cce55d9cb02ef73e18cc9311894f3fe1d1eafd235ac2d26cd8ba5891a4505050565b60008481526001602052604081205485906001600160a01b03163314610ced576040516317737e4f60e31b815260040160405180910390fd5b6000868152602081905260408120610d0590876109a9565b6000888152602081905260409020909150610d229087878761197d565b604080518381526020810189905290810182905290935087907f3108849c053c77b8073a11256dffb5ffd5b55e93e105a355e1c9061db890d8719060600160405180910390a25050949350505050565b6000818152600260205260409020546001600160a01b03163314610da9576040516334c4245d60e01b815260040160405180910390fd5b60008181526001602090815260408083208054336001600160a01b031980831682179093556002909452828520805490921690915590516001600160a01b0390911692839185917f0ba83579a0e79193ef649b9f5a8759d35af086ba62a3e207b52e4a8ae30d49e391a45050565b8254600090815b83811015610f4857600080516020611f2d833981519152858583818110610e4757610e47611c26565b9050602002013510610e6c576040516361c0541760e11b815260040160405180910390fd5b848482818110610e7e57610e7e611c26565b90506020020135600003610ea5576040516314b48df160e11b815260040160405180910390fd5b610eda86868684818110610ebb57610ebb611c26565b9050602002013560009081526003919091016020526040902054151590565b15610ef8576040516312c50cad60e11b815260040160405180910390fd5b80610f04836001611c13565b610f0e9190611c13565b866003016000878785818110610f2657610f26611c26565b6020908102929092013583525081019190915260400160002055600101610e1e565b50606084848080602002602001604051908101604052809392919081815260200183836020028082843760009201919091525050506001880154919250505b610f918584611c13565b610f9c826002611ea9565b1015610fb257610fab81611bfa565b9050610f87565b60018701819055826000610fc68783611c13565b9050600182811c90600090610fdb8185611db2565b610fe7911c6001611c13565b905060005b858110156112d85760006110008484611db2565b905060008167ffffffffffffffff81111561101d5761101d611eb5565b604051908082528060200260200182016040528015611046578160200160208202803683370190505b50905060005b82811015611203576000886110618884611c13565b61106c906002611ecb565b101561108f578f60020160008681526020019081526020016000205490506110cb565b8a8961109b8985611c13565b6110a6906002611ecb565b6110b09190611db2565b815181106110c0576110c0611c26565b602002602001015190505b6000886110d88985611c13565b6110e3906002611ecb565b6110ee906001611c13565b101561113b578b8a6111008a86611c13565b61110b906002611ecb565b611116906001611c13565b6111209190611db2565b8151811061113057611130611c26565b602002602001015190505b600081156111d357604080518082018252848152602081018490529051632b0aac7f60e11b815273__$75f79a42d9bcbdbb69ad79ebd80f556f39$__9163561558fe9161118b9190600401611ee2565b602060405180830381865af41580156111a8573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906111cc9190611f13565b90506111d6565b50815b808585815181106111e9576111e9611c26565b60200260200101818152505083600101935050505061104c565b5085600116600103611254578860018a5161121e9190611db2565b8151811061122e5761122e611c26565b60200260200101518e60020160008581526020019081526020016000208190555061129f565b60018951111561129f578860028a5161126d9190611db2565b8151811061127d5761127d611c26565b60200260200101518e6002016000858152602001908152602001600020819055505b849650600185901c9450809850839550600180856112bd9190611db2565b6112c9911c6001611c13565b93508260010192505050610fec565b506112e38988611c13565b8b55855186906000906112f8576112f8611c26565b60200260200101518b6002016000878152602001908152602001600020819055508560008151811061132c5761132c611c26565b60200260200101519750505050505050509392505050565b6000600080516020611f2d8339815191528210611374576040516361c0541760e11b815260040160405180910390fd5b81600003611395576040516314b48df160e11b815260040160405180910390fd5b6000828152600384016020526040902054156113c4576040516312c50cad60e11b815260040160405180910390fd5b8254600180850154906113d8908390611c13565b6113e3826002611ea9565b10156113f5576113f281611bfa565b90505b600185018190558360005b828110156114d2578084901c6001166001036114b657604080518082018252600083815260028a0160209081529083902054825281018490529051632b0aac7f60e11b815273__$75f79a42d9bcbdbb69ad79ebd80f556f39$__9163561558fe9161146e9190600401611ee2565b602060405180830381865af415801561148b573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906114af9190611f13565b91506114ca565b600081815260028801602052604090208290555b600101611400565b506114dc83611bfa565b8087556000928352600287016020908152604080852084905596845260039097019096529390209390935550919050565b6000600080516020611f2d833981519152841061153d576040516361c0541760e11b815260040160405180910390fd5b600085815260038701602052604090205461156b57604051631c811d5b60e21b815260040160405180910390fd5b60008481526003870160205260409020541561159a576040516312c50cad60e11b815260040160405180910390fd5b60006115a687876109a9565b8754909150859087906000906115be90600190611db2565b60018b0154909150600090815b818110156118f4578087901c60011660010361177e57600080516020611f2d8339815191528a8a8581811061160257611602611c26565b9050602002013510611627576040516361c0541760e11b815260040160405180910390fd5b73__$75f79a42d9bcbdbb69ad79ebd80f556f39$__63561558fe60405180604001604052808d8d8881811061165e5761165e611c26565b905060200201358152602001898152506040518263ffffffff1660e01b815260040161168a9190611ee2565b602060405180830381865af41580156116a7573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906116cb9190611f13565b955073__$75f79a42d9bcbdbb69ad79ebd80f556f39$__63561558fe60405180604001604052808d8d8881811061170457611704611c26565b905060200201358152602001888152506040518263ffffffff1660e01b81526004016117309190611ee2565b602060405180830381865af415801561174d573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906117719190611f13565b94508260010192506118ec565b86811c84821c146118d857600080516020611f2d8339815191528a8a858181106117aa576117aa611c26565b90506020020135106117cf576040516361c0541760e11b815260040160405180910390fd5b73__$75f79a42d9bcbdbb69ad79ebd80f556f39$__63561558fe60405180604001604052808981526020018d8d8881811061180c5761180c611c26565b905060200201358152506040518263ffffffff1660e01b81526004016118329190611ee2565b602060405180830381865af415801561184f573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906118739190611f13565b955073__$75f79a42d9bcbdbb69ad79ebd80f556f39$__63561558fe60405180604001604052808881526020018d8d888181106118b2576118b2611c26565b905060200201358152506040518263ffffffff1660e01b81526004016117309190611ee2565b600083815260028e01602052604090208690555b6001016115cb565b5060018c0154600090815260028d016020526040902054841461192a57604051631fd4986360e11b815260040160405180910390fd5b600081815260028d0160205260409020859055891561195c5760008b815260038d016020526040808220548c83529120555b505050600088815260038a0160205260408120555091505095945050505050565b600061198d85856000868661150d565b95945050505050565b60008083601f8401126119a857600080fd5b50813567ffffffffffffffff8111156119c057600080fd5b6020830191508360208260051b85010111156119db57600080fd5b9250929050565b6000806000604084860312156119f757600080fd5b83359250602084013567ffffffffffffffff811115611a1557600080fd5b611a2186828701611996565b9497909650939450505050565b60008060408385031215611a4157600080fd5b50508035926020909101359150565b80356001600160a01b0381168114611a6757600080fd5b919050565b60008060408385031215611a7f57600080fd5b611a8883611a50565b946020939093013593505050565b600080600080600060808688031215611aae57600080fd5b853594506020860135935060408601359250606086013567ffffffffffffffff811115611ada57600080fd5b611ae688828901611996565b969995985093965092949392505050565b6000808284036101c0811215611b0c57600080fd5b833592506101a0601f1982011215611b2357600080fd5b506020830190509250929050565b60008060408385031215611b4457600080fd5b82359150611b5460208401611a50565b90509250929050565b600060208284031215611b6f57600080fd5b61037e82611a50565b600060208284031215611b8a57600080fd5b5035919050565b60008060008060608587031215611ba757600080fd5b8435935060208501359250604085013567ffffffffffffffff811115611bcc57600080fd5b611bd887828801611996565b95989497509550505050565b634e487b7160e01b600052601160045260246000fd5b600060018201611c0c57611c0c611be4565b5060010190565b8082018082111561038157610381611be4565b634e487b7160e01b600052603260045260246000fd5b8060005b6002811015611c5f578151845260209384019390910190600101611c40565b50505050565b8060005b6004811015611c5f578151845260209384019390910190600101611c69565b6101a08101611c978288611c3c565b6040808301876000805b6002808210611cb05750611cea565b835185845b83811015611cd3578251825260209283019290910190600101611cb5565b505050938501935060209290920191600101611ca1565b5050505050611cfc60c0830186611c3c565b611d0a610100830185611c65565b826101808301529695505050505050565b600060208284031215611d2d57600080fd5b81518015158114611d3d57600080fd5b9392505050565b8481526020810184905260408101839052610160810161010083606084013795945050505050565b848152606060208201819052810183905260006001600160fb1b03841115611d9357600080fd5b8360051b80866080850137604083019390935250016080019392505050565b8181038181111561038157610381611be4565b600181815b80851115611e00578160001904821115611de657611de6611be4565b80851615611df357918102915b93841c9390800290611dca565b509250929050565b600082611e1757506001610381565b81611e2457506000610381565b8160018114611e3a5760028114611e4457611e60565b6001915050610381565b60ff841115611e5557611e55611be4565b50506001821b610381565b5060208310610133831016604e8410600b8410161715611e83575081810a610381565b611e8d8383611dc5565b8060001904821115611ea157611ea1611be4565b029392505050565b600061037e8383611e08565b634e487b7160e01b600052604160045260246000fd5b808202811582820484141761038157610381611be4565b60408101818360005b6002811015611f0a578151835260209283019290910190600101611eeb565b50505092915050565b600060208284031215611f2557600080fd5b505191905056fe30644e72e131a029b85045b68181585d2833e84879b9709143e1f593f0000001a2646970667358221220164ddea4e67fb9956ad9d73065c0b85ecf9b8062f67bcc5be446364b9475660664736f6c63430008170033";
861
+ var linkReferences = {
862
+ "poseidon-solidity/PoseidonT3.sol": {
863
+ PoseidonT3: [
864
+ {
865
+ length: 20,
866
+ start: 4599
867
+ },
868
+ {
869
+ length: 20,
870
+ start: 5338
871
+ },
872
+ {
873
+ length: 20,
874
+ start: 5820
875
+ },
876
+ {
877
+ length: 20,
878
+ start: 5986
879
+ },
880
+ {
881
+ length: 20,
882
+ start: 6244
883
+ },
884
+ {
885
+ length: 20,
886
+ start: 6410
887
+ }
888
+ ]
889
+ }
890
+ };
891
+ var deployedLinkReferences = {
892
+ "poseidon-solidity/PoseidonT3.sol": {
893
+ PoseidonT3: [
894
+ {
895
+ length: 20,
896
+ start: 4452
897
+ },
898
+ {
899
+ length: 20,
900
+ start: 5191
901
+ },
902
+ {
903
+ length: 20,
904
+ start: 5673
905
+ },
906
+ {
907
+ length: 20,
908
+ start: 5839
909
+ },
910
+ {
911
+ length: 20,
912
+ start: 6097
913
+ },
914
+ {
915
+ length: 20,
916
+ start: 6263
917
+ }
918
+ ]
919
+ }
920
+ };
921
+ var _interface = {
922
+ _format: _format,
923
+ contractName: contractName,
924
+ sourceName: sourceName,
925
+ abi: abi,
926
+ bytecode: bytecode,
927
+ deployedBytecode: deployedBytecode,
928
+ linkReferences: linkReferences,
929
+ deployedLinkReferences: deployedLinkReferences
930
+ };
931
+
932
+ // Minimum supported tree depth.
15
933
  const MIN_DEPTH = 1;
16
- const MAX_DEPTH = 12;
934
+ // Maximum supported tree depth.
935
+ const MAX_DEPTH = 32;
936
+ const SemaphoreABI = _interface.abi;
937
+ const SemaphoreBytecode = _interface.bytecode;
17
938
 
18
939
  var constants = /*#__PURE__*/Object.freeze({
19
940
  __proto__: null,
20
941
  MAX_DEPTH: MAX_DEPTH,
21
- MIN_DEPTH: MIN_DEPTH
942
+ MIN_DEPTH: MIN_DEPTH,
943
+ SemaphoreABI: SemaphoreABI,
944
+ SemaphoreBytecode: SemaphoreBytecode
22
945
  });
23
946
 
24
947
  /**
@@ -32,7 +955,7 @@ var constants = /*#__PURE__*/Object.freeze({
32
955
  * @returns The Semaphore message as a text.
33
956
  */
34
957
  function decodeMessage(message) {
35
- return abi.decodeBytes32String(utils.toBeHex(message, 32));
958
+ return abi$1.decodeBytes32String(utils.toBeHex(message, 32));
36
959
  }
37
960
 
38
961
  var deployedContracts = [
@@ -41,18 +964,18 @@ var deployedContracts = [
41
964
  contracts: [
42
965
  {
43
966
  name: "SemaphoreVerifier",
44
- address: "0x58AD7a4389E0F5d814815E5D5A3Ab903dAE9284a",
45
- startBlock: 5539276
967
+ address: "0xe538f9DeeE04A397decb1E7dc5D16fD6f123c043",
968
+ startBlock: 6333999
46
969
  },
47
970
  {
48
971
  name: "PoseidonT3",
49
- address: "0x4EFfF6a6a7BB31cdAd9Ee742b0faAA6Bb9BF096B",
50
- startBlock: 5539276
972
+ address: "0xB43122Ecb241DD50062641f089876679fd06599a",
973
+ startBlock: 6333999
51
974
  },
52
975
  {
53
976
  name: "Semaphore",
54
- address: "0x0A09FB3f63c13F1C54F2fA41AFB1e7a98cffc774",
55
- startBlock: 5539276
977
+ address: "0x1e0d7FF1610e480fC93BdEC510811ea2Ba6d7c2f",
978
+ startBlock: 6333999
56
979
  }
57
980
  ]
58
981
  },
@@ -61,18 +984,18 @@ var deployedContracts = [
61
984
  contracts: [
62
985
  {
63
986
  name: "SemaphoreVerifier",
64
- address: "0x5f4edC58142f4395D1D536e793137A0252dA5a49",
65
- startBlock: 25837653
987
+ address: "0xe538f9DeeE04A397decb1E7dc5D16fD6f123c043",
988
+ startBlock: 64798522
66
989
  },
67
990
  {
68
991
  name: "PoseidonT3",
69
- address: "0x181B7f34538cE3BceC68597d4A212aB3f7881648",
70
- startBlock: 25837653
992
+ address: "0xB43122Ecb241DD50062641f089876679fd06599a",
993
+ startBlock: 64798522
71
994
  },
72
995
  {
73
996
  name: "Semaphore",
74
- address: "0x220fBdB6F996827b1Cf12f0C181E8d5e6de3a36F",
75
- startBlock: 25837653
997
+ address: "0x1e0d7FF1610e480fC93BdEC510811ea2Ba6d7c2f",
998
+ startBlock: 64798522
76
999
  }
77
1000
  ]
78
1001
  },
@@ -81,38 +1004,38 @@ var deployedContracts = [
81
1004
  contracts: [
82
1005
  {
83
1006
  name: "SemaphoreVerifier",
84
- address: "0x3d3df6CFc6BFf68d9693e097F32bF4a9903E77a5",
85
- startBlock: 9663266
1007
+ address: "0xe538f9DeeE04A397decb1E7dc5D16fD6f123c043",
1008
+ startBlock: 14757931
86
1009
  },
87
1010
  {
88
1011
  name: "PoseidonT3",
89
- address: "0x5f4edC58142f4395D1D536e793137A0252dA5a49",
90
- startBlock: 9663266
1012
+ address: "0xB43122Ecb241DD50062641f089876679fd06599a",
1013
+ startBlock: 14757931
91
1014
  },
92
1015
  {
93
1016
  name: "Semaphore",
94
- address: "0x181B7f34538cE3BceC68597d4A212aB3f7881648",
95
- startBlock: 9663266
1017
+ address: "0x1e0d7FF1610e480fC93BdEC510811ea2Ba6d7c2f",
1018
+ startBlock: 14757931
96
1019
  }
97
1020
  ]
98
1021
  },
99
1022
  {
100
- network: "matic-mumbai",
1023
+ network: "matic-amoy",
101
1024
  contracts: [
102
1025
  {
103
1026
  name: "SemaphoreVerifier",
104
- address: "0xE5269ae1E996C6FEEf6E832c7032401E73087568",
105
- startBlock: 47356015
1027
+ address: "0xe538f9DeeE04A397decb1E7dc5D16fD6f123c043",
1028
+ startBlock: 9636193
106
1029
  },
107
1030
  {
108
1031
  name: "PoseidonT3",
109
- address: "0xC0ae1a8D3505B2bE9DCe0e826abd722Afd13F1c9",
110
- startBlock: 47356015
1032
+ address: "0xB43122Ecb241DD50062641f089876679fd06599a",
1033
+ startBlock: 9636193
111
1034
  },
112
1035
  {
113
1036
  name: "Semaphore",
114
- address: "0x346a936b19071b2f619200848B8ADbb938D72250",
115
- startBlock: 47356015
1037
+ address: "0x1e0d7FF1610e480fC93BdEC510811ea2Ba6d7c2f",
1038
+ startBlock: 9636193
116
1039
  }
117
1040
  ]
118
1041
  }
@@ -137,11 +1060,11 @@ var supportedNetworks = {
137
1060
  chainId: 11155420,
138
1061
  explorer: "https://sepolia-optimism.etherscan.io"
139
1062
  },
140
- "matic-mumbai": {
141
- name: "Matic Mumbai",
142
- url: "https://rpc-mumbai.polygon.technology",
143
- chainId: 80001,
144
- explorer: "https://mumbai.polygonscan.com"
1063
+ "matic-amoy": {
1064
+ name: "Matic Amoy",
1065
+ url: "https://rpc-amoy.polygon.technology",
1066
+ chainId: 80002,
1067
+ explorer: "https://amoy.polygonscan.com"
145
1068
  }
146
1069
  };
147
1070