@coti-io/coti-contracts 0.1.0 → 1.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.
Files changed (71) hide show
  1. package/contracts/access/DataPrivacyFramework/extensions/DataPrivacyFrameworkMpc.sol +3 -115
  2. package/contracts/mocks/README.md +1 -1
  3. package/contracts/mocks/utils/mpc/ArithmeticTestsContract.sol +105 -280
  4. package/contracts/mocks/utils/mpc/BitwiseTestsContract.sol +83 -187
  5. package/contracts/mocks/utils/mpc/{Comparison1Tests.Contract.sol → Comparison1TestsContract.sol} +67 -115
  6. package/contracts/mocks/utils/mpc/Comparison2TestsContract.sol +68 -116
  7. package/contracts/mocks/utils/mpc/MinMaxTestsContract.sol +69 -164
  8. package/contracts/mocks/utils/mpc/Miscellaneous1TestsContract.sol +70 -52
  9. package/contracts/mocks/utils/mpc/MiscellaneousTestsContract.sol +270 -0
  10. package/contracts/mocks/utils/mpc/OffboardToUserKeyTestContract.sol +102 -0
  11. package/contracts/mocks/utils/mpc/README.md +12 -12
  12. package/contracts/mocks/utils/mpc/TransferScalarTestsContract.sol +54 -211
  13. package/contracts/mocks/utils/mpc/TransferTestsContract.sol +162 -640
  14. package/contracts/onboard/AccountOnboard.sol +3 -3
  15. package/contracts/utils/mpc/MpcCore.sol +2835 -988
  16. package/contracts/utils/mpc/MpcInterface.sol +6 -4
  17. package/hardhat.config.ts +8 -5
  18. package/package.json +2 -2
  19. package/test/utils/accounts.ts +1 -1
  20. package/test/utils/mpc/Precompile.test.ts +26 -37
  21. package/typechain-types/contracts/mocks/utils/mpc/ArithmeticTestsContract.sol/ArithmeticTestsContract.ts +374 -0
  22. package/typechain-types/contracts/mocks/utils/mpc/ArithmeticTestsContract.sol/PrecompilesArythmeticTestsContract.ts +374 -0
  23. package/typechain-types/contracts/mocks/utils/mpc/ArithmeticTestsContract.sol/index.ts +5 -0
  24. package/typechain-types/contracts/mocks/utils/mpc/ArithmeticTestsContract.ts +30 -10
  25. package/typechain-types/contracts/mocks/utils/mpc/BitwiseTestsContract.ts +39 -5
  26. package/typechain-types/contracts/mocks/utils/mpc/Comparison1TestsContract.ts +374 -0
  27. package/typechain-types/contracts/mocks/utils/mpc/Comparison2TestsContract.ts +39 -5
  28. package/typechain-types/contracts/mocks/utils/mpc/MinMaxTestsContract.ts +25 -5
  29. package/typechain-types/contracts/mocks/utils/mpc/Miscellaneous1TestsContract.ts +62 -0
  30. package/typechain-types/contracts/mocks/utils/mpc/MiscellaneousTestsContract.ts +396 -0
  31. package/typechain-types/contracts/mocks/utils/mpc/OffboardToUserKeyTestContract.ts +221 -0
  32. package/typechain-types/contracts/mocks/utils/mpc/OffboardToUserKeyTestsContract.sol/OffboardToUserKeyTestContract.ts +11 -8
  33. package/typechain-types/contracts/mocks/utils/mpc/TransferScalarTestsContract.ts +15 -15
  34. package/typechain-types/contracts/mocks/utils/mpc/TransferTestsContract.ts +15 -15
  35. package/typechain-types/contracts/mocks/utils/mpc/index.ts +3 -6
  36. package/typechain-types/contracts/onboard/AccountOnboard.ts +9 -4
  37. package/typechain-types/contracts/utils/mpc/MpcCore.ts +84 -0
  38. package/typechain-types/contracts/utils/mpc/MpcInterface.sol/ExtendedOperations.ts +81 -40
  39. package/typechain-types/contracts/utils/mpc/index.ts +1 -0
  40. package/typechain-types/factories/contracts/mocks/access/DataPrivacyFramework/DataPrivacyFrameworkMock__factory.ts +1 -1
  41. package/typechain-types/factories/contracts/mocks/token/PrivateERC20/PrivateERC20Mock__factory.ts +1 -1
  42. package/typechain-types/factories/contracts/mocks/token/PrivateERC721/PrivateERC721URIStorageMock__factory.ts +1 -1
  43. package/typechain-types/factories/contracts/mocks/utils/mpc/ArithmeticTestsContract.sol/ArithmeticTestsContract__factory.ts +387 -0
  44. package/typechain-types/factories/contracts/mocks/utils/mpc/ArithmeticTestsContract.sol/PrecompilesArythmeticTestsContract__factory.ts +388 -0
  45. package/typechain-types/factories/contracts/mocks/utils/mpc/ArithmeticTestsContract.sol/index.ts +5 -0
  46. package/typechain-types/factories/contracts/mocks/utils/mpc/ArithmeticTestsContract__factory.ts +20 -7
  47. package/typechain-types/factories/contracts/mocks/utils/mpc/BitwiseTestsContract__factory.ts +28 -2
  48. package/typechain-types/factories/contracts/mocks/utils/mpc/Comparison1Tests.Contract.sol/Comparison1TestsContract__factory.ts +1 -1
  49. package/typechain-types/factories/contracts/mocks/utils/mpc/Comparison1TestsContract__factory.ts +387 -0
  50. package/typechain-types/factories/contracts/mocks/utils/mpc/Comparison2TestsContract__factory.ts +28 -2
  51. package/typechain-types/factories/contracts/mocks/utils/mpc/MinMaxTestsContract__factory.ts +15 -2
  52. package/typechain-types/factories/contracts/mocks/utils/mpc/Miscellaneous1TestsContract__factory.ts +66 -1
  53. package/typechain-types/factories/contracts/mocks/utils/mpc/Miscellaneous2TestsContract__factory.ts +1 -1
  54. package/typechain-types/factories/contracts/mocks/utils/mpc/MiscellaneousTestsContract__factory.ts +424 -0
  55. package/typechain-types/factories/contracts/mocks/utils/mpc/OffboardToUserKeyTestContract__factory.ts +289 -0
  56. package/typechain-types/factories/contracts/mocks/utils/mpc/OffboardToUserKeyTestsContract.sol/OffboardToUserKeyTestContract__factory.ts +19 -3
  57. package/typechain-types/factories/contracts/mocks/utils/mpc/ShiftTestsContract__factory.ts +1 -1
  58. package/typechain-types/factories/contracts/mocks/utils/mpc/StringTestsContract__factory.ts +1 -1
  59. package/typechain-types/factories/contracts/mocks/utils/mpc/TransferScalarTestsContract__factory.ts +4 -4
  60. package/typechain-types/factories/contracts/mocks/utils/mpc/TransferTestsContract__factory.ts +4 -4
  61. package/typechain-types/factories/contracts/mocks/utils/mpc/index.ts +3 -4
  62. package/typechain-types/factories/contracts/mocks/wallet/PrivateERC20Wallet/PrivateERC20WalletMock__factory.ts +1 -1
  63. package/typechain-types/factories/contracts/onboard/AccountOnboard__factory.ts +8 -2
  64. package/typechain-types/factories/contracts/utils/mpc/MpcCore__factory.ts +77 -0
  65. package/typechain-types/factories/contracts/utils/mpc/MpcInterface.sol/ExtendedOperations__factory.ts +124 -61
  66. package/typechain-types/factories/contracts/utils/mpc/index.ts +1 -0
  67. package/typechain-types/hardhat.d.ts +26 -26
  68. package/typechain-types/index.ts +8 -8
  69. package/contracts/mocks/utils/mpc/Miscellaneous2TestsContract.sol +0 -448
  70. package/contracts/mocks/utils/mpc/OffboardToUserKeyTestsContract.sol +0 -81
  71. package/contracts/mocks/utils/mpc/ShiftTestsContract.sol +0 -311
