@orbs-network/spot 1.9.2 → 1.9.4

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.
Files changed (159) hide show
  1. package/README.md +20 -13
  2. package/{script/input/config.json → config.json} +54 -10
  3. package/index.js +8 -3
  4. package/out/00_DeployWM.s.sol/DeployWM.json +1 -1
  5. package/out/00_UpdateWMWhitelist.s.sol/UpdateWMWhitelist.json +1 -1
  6. package/out/01_DeployRepermit.s.sol/DeployRepermit.json +1 -1
  7. package/out/02_DeployCosigner.s.sol/DeployCosigner.json +1 -1
  8. package/out/03_DeployReactor.s.sol/DeployReactor.json +1 -1
  9. package/out/04_DeployExecutor.s.sol/DeployExecutor.json +1 -1
  10. package/out/05_DeployRefinery.s.sol/DeployRefinery.json +1 -1
  11. package/out/{06_DeployDefaultExchange.s.sol/DeployDefaultExchange.abi.json → 06_DeployDefaultAdapter.s.sol/DeployDefaultAdapter.abi.json} +1 -1
  12. package/out/06_DeployDefaultAdapter.s.sol/DeployDefaultAdapter.json +1 -0
  13. package/out/{06_DeployParaswapExchange.s.sol/DeployParaswapExchange.abi.json → 06_DeployDelegatingAdapter.s.sol/DeployDelegatingAdapter.abi.json} +1 -1
  14. package/out/06_DeployDelegatingAdapter.s.sol/DeployDelegatingAdapter.json +1 -0
  15. package/out/{06_DeployP2Exchange.s.sol/DeployP2Exchange.abi.json → 06_DeployP2Adapter.s.sol/DeployP2Adapter.abi.json} +1 -1
  16. package/out/06_DeployP2Adapter.s.sol/DeployP2Adapter.json +1 -0
  17. package/out/06_DeployParaswapAdapter.s.sol/DeployParaswapAdapter.abi.json +28 -0
  18. package/out/06_DeployParaswapAdapter.s.sol/DeployParaswapAdapter.json +1 -0
  19. package/out/06_DeployUniversalAdapter.s.sol/DeployUniversalAdapter.abi.json +28 -0
  20. package/out/06_DeployUniversalAdapter.s.sol/DeployUniversalAdapter.json +1 -0
  21. package/out/BaseTest.sol/BaseTest.abi.json +26 -13
  22. package/out/BaseTest.sol/BaseTest.json +1 -1
  23. package/out/Constants.sol/Constants.json +1 -1
  24. package/out/CosignatureLib.sol/CosignatureLib.abi.json +10 -0
  25. package/out/CosignatureLib.sol/CosignatureLib.json +1 -1
  26. package/out/CosignatureLib.t.sol/CosignatureLibTest.abi.json +125 -16
  27. package/out/CosignatureLib.t.sol/CosignatureLibTest.json +1 -1
  28. package/out/Cosigner.sol/Cosigner.abi.json +12 -115
  29. package/out/Cosigner.sol/Cosigner.json +1 -1
  30. package/out/Cosigner.t.sol/CosignerTest.abi.json +30 -154
  31. package/out/Cosigner.t.sol/CosignerTest.json +1 -1
  32. package/out/Cosigner.t.sol/CosignerWrapper.abi.json +12 -115
  33. package/out/Cosigner.t.sol/CosignerWrapper.json +1 -1
  34. package/out/CosignerIntegration.t.sol/CosignerIntegrationTest.abi.json +49 -33
  35. package/out/CosignerIntegration.t.sol/CosignerIntegrationTest.json +1 -1
  36. package/out/DefaultDexAdapter.sol/DefaultDexAdapter.abi.json +105 -4
  37. package/out/DefaultDexAdapter.sol/DefaultDexAdapter.json +1 -1
  38. package/out/DefaultDexAdapter.t.sol/DefaultDexAdapterTest.abi.json +33 -13
  39. package/out/DefaultDexAdapter.t.sol/DefaultDexAdapterTest.json +1 -1
  40. package/out/DelegatingAdapter.sol/DelegatingAdapter.abi.json +402 -0
  41. package/out/DelegatingAdapter.sol/DelegatingAdapter.json +1 -0
  42. package/out/DelegatingAdapter.t.sol/DelegatingAdapterTest.abi.json +916 -0
  43. package/out/DelegatingAdapter.t.sol/DelegatingAdapterTest.json +1 -0
  44. package/out/DelegatingAdapter.t.sol/MockDelegateTarget.abi.json +22 -0
  45. package/out/DelegatingAdapter.t.sol/MockDelegateTarget.json +1 -0
  46. package/out/ERC20Mock.sol/ERC20Mock.json +1 -1
  47. package/out/ERC20Mock6Decimals.sol/ERC20Mock6Decimals.json +1 -1
  48. package/out/EpochLib.sol/EpochLib.json +1 -1
  49. package/out/EpochLib.t.sol/EpochLibTest.json +1 -1
  50. package/out/ExclusivityOverrideLib.sol/ExclusivityOverrideLib.json +1 -1
  51. package/out/ExclusivityOverrideLib.t.sol/ExclusivityCaller.json +1 -1
  52. package/out/ExclusivityOverrideLib.t.sol/ExclusivityLibTest.abi.json +26 -13
  53. package/out/ExclusivityOverrideLib.t.sol/ExclusivityLibTest.json +1 -1
  54. package/out/Executor.sol/Executor.abi.json +200 -13
  55. package/out/Executor.sol/Executor.json +1 -1
  56. package/out/Executor.t.sol/ExecutorTest.abi.json +26 -13
  57. package/out/Executor.t.sol/ExecutorTest.json +1 -1
  58. package/out/FeeOnTransferERC20Mock.sol/FeeOnTransferERC20Mock.json +1 -1
  59. package/out/{07_CheckOrder.s.sol/AlwaysValid1271.abi.json → ICommitteeSync.sol/ICommitteeSync.abi.json} +9 -9
  60. package/out/ICommitteeSync.sol/ICommitteeSync.json +1 -0
  61. package/out/IEIP712.sol/IEIP712.json +1 -1
  62. package/out/IExchangeAdapter.sol/IExchangeAdapter.abi.json +105 -4
  63. package/out/IExchangeAdapter.sol/IExchangeAdapter.json +1 -1
  64. package/out/IParaswapAugustus.sol/IParaswapAugustus.json +1 -1
  65. package/out/IPermit2.sol/IPermit2.json +1 -1
  66. package/out/IReactor.sol/IReactor.abi.json +100 -4
  67. package/out/IReactor.sol/IReactor.json +1 -1
  68. package/out/IReactorCallback.sol/IReactorCallback.abi.json +100 -4
  69. package/out/IReactorCallback.sol/IReactorCallback.json +1 -1
  70. package/out/IWM.sol/IWM.json +1 -1
  71. package/out/IWrappedNative.sol/IWrappedNative.abi.json +22 -0
  72. package/out/IWrappedNative.sol/IWrappedNative.json +1 -0
  73. package/out/MockCommitteeSync.sol/MockCommitteeSync.abi.json +67 -0
  74. package/out/MockCommitteeSync.sol/MockCommitteeSync.json +1 -0
  75. package/out/MockDexRouter.sol/MockDexRouter.json +1 -1
  76. package/out/MockParaswap.sol/MockParaswapAugustus.json +1 -1
  77. package/out/MockParaswap.sol/MockTokenTransferProxy.json +1 -1
  78. package/out/MockPermit2.sol/MockPermit2.json +1 -1
  79. package/out/MockReactor.sol/MockReactor.abi.json +200 -8
  80. package/out/MockReactor.sol/MockReactor.json +1 -1
  81. package/out/Multicall3Lib.sol/Multicall3Lib.json +1 -1
  82. package/out/OrderLib.sol/OrderLib.json +1 -1
  83. package/out/OrderReactor.E2E.t.sol/OrderReactorE2ETest.abi.json +27 -14
  84. package/out/OrderReactor.E2E.t.sol/OrderReactorE2ETest.json +1 -1
  85. package/out/OrderReactor.sol/OrderReactor.abi.json +130 -14
  86. package/out/OrderReactor.sol/OrderReactor.json +1 -1
  87. package/out/OrderReactorPause.t.sol/OrderReactorPauseTest.abi.json +26 -13
  88. package/out/OrderReactorPause.t.sol/OrderReactorPauseTest.json +1 -1
  89. package/out/OrderReactorPause.t.sol/SimpleCallback.abi.json +100 -4
  90. package/out/OrderReactorPause.t.sol/SimpleCallback.json +1 -1
  91. package/out/OrderValidationLib.Fuzz.t.sol/OrderValidationLibFuzzTest.abi.json +136 -22
  92. package/out/OrderValidationLib.Fuzz.t.sol/OrderValidationLibFuzzTest.json +1 -1
  93. package/out/OrderValidationLib.sol/OrderValidationLib.abi.json +15 -5
  94. package/out/OrderValidationLib.sol/OrderValidationLib.json +1 -1
  95. package/out/OrderValidationLib.t.sol/OrderValidationLibTest.abi.json +160 -30
  96. package/out/OrderValidationLib.t.sol/OrderValidationLibTest.json +1 -1
  97. package/out/P2DexAdapter.sol/P2DexAdapter.abi.json +105 -4
  98. package/out/P2DexAdapter.sol/P2DexAdapter.json +1 -1
  99. package/out/P2DexAdapter.t.sol/P2DexAdapterTest.abi.json +33 -13
  100. package/out/P2DexAdapter.t.sol/P2DexAdapterTest.json +1 -1
  101. package/out/ParaswapDexAdapter.sol/ParaswapDexAdapter.abi.json +105 -4
  102. package/out/ParaswapDexAdapter.sol/ParaswapDexAdapter.json +1 -1
  103. package/out/ParaswapDexAdapter.t.sol/ParaswapDexAdapterTest.abi.json +33 -13
  104. package/out/ParaswapDexAdapter.t.sol/ParaswapDexAdapterTest.json +1 -1
  105. package/out/RePermit.sol/RePermit.json +1 -1
  106. package/out/RePermit.t.sol/RePermitTest.abi.json +26 -13
  107. package/out/RePermit.t.sol/RePermitTest.json +1 -1
  108. package/out/RePermitLib.sol/RePermitLib.json +1 -1
  109. package/out/Refinery.sol/Refinery.json +1 -1
  110. package/out/Refinery.t.sol/PayableTarget.json +1 -1
  111. package/out/Refinery.t.sol/RefineryTest.abi.json +26 -13
  112. package/out/Refinery.t.sol/RefineryTest.json +1 -1
  113. package/out/ResolutionLib.Fuzz.t.sol/ResolutionLibFuzzTest.abi.json +122 -18
  114. package/out/ResolutionLib.Fuzz.t.sol/ResolutionLibFuzzTest.json +1 -1
  115. package/out/ResolutionLib.sol/ResolutionLib.abi.json +1 -1
  116. package/out/ResolutionLib.sol/ResolutionLib.json +1 -1
  117. package/out/ResolutionLib.t.sol/ResolutionLibTest.abi.json +133 -20
  118. package/out/ResolutionLib.t.sol/ResolutionLibTest.json +1 -1
  119. package/out/SettlementLib.sol/SettlementLib.json +1 -1
  120. package/out/SettlementLib.t.sol/SettlementLibTest.abi.json +26 -13
  121. package/out/SettlementLib.t.sol/SettlementLibTest.json +1 -1
  122. package/out/SettlementLib.t.sol/SettlementWrapper.abi.json +100 -4
  123. package/out/SettlementLib.t.sol/SettlementWrapper.json +1 -1
  124. package/out/Settler.sol/Settler.abi.json +454 -0
  125. package/out/Settler.sol/Settler.json +1 -0
  126. package/out/Settler.t.sol/SettlerTest.abi.json +995 -0
  127. package/out/Settler.t.sol/SettlerTest.json +1 -0
  128. package/out/StdError.sol/stdError.json +1 -1
  129. package/out/SurplusLib.sol/SurplusLib.json +1 -1
  130. package/out/SurplusLib.t.sol/SurplusHarness.json +1 -1
  131. package/out/SurplusLib.t.sol/SurplusLibTest.json +1 -1
  132. package/out/SwapAdapter.sol/SwapAdapterMock.abi.json +100 -9
  133. package/out/SwapAdapter.sol/SwapAdapterMock.json +1 -1
  134. package/out/TokenLib.sol/TokenLib.json +1 -1
  135. package/out/TokenLib.t.sol/TokenLibHarness.json +1 -1
  136. package/out/TokenLib.t.sol/TokenLibTest.json +1 -1
  137. package/out/USDTMock.sol/USDTMock.json +1 -1
  138. package/out/UniversalAdapter.sol/UniversalAdapter.abi.json +429 -0
  139. package/out/UniversalAdapter.sol/UniversalAdapter.json +1 -0
  140. package/out/UniversalAdapter.t.sol/UniversalAdapterTest.abi.json +930 -0
  141. package/out/UniversalAdapter.t.sol/UniversalAdapterTest.json +1 -0
  142. package/out/WM.sol/WM.json +1 -1
  143. package/out/WM.t.sol/WMTest.abi.json +26 -13
  144. package/out/WM.t.sol/WMTest.json +1 -1
  145. package/out/WMAllowed.sol/WMAllowed.json +1 -1
  146. package/out/WrappedNativeMock.sol/WrappedNativeMock.abi.json +360 -0
  147. package/out/WrappedNativeMock.sol/WrappedNativeMock.json +1 -0
  148. package/out/build-info/{42633f5ef75c0db8.json → 621c6e28e002a5dd.json} +1 -1
  149. package/out/build-info/{a2626b343b46f44e.json → 7683d39d37ddee4a.json} +1 -1
  150. package/package.json +2 -1
  151. package/script/input/cosignature.skeleton.json +0 -1
  152. package/script/input/repermit.skeleton.json +12 -2
  153. package/out/06_DeployDefaultExchange.s.sol/DeployDefaultExchange.json +0 -1
  154. package/out/06_DeployP2Exchange.s.sol/DeployP2Exchange.json +0 -1
  155. package/out/06_DeployParaswapExchange.s.sol/DeployParaswapExchange.json +0 -1
  156. package/out/07_CheckOrder.s.sol/AlwaysValid1271.json +0 -1
  157. package/out/07_CheckOrder.s.sol/CheckOrder.abi.json +0 -78
  158. package/out/07_CheckOrder.s.sol/CheckOrder.json +0 -1
  159. package/script/input/order.json +0 -63
