@cofhe/mock-contracts 0.0.0-beta-20251027110729

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.
@@ -0,0 +1,350 @@
1
+ // This file is auto-generated by build-artifacts.ts
2
+ import { type MocksArtifact } from './index';
3
+
4
+ export const MockQueryDecrypterArtifact = {
5
+ "contractName": "MockQueryDecrypter",
6
+ "fixedAddress": "0x0000000000000000000000000000000000000200",
7
+ "abi": [
8
+ {
9
+ "type": "function",
10
+ "name": "decodeLowLevelReversion",
11
+ "inputs": [
12
+ {
13
+ "name": "data",
14
+ "type": "bytes",
15
+ "internalType": "bytes"
16
+ }
17
+ ],
18
+ "outputs": [
19
+ {
20
+ "name": "error",
21
+ "type": "string",
22
+ "internalType": "string"
23
+ }
24
+ ],
25
+ "stateMutability": "pure"
26
+ },
27
+ {
28
+ "type": "function",
29
+ "name": "exists",
30
+ "inputs": [],
31
+ "outputs": [
32
+ {
33
+ "name": "",
34
+ "type": "bool",
35
+ "internalType": "bool"
36
+ }
37
+ ],
38
+ "stateMutability": "pure"
39
+ },
40
+ {
41
+ "type": "function",
42
+ "name": "initialize",
43
+ "inputs": [
44
+ {
45
+ "name": "_taskManager",
46
+ "type": "address",
47
+ "internalType": "address"
48
+ },
49
+ {
50
+ "name": "_acl",
51
+ "type": "address",
52
+ "internalType": "address"
53
+ }
54
+ ],
55
+ "outputs": [],
56
+ "stateMutability": "nonpayable"
57
+ },
58
+ {
59
+ "type": "function",
60
+ "name": "mockAcl",
61
+ "inputs": [],
62
+ "outputs": [
63
+ {
64
+ "name": "",
65
+ "type": "address",
66
+ "internalType": "contract MockACL"
67
+ }
68
+ ],
69
+ "stateMutability": "view"
70
+ },
71
+ {
72
+ "type": "function",
73
+ "name": "mockQueryDecrypt",
74
+ "inputs": [
75
+ {
76
+ "name": "ctHash",
77
+ "type": "uint256",
78
+ "internalType": "uint256"
79
+ },
80
+ {
81
+ "name": "",
82
+ "type": "uint256",
83
+ "internalType": "uint256"
84
+ },
85
+ {
86
+ "name": "issuer",
87
+ "type": "address",
88
+ "internalType": "address"
89
+ }
90
+ ],
91
+ "outputs": [
92
+ {
93
+ "name": "allowed",
94
+ "type": "bool",
95
+ "internalType": "bool"
96
+ },
97
+ {
98
+ "name": "error",
99
+ "type": "string",
100
+ "internalType": "string"
101
+ },
102
+ {
103
+ "name": "",
104
+ "type": "uint256",
105
+ "internalType": "uint256"
106
+ }
107
+ ],
108
+ "stateMutability": "view"
109
+ },
110
+ {
111
+ "type": "function",
112
+ "name": "mockTaskManager",
113
+ "inputs": [],
114
+ "outputs": [
115
+ {
116
+ "name": "",
117
+ "type": "address",
118
+ "internalType": "contract MockTaskManager"
119
+ }
120
+ ],
121
+ "stateMutability": "view"
122
+ },
123
+ {
124
+ "type": "function",
125
+ "name": "queryDecrypt",
126
+ "inputs": [
127
+ {
128
+ "name": "ctHash",
129
+ "type": "uint256",
130
+ "internalType": "uint256"
131
+ },
132
+ {
133
+ "name": "",
134
+ "type": "uint256",
135
+ "internalType": "uint256"
136
+ },
137
+ {
138
+ "name": "permission",
139
+ "type": "tuple",
140
+ "internalType": "struct Permission",
141
+ "components": [
142
+ {
143
+ "name": "issuer",
144
+ "type": "address",
145
+ "internalType": "address"
146
+ },
147
+ {
148
+ "name": "expiration",
149
+ "type": "uint64",
150
+ "internalType": "uint64"
151
+ },
152
+ {
153
+ "name": "recipient",
154
+ "type": "address",
155
+ "internalType": "address"
156
+ },
157
+ {
158
+ "name": "validatorId",
159
+ "type": "uint256",
160
+ "internalType": "uint256"
161
+ },
162
+ {
163
+ "name": "validatorContract",
164
+ "type": "address",
165
+ "internalType": "address"
166
+ },
167
+ {
168
+ "name": "sealingKey",
169
+ "type": "bytes32",
170
+ "internalType": "bytes32"
171
+ },
172
+ {
173
+ "name": "issuerSignature",
174
+ "type": "bytes",
175
+ "internalType": "bytes"
176
+ },
177
+ {
178
+ "name": "recipientSignature",
179
+ "type": "bytes",
180
+ "internalType": "bytes"
181
+ }
182
+ ]
183
+ }
184
+ ],
185
+ "outputs": [
186
+ {
187
+ "name": "allowed",
188
+ "type": "bool",
189
+ "internalType": "bool"
190
+ },
191
+ {
192
+ "name": "error",
193
+ "type": "string",
194
+ "internalType": "string"
195
+ },
196
+ {
197
+ "name": "",
198
+ "type": "uint256",
199
+ "internalType": "uint256"
200
+ }
201
+ ],
202
+ "stateMutability": "view"
203
+ },
204
+ {
205
+ "type": "function",
206
+ "name": "querySealOutput",
207
+ "inputs": [
208
+ {
209
+ "name": "ctHash",
210
+ "type": "uint256",
211
+ "internalType": "uint256"
212
+ },
213
+ {
214
+ "name": "",
215
+ "type": "uint256",
216
+ "internalType": "uint256"
217
+ },
218
+ {
219
+ "name": "permission",
220
+ "type": "tuple",
221
+ "internalType": "struct Permission",
222
+ "components": [
223
+ {
224
+ "name": "issuer",
225
+ "type": "address",
226
+ "internalType": "address"
227
+ },
228
+ {
229
+ "name": "expiration",
230
+ "type": "uint64",
231
+ "internalType": "uint64"
232
+ },
233
+ {
234
+ "name": "recipient",
235
+ "type": "address",
236
+ "internalType": "address"
237
+ },
238
+ {
239
+ "name": "validatorId",
240
+ "type": "uint256",
241
+ "internalType": "uint256"
242
+ },
243
+ {
244
+ "name": "validatorContract",
245
+ "type": "address",
246
+ "internalType": "address"
247
+ },
248
+ {
249
+ "name": "sealingKey",
250
+ "type": "bytes32",
251
+ "internalType": "bytes32"
252
+ },
253
+ {
254
+ "name": "issuerSignature",
255
+ "type": "bytes",
256
+ "internalType": "bytes"
257
+ },
258
+ {
259
+ "name": "recipientSignature",
260
+ "type": "bytes",
261
+ "internalType": "bytes"
262
+ }
263
+ ]
264
+ }
265
+ ],
266
+ "outputs": [
267
+ {
268
+ "name": "allowed",
269
+ "type": "bool",
270
+ "internalType": "bool"
271
+ },
272
+ {
273
+ "name": "error",
274
+ "type": "string",
275
+ "internalType": "string"
276
+ },
277
+ {
278
+ "name": "",
279
+ "type": "bytes32",
280
+ "internalType": "bytes32"
281
+ }
282
+ ],
283
+ "stateMutability": "view"
284
+ },
285
+ {
286
+ "type": "function",
287
+ "name": "seal",
288
+ "inputs": [
289
+ {
290
+ "name": "input",
291
+ "type": "uint256",
292
+ "internalType": "uint256"
293
+ },
294
+ {
295
+ "name": "key",
296
+ "type": "bytes32",
297
+ "internalType": "bytes32"
298
+ }
299
+ ],
300
+ "outputs": [
301
+ {
302
+ "name": "",
303
+ "type": "bytes32",
304
+ "internalType": "bytes32"
305
+ }
306
+ ],
307
+ "stateMutability": "pure"
308
+ },
309
+ {
310
+ "type": "function",
311
+ "name": "unseal",
312
+ "inputs": [
313
+ {
314
+ "name": "hashed",
315
+ "type": "bytes32",
316
+ "internalType": "bytes32"
317
+ },
318
+ {
319
+ "name": "key",
320
+ "type": "bytes32",
321
+ "internalType": "bytes32"
322
+ }
323
+ ],
324
+ "outputs": [
325
+ {
326
+ "name": "",
327
+ "type": "uint256",
328
+ "internalType": "uint256"
329
+ }
330
+ ],
331
+ "stateMutability": "pure"
332
+ },
333
+ {
334
+ "type": "error",
335
+ "name": "NotAllowed",
336
+ "inputs": []
337
+ },
338
+ {
339
+ "type": "error",
340
+ "name": "SealingKeyInvalid",
341
+ "inputs": []
342
+ },
343
+ {
344
+ "type": "error",
345
+ "name": "SealingKeyMissing",
346
+ "inputs": []
347
+ }
348
+ ],
349
+ "deployedBytecode": "0x608060405234801561000f575f5ffd5b506004361061009c575f3560e01c80637e0f4b5b116100645780637e0f4b5b1461015a5780638a5c8c7f14610178578063a02eb534146101a8578063a0639f54146101da578063ff6957d31461020c5761009c565b806309ba3156146100a05780631a1992a9146100d2578063267c4ae414610102578063485cc955146101205780634cdc014d1461013c575b5f5ffd5b6100ba60048036038101906100b591906110b5565b61023c565b6040516100c9939291906111aa565b60405180910390f35b6100ec60048036038101906100e791906111e6565b61051f565b6040516100f99190611224565b60405180910390f35b61010a61052d565b604051610117919061123d565b60405180910390f35b61013a60048036038101906101359190611256565b610535565b005b6101446105b8565b60405161015191906112ef565b60405180910390f35b6101626105dd565b60405161016f9190611328565b60405180910390f35b610192600480360381019061018d9190611341565b610601565b60405161019f919061138e565b60405180910390f35b6101c260048036038101906101bd91906113a7565b61060f565b6040516101d1939291906113f7565b60405180910390f35b6101f460048036038101906101ef91906110b5565b61089e565b604051610203939291906113f7565b60405180910390f35b61022660048036038101906102219190611433565b610b28565b604051610233919061147a565b60405180910390f35b5f60605f5f5f1b8460a001510361027f576040517fb78926d800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b5f60015f9054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663ae79f04a86896040518363ffffffff1660e01b81526004016102dc9291906115dc565b602060405180830381865afa92505050801561031657506040513d601f19601f820116820180604052508101906103139190611634565b60015b6104025761032261166b565b806308c379a003610353575061033661168a565b8061034157506103b8565b5f815f5f1b9450945094505050610516565b634e487b71036103b857610365611719565b9061037057506103b8565b5f5f5f1b6040518060400160405280600581526020017f50616e6963000000000000000000000000000000000000000000000000000000815250909450945094505050610516565b3d805f81146103e2576040519150601f19603f3d011682016040523d82523d5f602084013e6103e7565b606091505b505f6103f282610b28565b5f5f1b9450945094505050610516565b8091505080610452575f5f5f1b6040518060400160405280600a81526020017f4e6f74416c6c6f776564000000000000000000000000000000000000000000008152509093509350935050610516565b5f5f5f9054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16631c76642b896040518263ffffffff1660e01b81526004016104ac919061138e565b602060405180830381865afa1580156104c7573d5f5f3e3d5ffd5b505050506040513d601f19601f820116820180604052508101906104eb919061174b565b905060016104fd828860a0015161051f565b60405180602001604052805f8152509094509450945050505b93509350939050565b5f81835f1b18905092915050565b5f6001905090565b815f5f6101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff1602179055508060015f6101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff1602179055505050565b60015f9054906101000a900473ffffffffffffffffffffffffffffffffffffffff1681565b5f5f9054906101000a900473ffffffffffffffffffffffffffffffffffffffff1681565b5f8183185f1c905092915050565b5f60605f5f60015f9054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16635faa299a88876040518363ffffffff1660e01b8152600401610670929190611785565b602060405180830381865afa9250505080156106aa57506040513d601f19601f820116820180604052508101906106a79190611634565b60015b610790576106b661166b565b806308c379a0036106e557506106ca61168a565b806106d55750610748565b5f815f9450945094505050610895565b634e487b7103610748576106f7611719565b906107025750610748565b5f5f6040518060400160405280600581526020017f50616e6963000000000000000000000000000000000000000000000000000000815250909450945094505050610895565b3d805f8114610772576040519150601f19603f3d011682016040523d82523d5f602084013e610777565b606091505b505f61078282610b28565b5f9450945094505050610895565b80915050806107de575f5f6040518060400160405280600a81526020017f4e6f74416c6c6f776564000000000000000000000000000000000000000000008152509093509350935050610895565b5f5f5f9054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16631c76642b896040518263ffffffff1660e01b8152600401610838919061138e565b602060405180830381865afa158015610853573d5f5f3e3d5ffd5b505050506040513d601f19601f82011682018060405250810190610877919061174b565b905060018160405180602001604052805f8152509094509450945050505b93509350939050565b5f60605f5f60015f9054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663ae79f04a86896040518363ffffffff1660e01b81526004016108ff9291906115dc565b602060405180830381865afa92505050801561093957506040513d601f19601f820116820180604052508101906109369190611634565b60015b610a1f5761094561166b565b806308c379a003610974575061095961168a565b8061096457506109d7565b5f815f9450945094505050610b1f565b634e487b71036109d757610986611719565b9061099157506109d7565b5f5f6040518060400160405280600581526020017f50616e6963000000000000000000000000000000000000000000000000000000815250909450945094505050610b1f565b3d805f8114610a01576040519150601f19603f3d011682016040523d82523d5f602084013e610a06565b606091505b505f610a1182610b28565b5f9450945094505050610b1f565b8091505080610a6d575f5f6040518060400160405280600a81526020017f4e6f74416c6c6f776564000000000000000000000000000000000000000000008152509093509350935050610b1f565b60015f5f9054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16631c76642b896040518263ffffffff1660e01b8152600401610ac8919061138e565b602060405180830381865afa158015610ae3573d5f5f3e3d5ffd5b505050506040513d601f19601f82011682018060405250810190610b07919061174b565b60405180602001604052805f81525090935093509350505b93509350939050565b60605f82610b3590611806565b905063ed0764a160e01b7bffffffffffffffffffffffffffffffffffffffffffffffffffffffff1916817bffffffffffffffffffffffffffffffffffffffffffffffffffffffff191603610bc1576040518060400160405280601981526020017f5065726d697373696f6e496e76616c69645f4578706972656400000000000000815250915050610d5f565b634c40eccb60e01b7bffffffffffffffffffffffffffffffffffffffffffffffffffffffff1916817bffffffffffffffffffffffffffffffffffffffffffffffffffffffff191603610c2e5760405180606001604052806021815260200161189160219139915050610d5f565b638e143bf760e01b7bffffffffffffffffffffffffffffffffffffffffffffffffffffffff1916817bffffffffffffffffffffffffffffffffffffffffffffffffffffffff191603610c9b5760405180606001604052806024815260200161186d60249139915050610d5f565b63cbd3a96660e01b7bffffffffffffffffffffffffffffffffffffffffffffffffffffffff1916817bffffffffffffffffffffffffffffffffffffffffffffffffffffffff191603610d25576040518060400160405280601a81526020017f5065726d697373696f6e496e76616c69645f44697361626c6564000000000000815250915050610d5f565b6040518060400160405280600f81526020017f4c6f77204c6576656c204572726f7200000000000000000000000000000000008152509150505b919050565b5f604051905090565b5f5ffd5b5f5ffd5b5f819050919050565b610d8781610d75565b8114610d91575f5ffd5b50565b5f81359050610da281610d7e565b92915050565b5f5ffd5b5f601f19601f8301169050919050565b7f4e487b71000000000000000000000000000000000000000000000000000000005f52604160045260245ffd5b610df282610dac565b810181811067ffffffffffffffff82111715610e1157610e10610dbc565b5b80604052505050565b5f610e23610d64565b9050610e2f8282610de9565b919050565b5f5ffd5b5f73ffffffffffffffffffffffffffffffffffffffff82169050919050565b5f610e6182610e38565b9050919050565b610e7181610e57565b8114610e7b575f5ffd5b50565b5f81359050610e8c81610e68565b92915050565b5f67ffffffffffffffff82169050919050565b610eae81610e92565b8114610eb8575f5ffd5b50565b5f81359050610ec981610ea5565b92915050565b5f819050919050565b610ee181610ecf565b8114610eeb575f5ffd5b50565b5f81359050610efc81610ed8565b92915050565b5f5ffd5b5f5ffd5b5f67ffffffffffffffff821115610f2457610f23610dbc565b5b610f2d82610dac565b9050602081019050919050565b828183375f83830152505050565b5f610f5a610f5584610f0a565b610e1a565b905082815260208101848484011115610f7657610f75610f06565b5b610f81848285610f3a565b509392505050565b5f82601f830112610f9d57610f9c610f02565b5b8135610fad848260208601610f48565b91505092915050565b5f6101008284031215610fcc57610fcb610da8565b5b610fd7610100610e1a565b90505f610fe684828501610e7e565b5f830152506020610ff984828501610ebb565b602083015250604061100d84828501610e7e565b604083015250606061102184828501610d94565b606083015250608061103584828501610e7e565b60808301525060a061104984828501610eee565b60a08301525060c082013567ffffffffffffffff81111561106d5761106c610e34565b5b61107984828501610f89565b60c08301525060e082013567ffffffffffffffff81111561109d5761109c610e34565b5b6110a984828501610f89565b60e08301525092915050565b5f5f5f606084860312156110cc576110cb610d6d565b5b5f6110d986828701610d94565b93505060206110ea86828701610d94565b925050604084013567ffffffffffffffff81111561110b5761110a610d71565b5b61111786828701610fb6565b9150509250925092565b5f8115159050919050565b61113581611121565b82525050565b5f81519050919050565b5f82825260208201905092915050565b8281835e5f83830152505050565b5f61116d8261113b565b6111778185611145565b9350611187818560208601611155565b61119081610dac565b840191505092915050565b6111a481610ecf565b82525050565b5f6060820190506111bd5f83018661112c565b81810360208301526111cf8185611163565b90506111de604083018461119b565b949350505050565b5f5f604083850312156111fc576111fb610d6d565b5b5f61120985828601610d94565b925050602061121a85828601610eee565b9150509250929050565b5f6020820190506112375f83018461119b565b92915050565b5f6020820190506112505f83018461112c565b92915050565b5f5f6040838503121561126c5761126b610d6d565b5b5f61127985828601610e7e565b925050602061128a85828601610e7e565b9150509250929050565b5f819050919050565b5f6112b76112b26112ad84610e38565b611294565b610e38565b9050919050565b5f6112c88261129d565b9050919050565b5f6112d9826112be565b9050919050565b6112e9816112cf565b82525050565b5f6020820190506113025f8301846112e0565b92915050565b5f611312826112be565b9050919050565b61132281611308565b82525050565b5f60208201905061133b5f830184611319565b92915050565b5f5f6040838503121561135757611356610d6d565b5b5f61136485828601610eee565b925050602061137585828601610eee565b9150509250929050565b61138881610d75565b82525050565b5f6020820190506113a15f83018461137f565b92915050565b5f5f5f606084860312156113be576113bd610d6d565b5b5f6113cb86828701610d94565b93505060206113dc86828701610d94565b92505060406113ed86828701610e7e565b9150509250925092565b5f60608201905061140a5f83018661112c565b818103602083015261141c8185611163565b905061142b604083018461137f565b949350505050565b5f6020828403121561144857611447610d6d565b5b5f82013567ffffffffffffffff81111561146557611464610d71565b5b61147184828501610f89565b91505092915050565b5f6020820190508181035f8301526114928184611163565b905092915050565b6114a381610e57565b82525050565b6114b281610e92565b82525050565b6114c181610d75565b82525050565b6114d081610ecf565b82525050565b5f81519050919050565b5f82825260208201905092915050565b5f6114fa826114d6565b61150481856114e0565b9350611514818560208601611155565b61151d81610dac565b840191505092915050565b5f61010083015f83015161153e5f86018261149a565b50602083015161155160208601826114a9565b506040830151611564604086018261149a565b50606083015161157760608601826114b8565b50608083015161158a608086018261149a565b5060a083015161159d60a08601826114c7565b5060c083015184820360c08601526115b582826114f0565b91505060e083015184820360e08601526115cf82826114f0565b9150508091505092915050565b5f6040820190508181035f8301526115f48185611528565b9050611603602083018461137f565b9392505050565b61161381611121565b811461161d575f5ffd5b50565b5f8151905061162e8161160a565b92915050565b5f6020828403121561164957611648610d6d565b5b5f61165684828501611620565b91505092915050565b5f8160e01c9050919050565b5f60033d11156116875760045f5f3e6116845f5161165f565b90505b90565b5f60443d106117165761169b610d64565b60043d036004823e80513d602482011167ffffffffffffffff821117156116c3575050611716565b808201805167ffffffffffffffff8111156116e15750505050611716565b80602083010160043d0385018111156116fe575050505050611716565b61170d82602001850186610de9565b82955050505050505b90565b5f5f60233d111561173357602060045f3e600191505f5190505b9091565b5f8151905061174581610d7e565b92915050565b5f602082840312156117605761175f610d6d565b5b5f61176d84828501611737565b91505092915050565b61177f81610e57565b82525050565b5f6040820190506117985f83018561137f565b6117a56020830184611776565b9392505050565b5f819050602082019050919050565b5f7fffffffff0000000000000000000000000000000000000000000000000000000082169050919050565b5f6117f182516117bb565b80915050919050565b5f82821b905092915050565b5f611810826114d6565b8261181a846117ac565b9050611825816117e6565b92506004821015611865576118607fffffffff00000000000000000000000000000000000000000000000000000000836004036008026117fa565b831692505b505091905056fe5065726d697373696f6e496e76616c69645f526563697069656e745369676e61747572655065726d697373696f6e496e76616c69645f4973737565725369676e6174757265a2646970667358221220fa3be26f428c881bbc66076a1abb7d52826a97cb40ed8a95f18aaa40de450ab364736f6c634300081e0033"
350
+ } satisfies MocksArtifact;