@@ -56,15 +56,15 @@ export declare namespace TransferScalarTestsContract {
56
56
  export interface TransferScalarTestsContractInterface extends Interface {
57
57
  getFunction(
58
58
  nameOrSignature:
59
- | "computeAndChekTransfer16"
60
- | "computeAndChekTransfer32"
61
- | "computeAndChekTransfer64"
59
+ | "computeAndCheckTransfer16"
60
+ | "computeAndCheckTransfer32"
61
+ | "computeAndCheckTransfer64"
62
62
  | "getResults"
63
63
  | "transferScalarTest"
64
64
  ): FunctionFragment;
65
65
 
66
66
  encodeFunctionData(
67
- functionFragment: "computeAndChekTransfer16",
67
+ functionFragment: "computeAndCheckTransfer16",
68
68
  values: [
69
69
  TransferScalarTestsContract.AllGTCastingValuesStruct,
70
70
  BigNumberish,
@@ -74,7 +74,7 @@ export interface TransferScalarTestsContractInterface extends Interface {
74
74
  ]
75
75
  ): string;
76
76
  encodeFunctionData(
77
- functionFragment: "computeAndChekTransfer32",
77
+ functionFragment: "computeAndCheckTransfer32",
78
78
  values: [
79
79
  TransferScalarTestsContract.AllGTCastingValuesStruct,
80
80
  BigNumberish,
@@ -84,7 +84,7 @@ export interface TransferScalarTestsContractInterface extends Interface {
84
84
  ]
85
85
  ): string;
86
86
  encodeFunctionData(
87
- functionFragment: "computeAndChekTransfer64",
87
+ functionFragment: "computeAndCheckTransfer64",
88
88
  values: [
89
89
  TransferScalarTestsContract.AllGTCastingValuesStruct,
90
90
  BigNumberish,
@@ -103,15 +103,15 @@ export interface TransferScalarTestsContractInterface extends Interface {
103
103
  ): string;
104
104
 
105
105
  decodeFunctionResult(
106
- functionFragment: "computeAndChekTransfer16",
106
+ functionFragment: "computeAndCheckTransfer16",
107
107
  data: BytesLike
108
108
  ): Result;
109
109
  decodeFunctionResult(
110
- functionFragment: "computeAndChekTransfer32",
110
+ functionFragment: "computeAndCheckTransfer32",
111
111
  data: BytesLike
112
112
  ): Result;
113
113
  decodeFunctionResult(
114
- functionFragment: "computeAndChekTransfer64",
114
+ functionFragment: "computeAndCheckTransfer64",
115
115
  data: BytesLike
116
116
  ): Result;
117
117
  decodeFunctionResult(functionFragment: "getResults", data: BytesLike): Result;
@@ -164,7 +164,7 @@ export interface TransferScalarTestsContract extends BaseContract {
164
164
  event?: TCEvent
165
165
  ): Promise<this>;
166
166
 
167
- computeAndChekTransfer16: TypedContractMethod<
167
+ computeAndCheckTransfer16: TypedContractMethod<
168
168
  [
169
169
  allGTCastingValues: TransferScalarTestsContract.AllGTCastingValuesStruct,
170
170
  new_a: BigNumberish,
@@ -176,7 +176,7 @@ export interface TransferScalarTestsContract extends BaseContract {
176
176
  "nonpayable"
177
177
  >;
178
178
 
179
- computeAndChekTransfer32: TypedContractMethod<
179
+ computeAndCheckTransfer32: TypedContractMethod<
180
180
  [
181
181
  allGTCastingValues: TransferScalarTestsContract.AllGTCastingValuesStruct,
182
182
  new_a: BigNumberish,
@@ -188,7 +188,7 @@ export interface TransferScalarTestsContract extends BaseContract {
188
188
  "nonpayable"
189
189
  >;
190
190
 
191
- computeAndChekTransfer64: TypedContractMethod<
191
+ computeAndCheckTransfer64: TypedContractMethod<
192
192
  [
193
193
  allGTCastingValues: TransferScalarTestsContract.AllGTCastingValuesStruct,
194
194
  new_a: BigNumberish,
@@ -213,7 +213,7 @@ export interface TransferScalarTestsContract extends BaseContract {
213
213
  ): T;
214
214
 
215
215
  getFunction(
216
- nameOrSignature: "computeAndChekTransfer16"
216
+ nameOrSignature: "computeAndCheckTransfer16"
217
217
  ): TypedContractMethod<
218
218
  [
219
219
  allGTCastingValues: TransferScalarTestsContract.AllGTCastingValuesStruct,
@@ -226,7 +226,7 @@ export interface TransferScalarTestsContract extends BaseContract {
226
226
  "nonpayable"
227
227
  >;
228
228
  getFunction(
229
- nameOrSignature: "computeAndChekTransfer32"
229
+ nameOrSignature: "computeAndCheckTransfer32"
230
230
  ): TypedContractMethod<
231
231
  [
232
232
  allGTCastingValues: TransferScalarTestsContract.AllGTCastingValuesStruct,
@@ -239,7 +239,7 @@ export interface TransferScalarTestsContract extends BaseContract {
239
239
  "nonpayable"
240
240
  >;
241
241
  getFunction(
242
- nameOrSignature: "computeAndChekTransfer64"
242
+ nameOrSignature: "computeAndCheckTransfer64"
243
243
  ): TypedContractMethod<
244
244
  [
245
245
  allGTCastingValues: TransferScalarTestsContract.AllGTCastingValuesStruct,
@@ -78,15 +78,15 @@ export declare namespace TransferTestsContract {
78
78
  export interface TransferTestsContractInterface extends Interface {
79
79
  getFunction(
80
80
  nameOrSignature:
81
- | "computeAndChekTransfer16"
82
- | "computeAndChekTransfer32"
83
- | "computeAndChekTransfer64"
81
+ | "computeAndCheckTransfer16"
82
+ | "computeAndCheckTransfer32"
83
+ | "computeAndCheckTransfer64"
84
84
  | "getResults"
85
85
  | "transferTest"
86
86
  ): FunctionFragment;
87
87
 
88
88
  encodeFunctionData(
89
- functionFragment: "computeAndChekTransfer16",
89
+ functionFragment: "computeAndCheckTransfer16",
90
90
  values: [
91
91
  TransferTestsContract.AllGTCastingValuesStruct,
92
92
  TransferTestsContract.AllAmountValuesStruct,
@@ -96,7 +96,7 @@ export interface TransferTestsContractInterface extends Interface {
96
96
  ]
97
97
  ): string;
98
98
  encodeFunctionData(
99
- functionFragment: "computeAndChekTransfer32",
99
+ functionFragment: "computeAndCheckTransfer32",
100
100
  values: [
101
101
  TransferTestsContract.AllGTCastingValuesStruct,
102
102
  TransferTestsContract.AllAmountValuesStruct,
@@ -106,7 +106,7 @@ export interface TransferTestsContractInterface extends Interface {
106
106
  ]
107
107
  ): string;
108
108
  encodeFunctionData(
109
- functionFragment: "computeAndChekTransfer64",
109
+ functionFragment: "computeAndCheckTransfer64",
110
110
  values: [
111
111
  TransferTestsContract.AllGTCastingValuesStruct,
112
112
  TransferTestsContract.AllAmountValuesStruct,
@@ -125,15 +125,15 @@ export interface TransferTestsContractInterface extends Interface {
125
125
  ): string;
126
126
 
127
127
  decodeFunctionResult(
128
- functionFragment: "computeAndChekTransfer16",
128
+ functionFragment: "computeAndCheckTransfer16",
129
129
  data: BytesLike
130
130
  ): Result;
131
131
  decodeFunctionResult(
132
- functionFragment: "computeAndChekTransfer32",
132
+ functionFragment: "computeAndCheckTransfer32",
133
133
  data: BytesLike
134
134
  ): Result;
135
135
  decodeFunctionResult(
136
- functionFragment: "computeAndChekTransfer64",
136
+ functionFragment: "computeAndCheckTransfer64",
137
137
  data: BytesLike
138
138
  ): Result;
139
139
  decodeFunctionResult(functionFragment: "getResults", data: BytesLike): Result;
@@ -186,7 +186,7 @@ export interface TransferTestsContract extends BaseContract {
186
186
  event?: TCEvent
187
187
  ): Promise<this>;
188
188
 
189
- computeAndChekTransfer16: TypedContractMethod<
189
+ computeAndCheckTransfer16: TypedContractMethod<
190
190
  [
191
191
  allGTCastingValues: TransferTestsContract.AllGTCastingValuesStruct,
192
192
  allAmountValues: TransferTestsContract.AllAmountValuesStruct,
@@ -198,7 +198,7 @@ export interface TransferTestsContract extends BaseContract {
198
198
  "nonpayable"
199
199
  >;
200
200
 
201
- computeAndChekTransfer32: TypedContractMethod<
201
+ computeAndCheckTransfer32: TypedContractMethod<
202
202
  [
203
203
  allGTCastingValues: TransferTestsContract.AllGTCastingValuesStruct,
204
204
  allAmountValues: TransferTestsContract.AllAmountValuesStruct,
@@ -210,7 +210,7 @@ export interface TransferTestsContract extends BaseContract {
210
210
  "nonpayable"
211
211
  >;
212
212
 
213
- computeAndChekTransfer64: TypedContractMethod<
213
+ computeAndCheckTransfer64: TypedContractMethod<
214
214
  [
215
215
  allGTCastingValues: TransferTestsContract.AllGTCastingValuesStruct,
216
216
  allAmountValues: TransferTestsContract.AllAmountValuesStruct,
@@ -235,7 +235,7 @@ export interface TransferTestsContract extends BaseContract {
235
235
  ): T;
236
236
 
237
237
  getFunction(
238
- nameOrSignature: "computeAndChekTransfer16"
238
+ nameOrSignature: "computeAndCheckTransfer16"
239
239
  ): TypedContractMethod<
240
240
  [
241
241
  allGTCastingValues: TransferTestsContract.AllGTCastingValuesStruct,
@@ -248,7 +248,7 @@ export interface TransferTestsContract extends BaseContract {
248
248
  "nonpayable"
249
249
  >;
250
250
  getFunction(
251
- nameOrSignature: "computeAndChekTransfer32"
251
+ nameOrSignature: "computeAndCheckTransfer32"
252
252
  ): TypedContractMethod<
253
253
  [
254
254
  allGTCastingValues: TransferTestsContract.AllGTCastingValuesStruct,
@@ -261,7 +261,7 @@ export interface TransferTestsContract extends BaseContract {
261
261
  "nonpayable"
262
262
  >;
263
263
  getFunction(
264
- nameOrSignature: "computeAndChekTransfer64"
264
+ nameOrSignature: "computeAndCheckTransfer64"
265
265
  ): TypedContractMethod<
266
266
  [
267
267
  allGTCastingValues: TransferTestsContract.AllGTCastingValuesStruct,
@@ -1,17 +1,14 @@
1
1
  /* Autogenerated file. Do not edit manually. */
2
2
  /* tslint:disable */
3
3
  /* eslint-disable */
4
- import type * as comparison1TestsContractSol from "./Comparison1Tests.Contract.sol";
5
- export type { comparison1TestsContractSol };
6
- import type * as offboardToUserKeyTestsContractSol from "./OffboardToUserKeyTestsContract.sol";
7
- export type { offboardToUserKeyTestsContractSol };
8
4
  export type { ArithmeticTestsContract } from "./ArithmeticTestsContract";
9
5
  export type { BitwiseTestsContract } from "./BitwiseTestsContract";
6
+ export type { Comparison1TestsContract } from "./Comparison1TestsContract";
10
7
  export type { Comparison2TestsContract } from "./Comparison2TestsContract";
11
8
  export type { MinMaxTestsContract } from "./MinMaxTestsContract";
12
9
  export type { Miscellaneous1TestsContract } from "./Miscellaneous1TestsContract";
13
- export type { Miscellaneous2TestsContract } from "./Miscellaneous2TestsContract";
14
- export type { ShiftTestsContract } from "./ShiftTestsContract";
10
+ export type { MiscellaneousTestsContract } from "./MiscellaneousTestsContract";
11
+ export type { OffboardToUserKeyTestContract } from "./OffboardToUserKeyTestContract";
15
12
  export type { StringTestsContract } from "./StringTestsContract";
16
13
  export type { TransferScalarTestsContract } from "./TransferScalarTestsContract";
17
14
  export type { TransferTestsContract } from "./TransferTestsContract";
@@ -39,11 +39,16 @@ export interface AccountOnboardInterface extends Interface {
39
39
  }
40
40
 
41
41
  export namespace AccountOnboardedEvent {
42
- export type InputTuple = [_from: AddressLike, userKey: BytesLike];
43
- export type OutputTuple = [_from: string, userKey: string];
42
+ export type InputTuple = [
43
+ _from: AddressLike,
44
+ userKey1: BytesLike,
45
+ userKey2: BytesLike
46
+ ];
47
+ export type OutputTuple = [_from: string, userKey1: string, userKey2: string];
44
48
  export interface OutputObject {
45
49
  _from: string;
46
- userKey: string;
50
+ userKey1: string;
51
+ userKey2: string;
47
52
  }
48
53
  export type Event = TypedContractEvent<InputTuple, OutputTuple, OutputObject>;
49
54
  export type Filter = TypedDeferredTopicFilter<Event>;
@@ -121,7 +126,7 @@ export interface AccountOnboard extends BaseContract {
121
126
  >;
122
127
 
123
128
  filters: {
124
- "AccountOnboarded(address,bytes)": TypedContractEvent<
129
+ "AccountOnboarded(address,bytes,bytes)": TypedContractEvent<
125
130
  AccountOnboardedEvent.InputTuple,
126
131
  AccountOnboardedEvent.OutputTuple,
127
132
  AccountOnboardedEvent.OutputObject
@@ -0,0 +1,84 @@
1
+ /* Autogenerated file. Do not edit manually. */
2
+ /* tslint:disable */
3
+ /* eslint-disable */
4
+ import type {
5
+ BaseContract,
6
+ BytesLike,
7
+ FunctionFragment,
8
+ Result,
9
+ Interface,
10
+ ContractRunner,
11
+ ContractMethod,
12
+ Listener,
13
+ } from "ethers";
14
+ import type {
15
+ TypedContractEvent,
16
+ TypedDeferredTopicFilter,
17
+ TypedEventLog,
18
+ TypedListener,
19
+ TypedContractMethod,
20
+ } from "../../../common";
21
+
22
+ export interface MpcCoreInterface extends Interface {
23
+ getFunction(nameOrSignature: "RSA_SIZE"): FunctionFragment;
24
+
25
+ encodeFunctionData(functionFragment: "RSA_SIZE", values?: undefined): string;
26
+
27
+ decodeFunctionResult(functionFragment: "RSA_SIZE", data: BytesLike): Result;
28
+ }
29
+
30
+ export interface MpcCore extends BaseContract {
31
+ connect(runner?: ContractRunner | null): MpcCore;
32
+ waitForDeployment(): Promise<this>;
33
+
34
+ interface: MpcCoreInterface;
35
+
36
+ queryFilter<TCEvent extends TypedContractEvent>(
37
+ event: TCEvent,
38
+ fromBlockOrBlockhash?: string | number | undefined,
39
+ toBlock?: string | number | undefined
40
+ ): Promise<Array<TypedEventLog<TCEvent>>>;
41
+ queryFilter<TCEvent extends TypedContractEvent>(
42
+ filter: TypedDeferredTopicFilter<TCEvent>,
43
+ fromBlockOrBlockhash?: string | number | undefined,
44
+ toBlock?: string | number | undefined
45
+ ): Promise<Array<TypedEventLog<TCEvent>>>;
46
+
47
+ on<TCEvent extends TypedContractEvent>(
48
+ event: TCEvent,
49
+ listener: TypedListener<TCEvent>
50
+ ): Promise<this>;
51
+ on<TCEvent extends TypedContractEvent>(
52
+ filter: TypedDeferredTopicFilter<TCEvent>,
53
+ listener: TypedListener<TCEvent>
54
+ ): Promise<this>;
55
+
56
+ once<TCEvent extends TypedContractEvent>(
57
+ event: TCEvent,
58
+ listener: TypedListener<TCEvent>
59
+ ): Promise<this>;
60
+ once<TCEvent extends TypedContractEvent>(
61
+ filter: TypedDeferredTopicFilter<TCEvent>,
62
+ listener: TypedListener<TCEvent>
63
+ ): Promise<this>;
64
+
65
+ listeners<TCEvent extends TypedContractEvent>(
66
+ event: TCEvent
67
+ ): Promise<Array<TypedListener<TCEvent>>>;
68
+ listeners(eventName?: string): Promise<Array<Listener>>;
69
+ removeAllListeners<TCEvent extends TypedContractEvent>(
70
+ event?: TCEvent
71
+ ): Promise<this>;
72
+
73
+ RSA_SIZE: TypedContractMethod<[], [bigint], "view">;
74
+
75
+ getFunction<T extends ContractMethod = ContractMethod>(
76
+ key: string | FunctionFragment
77
+ ): T;
78
+
79
+ getFunction(
80
+ nameOrSignature: "RSA_SIZE"
81
+ ): TypedContractMethod<[], [bigint], "view">;
82
+
83
+ filters: {};
84
+ }
@@ -25,7 +25,11 @@ export interface ExtendedOperationsInterface extends Interface {
25
25
  nameOrSignature:
26
26
  | "Add"
27
27
  | "And"
28
+ | "CheckedAdd"
29
+ | "CheckedMul"
30
+ | "CheckedSub"
28
31
  | "Decrypt"
32
+ | "DeleteUserKey"
29
33
  | "Div"
30
34
  | "Eq"
31
35
  | "Ge"
@@ -47,8 +51,6 @@ export interface ExtendedOperationsInterface extends Interface {
47
51
  | "RandBoundedBits"
48
52
  | "Rem"
49
53
  | "SetPublic"
50
- | "Shl"
51
- | "Shr"
52
54
  | "Sub"
53
55
  | "Transfer"
54
56
  | "TransferWithAllowance"
@@ -64,10 +66,26 @@ export interface ExtendedOperationsInterface extends Interface {
64
66
  functionFragment: "And",
65
67
  values: [BytesLike, BigNumberish, BigNumberish]
66
68
  ): string;
69
+ encodeFunctionData(
70
+ functionFragment: "CheckedAdd",
71
+ values: [BytesLike, BigNumberish, BigNumberish]
72
+ ): string;
73
+ encodeFunctionData(
74
+ functionFragment: "CheckedMul",
75
+ values: [BytesLike, BigNumberish, BigNumberish]
76
+ ): string;
77
+ encodeFunctionData(
78
+ functionFragment: "CheckedSub",
79
+ values: [BytesLike, BigNumberish, BigNumberish]
80
+ ): string;
67
81
  encodeFunctionData(
68
82
  functionFragment: "Decrypt",
69
83
  values: [BytesLike, BigNumberish]
70
84
  ): string;
85
+ encodeFunctionData(
86
+ functionFragment: "DeleteUserKey",
87
+ values: [BytesLike]
88
+ ): string;
71
89
  encodeFunctionData(
72
90
  functionFragment: "Div",
73
91
  values: [BytesLike, BigNumberish, BigNumberish]
@@ -149,14 +167,6 @@ export interface ExtendedOperationsInterface extends Interface {
149
167
  functionFragment: "SetPublic",
150
168
  values: [BytesLike, BigNumberish]
151
169
  ): string;
152
- encodeFunctionData(
153
- functionFragment: "Shl",
154
- values: [BytesLike, BigNumberish, BigNumberish]
155
- ): string;
156
- encodeFunctionData(
157
- functionFragment: "Shr",
158
- values: [BytesLike, BigNumberish, BigNumberish]
159
- ): string;
160
170
  encodeFunctionData(
161
171
  functionFragment: "Sub",
162
172
  values: [BytesLike, BigNumberish, BigNumberish]
@@ -180,7 +190,14 @@ export interface ExtendedOperationsInterface extends Interface {
180
190
 
181
191
  decodeFunctionResult(functionFragment: "Add", data: BytesLike): Result;
182
192
  decodeFunctionResult(functionFragment: "And", data: BytesLike): Result;
193
+ decodeFunctionResult(functionFragment: "CheckedAdd", data: BytesLike): Result;
194
+ decodeFunctionResult(functionFragment: "CheckedMul", data: BytesLike): Result;
195
+ decodeFunctionResult(functionFragment: "CheckedSub", data: BytesLike): Result;
183
196
  decodeFunctionResult(functionFragment: "Decrypt", data: BytesLike): Result;
197
+ decodeFunctionResult(
198
+ functionFragment: "DeleteUserKey",
199
+ data: BytesLike
200
+ ): Result;
184
201
  decodeFunctionResult(functionFragment: "Div", data: BytesLike): Result;
185
202
  decodeFunctionResult(functionFragment: "Eq", data: BytesLike): Result;
186
203
  decodeFunctionResult(functionFragment: "Ge", data: BytesLike): Result;
@@ -208,8 +225,6 @@ export interface ExtendedOperationsInterface extends Interface {
208
225
  ): Result;
209
226
  decodeFunctionResult(functionFragment: "Rem", data: BytesLike): Result;
210
227
  decodeFunctionResult(functionFragment: "SetPublic", data: BytesLike): Result;
211
- decodeFunctionResult(functionFragment: "Shl", data: BytesLike): Result;
212
- decodeFunctionResult(functionFragment: "Shr", data: BytesLike): Result;
213
228
  decodeFunctionResult(functionFragment: "Sub", data: BytesLike): Result;
214
229
  decodeFunctionResult(functionFragment: "Transfer", data: BytesLike): Result;
215
230
  decodeFunctionResult(
@@ -278,12 +293,36 @@ export interface ExtendedOperations extends BaseContract {
278
293
  "nonpayable"
279
294
  >;
280
295
 
296
+ CheckedAdd: TypedContractMethod<
297
+ [metaData: BytesLike, lhs: BigNumberish, rhs: BigNumberish],
298
+ [[bigint, bigint] & { overflowBit: bigint; result: bigint }],
299
+ "nonpayable"
300
+ >;
301
+
302
+ CheckedMul: TypedContractMethod<
303
+ [metaData: BytesLike, lhs: BigNumberish, rhs: BigNumberish],
304
+ [[bigint, bigint] & { overflowBit: bigint; result: bigint }],
305
+ "nonpayable"
306
+ >;
307
+
308
+ CheckedSub: TypedContractMethod<
309
+ [metaData: BytesLike, lhs: BigNumberish, rhs: BigNumberish],
310
+ [[bigint, bigint] & { overflowBit: bigint; result: bigint }],
311
+ "nonpayable"
312
+ >;
313
+
281
314
  Decrypt: TypedContractMethod<
282
315
  [metaData: BytesLike, a: BigNumberish],
283
316
  [bigint],
284
317
  "nonpayable"
285
318
  >;
286
319
 
320
+ DeleteUserKey: TypedContractMethod<
321
+ [signature: BytesLike],
322
+ [boolean],
323
+ "nonpayable"
324
+ >;
325
+
287
326
  Div: TypedContractMethod<
288
327
  [metaData: BytesLike, lhs: BigNumberish, rhs: BigNumberish],
289
328
  [bigint],
@@ -302,7 +341,11 @@ export interface ExtendedOperations extends BaseContract {
302
341
  "nonpayable"
303
342
  >;
304
343
 
305
- GetUserKey: TypedContractMethod<[signedEK: BytesLike], [string], "view">;
344
+ GetUserKey: TypedContractMethod<
345
+ [signedEK: BytesLike],
346
+ [string],
347
+ "nonpayable"
348
+ >;
306
349
 
307
350
  Gt: TypedContractMethod<
308
351
  [metaData: BytesLike, lhs: BigNumberish, rhs: BigNumberish],
@@ -402,18 +445,6 @@ export interface ExtendedOperations extends BaseContract {
402
445
  "nonpayable"
403
446
  >;
404
447
 
405
- Shl: TypedContractMethod<
406
- [metaData: BytesLike, lhs: BigNumberish, rhs: BigNumberish],
407
- [bigint],
408
- "nonpayable"
409
- >;
410
-
411
- Shr: TypedContractMethod<
412
- [metaData: BytesLike, lhs: BigNumberish, rhs: BigNumberish],
413
- [bigint],
414
- "nonpayable"
415
- >;
416
-
417
448
  Sub: TypedContractMethod<
418
449
  [metaData: BytesLike, lhs: BigNumberish, rhs: BigNumberish],
419
450
  [bigint],
@@ -480,6 +511,27 @@ export interface ExtendedOperations extends BaseContract {
480
511
  [bigint],
481
512
  "nonpayable"
482
513
  >;
514
+ getFunction(
515
+ nameOrSignature: "CheckedAdd"
516
+ ): TypedContractMethod<
517
+ [metaData: BytesLike, lhs: BigNumberish, rhs: BigNumberish],
518
+ [[bigint, bigint] & { overflowBit: bigint; result: bigint }],
519
+ "nonpayable"
520
+ >;
521
+ getFunction(
522
+ nameOrSignature: "CheckedMul"
523
+ ): TypedContractMethod<
524
+ [metaData: BytesLike, lhs: BigNumberish, rhs: BigNumberish],
525
+ [[bigint, bigint] & { overflowBit: bigint; result: bigint }],
526
+ "nonpayable"
527
+ >;
528
+ getFunction(
529
+ nameOrSignature: "CheckedSub"
530
+ ): TypedContractMethod<
531
+ [metaData: BytesLike, lhs: BigNumberish, rhs: BigNumberish],
532
+ [[bigint, bigint] & { overflowBit: bigint; result: bigint }],
533
+ "nonpayable"
534
+ >;
483
535
  getFunction(
484
536
  nameOrSignature: "Decrypt"
485
537
  ): TypedContractMethod<
@@ -487,6 +539,9 @@ export interface ExtendedOperations extends BaseContract {
487
539
  [bigint],
488
540
  "nonpayable"
489
541
  >;
542
+ getFunction(
543
+ nameOrSignature: "DeleteUserKey"
544
+ ): TypedContractMethod<[signature: BytesLike], [boolean], "nonpayable">;
490
545
  getFunction(
491
546
  nameOrSignature: "Div"
492
547
  ): TypedContractMethod<
@@ -510,7 +565,7 @@ export interface ExtendedOperations extends BaseContract {
510
565
  >;
511
566
  getFunction(
512
567
  nameOrSignature: "GetUserKey"
513
- ): TypedContractMethod<[signedEK: BytesLike], [string], "view">;
568
+ ): TypedContractMethod<[signedEK: BytesLike], [string], "nonpayable">;
514
569
  getFunction(
515
570
  nameOrSignature: "Gt"
516
571
  ): TypedContractMethod<
@@ -626,20 +681,6 @@ export interface ExtendedOperations extends BaseContract {
626
681
  [bigint],
627
682
  "nonpayable"
628
683
  >;
629
- getFunction(
630
- nameOrSignature: "Shl"
631
- ): TypedContractMethod<
632
- [metaData: BytesLike, lhs: BigNumberish, rhs: BigNumberish],
633
- [bigint],
634
- "nonpayable"
635
- >;
636
- getFunction(
637
- nameOrSignature: "Shr"
638
- ): TypedContractMethod<
639
- [metaData: BytesLike, lhs: BigNumberish, rhs: BigNumberish],
640
- [bigint],
641
- "nonpayable"
642
- >;
643
684
  getFunction(
644
685
  nameOrSignature: "Sub"
645
686
  ): TypedContractMethod<
@@ -3,3 +3,4 @@
3
3
  /* eslint-disable */
4
4
  import type * as mpcInterfaceSol from "./MpcInterface.sol";
5
5
  export type { mpcInterfaceSol };
6
+ export type { MpcCore } from "./MpcCore";