@@ -12,6 +12,19 @@
12
12
  ],
13
13
  "stateMutability": "view"
14
14
  },
15
+ {
16
+ "type": "function",
17
+ "name": "committee",
18
+ "inputs": [],
19
+ "outputs": [
20
+ {
21
+ "name": "",
22
+ "type": "address",
23
+ "internalType": "contract MockCommitteeSync"
24
+ }
25
+ ],
26
+ "stateMutability": "view"
27
+ },
15
28
  {
16
29
  "type": "function",
17
30
  "name": "cosigner",
@@ -102,32 +115,6 @@
102
115
  ],
103
116
  "stateMutability": "view"
104
117
  },
105
- {
106
- "type": "function",
107
- "name": "owner",
108
- "inputs": [],
109
- "outputs": [
110
- {
111
- "name": "",
112
- "type": "address",
113
- "internalType": "address"
114
- }
115
- ],
116
- "stateMutability": "view"
117
- },
118
- {
119
- "type": "function",
120
- "name": "ownerPK",
121
- "inputs": [],
122
- "outputs": [
123
- {
124
- "name": "",
125
- "type": "uint256",
126
- "internalType": "uint256"
127
- }
128
- ],
129
- "stateMutability": "view"
130
- },
131
118
  {
132
119
  "type": "function",
133
120
  "name": "setUp",
@@ -334,35 +321,14 @@
334
321
  },
335
322
  {
336
323
  "type": "function",
337
- "name": "test_acceptOwnership_completes_transfer",
324
+ "name": "test_constructor_reverts_when_owner_is_zero",
338
325
  "inputs": [],
339
326
  "outputs": [],
340
327
  "stateMutability": "nonpayable"
341
328
  },
342
329
  {
343
330
  "type": "function",
344
- "name": "test_acceptOwnership_reverts_when_not_pending_owner",
345
- "inputs": [],
346
- "outputs": [],
347
- "stateMutability": "nonpayable"
348
- },
349
- {
350
- "type": "function",
351
- "name": "test_approve_adds_signer_with_deadline",
352
- "inputs": [],
353
- "outputs": [],
354
- "stateMutability": "nonpayable"
355
- },
356
- {
357
- "type": "function",
358
- "name": "test_approve_reverts_when_not_owner",
359
- "inputs": [],
360
- "outputs": [],
361
- "stateMutability": "nonpayable"
362
- },
363
- {
364
- "type": "function",
365
- "name": "test_constructor_sets_initial_owner",
331
+ "name": "test_constructor_sets_owner",
366
332
  "inputs": [],
367
333
  "outputs": [],
368
334
  "stateMutability": "view"
@@ -383,115 +349,95 @@
383
349
  },
384
350
  {
385
351
  "type": "function",
386
- "name": "test_event_OwnershipTransferStarted",
352
+ "name": "test_isApprovedNow_owner_transfer_updates_approval",
387
353
  "inputs": [],
388
354
  "outputs": [],
389
355
  "stateMutability": "nonpayable"
390
356
  },
391
357
  {
392
358
  "type": "function",
393
- "name": "test_event_OwnershipTransferred",
359
+ "name": "test_isApprovedNow_renounced_owner_not_approved",
394
360
  "inputs": [],
395
361
  "outputs": [],
396
362
  "stateMutability": "nonpayable"
397
363
  },
398
364
  {
399
365
  "type": "function",
400
- "name": "test_isApprovedNow_returns_false_for_expired",
366
+ "name": "test_isApprovedNow_returns_false_for_expired_signer",
401
367
  "inputs": [],
402
368
  "outputs": [],
403
369
  "stateMutability": "nonpayable"
404
370
  },
405
371
  {
406
372
  "type": "function",
407
- "name": "test_isApprovedNow_returns_false_for_unapproved",
408
- "inputs": [],
409
- "outputs": [],
410
- "stateMutability": "view"
411
- },
412
- {
413
- "type": "function",
414
- "name": "test_rawSignatureValidation_accepts_approved_signer_signature",
373
+ "name": "test_isApprovedNow_returns_false_for_malformed_config_bytes",
415
374
  "inputs": [],
416
375
  "outputs": [],
417
376
  "stateMutability": "nonpayable"
418
377
  },
419
378
  {
420
379
  "type": "function",
421
- "name": "test_rawSignatureValidation_rejects_expired_signer",
380
+ "name": "test_isApprovedNow_returns_false_for_unapproved",
422
381
  "inputs": [],
423
382
  "outputs": [],
424
- "stateMutability": "nonpayable"
383
+ "stateMutability": "view"
425
384
  },
426
385
  {
427
386
  "type": "function",
428
- "name": "test_rawSignatureValidation_rejects_invalid_signature",
387
+ "name": "test_isApprovedNow_returns_true_for_active_signer",
429
388
  "inputs": [],
430
389
  "outputs": [],
431
390
  "stateMutability": "nonpayable"
432
391
  },
433
392
  {
434
393
  "type": "function",
435
- "name": "test_rawSignatureValidation_rejects_unapproved_signer",
394
+ "name": "test_isApprovedNow_returns_true_for_owner",
436
395
  "inputs": [],
437
396
  "outputs": [],
438
397
  "stateMutability": "view"
439
398
  },
440
399
  {
441
400
  "type": "function",
442
- "name": "test_revokeSigner_removes_signer",
401
+ "name": "test_rawSignatureValidation_accepts_approved_signer_signature",
443
402
  "inputs": [],
444
403
  "outputs": [],
445
404
  "stateMutability": "nonpayable"
446
405
  },
447
406
  {
448
407
  "type": "function",
449
- "name": "test_revokeSigner_reverts_when_not_owner",
408
+ "name": "test_rawSignatureValidation_accepts_owner_signature_without_committee_approval",
450
409
  "inputs": [],
451
410
  "outputs": [],
452
411
  "stateMutability": "nonpayable"
453
412
  },
454
413
  {
455
414
  "type": "function",
456
- "name": "test_transferOwnership_initiates_two_step_transfer",
415
+ "name": "test_rawSignatureValidation_rejects_expired_signer",
457
416
  "inputs": [],
458
417
  "outputs": [],
459
418
  "stateMutability": "nonpayable"
460
419
  },
461
420
  {
462
421
  "type": "function",
463
- "name": "test_transferOwnership_reverts_when_not_owner",
422
+ "name": "test_rawSignatureValidation_rejects_invalid_signature",
464
423
  "inputs": [],
465
424
  "outputs": [],
466
425
  "stateMutability": "nonpayable"
467
426
  },
468
427
  {
469
428
  "type": "function",
470
- "name": "test_transferOwnership_to_zero_address_cancels_pending",
429
+ "name": "test_rawSignatureValidation_rejects_unapproved_signer",
471
430
  "inputs": [],
472
431
  "outputs": [],
473
- "stateMutability": "nonpayable"
432
+ "stateMutability": "view"
474
433
  },
475
434
  {
476
435
  "type": "function",
477
- "name": "test_zeroAddressApproval_cannotBypassSignatureValidation",
436
+ "name": "test_zeroAddressConfig_cannotBypassSignatureValidation",
478
437
  "inputs": [],
479
438
  "outputs": [],
480
439
  "stateMutability": "nonpayable"
481
440
  },
482
- {
483
- "type": "function",
484
- "name": "unauthorized",
485
- "inputs": [],
486
- "outputs": [
487
- {
488
- "name": "",
489
- "type": "address",
490
- "internalType": "address"
491
- }
492
- ],
493
- "stateMutability": "view"
494
- },
495
441
  {
496
442
  "type": "function",
497
443
  "name": "wrapper",
@@ -505,76 +451,6 @@
505
451
  ],
506
452
  "stateMutability": "view"
507
453
  },
508
- {
509
- "type": "event",
510
- "name": "OwnershipTransferStarted",
511
- "inputs": [
512
- {
513
- "name": "previousOwner",
514
- "type": "address",
515
- "indexed": true,
516
- "internalType": "address"
517
- },
518
- {
519
- "name": "newOwner",
520
- "type": "address",
521
- "indexed": true,
522
- "internalType": "address"
523
- }
524
- ],
525
- "anonymous": false
526
- },
527
- {
528
- "type": "event",
529
- "name": "OwnershipTransferred",
530
- "inputs": [
531
- {
532
- "name": "previousOwner",
533
- "type": "address",
534
- "indexed": true,
535
- "internalType": "address"
536
- },
537
- {
538
- "name": "newOwner",
539
- "type": "address",
540
- "indexed": true,
541
- "internalType": "address"
542
- }
543
- ],
544
- "anonymous": false
545
- },
546
- {
547
- "type": "event",
548
- "name": "SignerApproved",
549
- "inputs": [
550
- {
551
- "name": "signer",
552
- "type": "address",
553
- "indexed": true,
554
- "internalType": "address"
555
- },
556
- {
557
- "name": "deadline",
558
- "type": "uint256",
559
- "indexed": false,
560
- "internalType": "uint256"
561
- }
562
- ],
563
- "anonymous": false
564
- },
565
- {
566
- "type": "event",
567
- "name": "SignerRevoked",
568
- "inputs": [
569
- {
570
- "name": "signer",
571
- "type": "address",
572
- "indexed": true,
573
- "internalType": "address"
574
- }
575
- ],
576
- "anonymous": false
577
- },
578
454
  {
579
455
  "type": "event",
580
456
  "name": "log",