@layerzerolabs/lz-evm-protocol-v2 2.0.2

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 (51) hide show
  1. package/artifacts/contracts/EndpointV2.sol/EndpointV2.json +2364 -0
  2. package/artifacts/contracts/EndpointV2Alt.sol/EndpointV2Alt.json +2379 -0
  3. package/artifacts/contracts/MessageLibManager.sol/MessageLibManager.json +783 -0
  4. package/artifacts/contracts/MessagingChannel.sol/MessagingChannel.json +426 -0
  5. package/artifacts/contracts/MessagingComposer.sol/MessagingComposer.json +320 -0
  6. package/artifacts/contracts/MessagingContext.sol/MessagingContext.json +42 -0
  7. package/artifacts/contracts/interfaces/ILayerZeroComposer.sol/ILayerZeroComposer.json +44 -0
  8. package/artifacts/contracts/interfaces/ILayerZeroEndpointV2.sol/ILayerZeroEndpointV2.json +1844 -0
  9. package/artifacts/contracts/interfaces/ILayerZeroReceiver.sol/ILayerZeroReceiver.json +121 -0
  10. package/artifacts/contracts/interfaces/IMessageLib.sol/IMessageLib.json +149 -0
  11. package/artifacts/contracts/interfaces/IMessageLibManager.sol/IMessageLibManager.json +629 -0
  12. package/artifacts/contracts/interfaces/IMessagingChannel.sol/IMessagingChannel.json +344 -0
  13. package/artifacts/contracts/interfaces/IMessagingComposer.sol/IMessagingComposer.json +246 -0
  14. package/artifacts/contracts/interfaces/IMessagingContext.sol/IMessagingContext.json +42 -0
  15. package/artifacts/contracts/interfaces/ISendLib.sol/ISendLib.json +364 -0
  16. package/artifacts/contracts/libs/AddressCast.sol/AddressCast.json +10 -0
  17. package/artifacts/contracts/libs/CalldataBytesLib.sol/CalldataBytesLib.json +10 -0
  18. package/artifacts/contracts/libs/Errors.sol/Errors.json +226 -0
  19. package/artifacts/contracts/libs/GUID.sol/GUID.json +10 -0
  20. package/artifacts/contracts/libs/Transfer.sol/Transfer.json +32 -0
  21. package/artifacts/contracts/messagelib/BlockedMessageLib.sol/BlockedMessageLib.json +94 -0
  22. package/artifacts/contracts/messagelib/SimpleMessageLib.sol/SimpleMessageLib.json +591 -0
  23. package/artifacts/contracts/messagelib/libs/BitMaps.sol/BitMaps.json +10 -0
  24. package/artifacts/contracts/messagelib/libs/ExecutorOptions.sol/ExecutorOptions.json +26 -0
  25. package/artifacts/contracts/messagelib/libs/PacketV1Codec.sol/PacketV1Codec.json +10 -0
  26. package/contracts/EndpointV2.sol +403 -0
  27. package/contracts/EndpointV2Alt.sol +50 -0
  28. package/contracts/MessageLibManager.sol +326 -0
  29. package/contracts/MessagingChannel.sol +161 -0
  30. package/contracts/MessagingComposer.sol +80 -0
  31. package/contracts/MessagingContext.sol +36 -0
  32. package/contracts/interfaces/ILayerZeroComposer.sol +24 -0
  33. package/contracts/interfaces/ILayerZeroEndpointV2.sol +98 -0
  34. package/contracts/interfaces/ILayerZeroReceiver.sol +20 -0
  35. package/contracts/interfaces/IMessageLib.sol +26 -0
  36. package/contracts/interfaces/IMessageLibManager.sol +68 -0
  37. package/contracts/interfaces/IMessagingChannel.sol +32 -0
  38. package/contracts/interfaces/IMessagingComposer.sol +38 -0
  39. package/contracts/interfaces/IMessagingContext.sol +9 -0
  40. package/contracts/interfaces/ISendLib.sol +36 -0
  41. package/contracts/libs/AddressCast.sol +40 -0
  42. package/contracts/libs/CalldataBytesLib.sol +58 -0
  43. package/contracts/libs/Errors.sol +42 -0
  44. package/contracts/libs/GUID.sol +19 -0
  45. package/contracts/libs/Transfer.sol +34 -0
  46. package/contracts/messagelib/BlockedMessageLib.sol +30 -0
  47. package/contracts/messagelib/SimpleMessageLib.sol +149 -0
  48. package/contracts/messagelib/libs/BitMaps.sol +26 -0
  49. package/contracts/messagelib/libs/ExecutorOptions.sol +85 -0
  50. package/contracts/messagelib/libs/PacketV1Codec.sol +108 -0
  51. package/package.json +27 -0
@@ -0,0 +1,629 @@
1
+ {
2
+ "_format": "hh-sol-artifact-1",
3
+ "contractName": "IMessageLibManager",
4
+ "sourceName": "contracts/interfaces/IMessageLibManager.sol",
5
+ "abi": [
6
+ {
7
+ "anonymous": false,
8
+ "inputs": [
9
+ {
10
+ "indexed": false,
11
+ "internalType": "uint32",
12
+ "name": "eid",
13
+ "type": "uint32"
14
+ },
15
+ {
16
+ "indexed": false,
17
+ "internalType": "address",
18
+ "name": "oldLib",
19
+ "type": "address"
20
+ },
21
+ {
22
+ "indexed": false,
23
+ "internalType": "address",
24
+ "name": "newLib",
25
+ "type": "address"
26
+ }
27
+ ],
28
+ "name": "DefaultReceiveLibrarySet",
29
+ "type": "event"
30
+ },
31
+ {
32
+ "anonymous": false,
33
+ "inputs": [
34
+ {
35
+ "indexed": false,
36
+ "internalType": "uint32",
37
+ "name": "eid",
38
+ "type": "uint32"
39
+ },
40
+ {
41
+ "indexed": false,
42
+ "internalType": "address",
43
+ "name": "oldLib",
44
+ "type": "address"
45
+ },
46
+ {
47
+ "indexed": false,
48
+ "internalType": "uint256",
49
+ "name": "expiry",
50
+ "type": "uint256"
51
+ }
52
+ ],
53
+ "name": "DefaultReceiveLibraryTimeoutSet",
54
+ "type": "event"
55
+ },
56
+ {
57
+ "anonymous": false,
58
+ "inputs": [
59
+ {
60
+ "indexed": false,
61
+ "internalType": "uint32",
62
+ "name": "eid",
63
+ "type": "uint32"
64
+ },
65
+ {
66
+ "indexed": false,
67
+ "internalType": "address",
68
+ "name": "newLib",
69
+ "type": "address"
70
+ }
71
+ ],
72
+ "name": "DefaultSendLibrarySet",
73
+ "type": "event"
74
+ },
75
+ {
76
+ "anonymous": false,
77
+ "inputs": [
78
+ {
79
+ "indexed": false,
80
+ "internalType": "address",
81
+ "name": "newLib",
82
+ "type": "address"
83
+ }
84
+ ],
85
+ "name": "LibraryRegistered",
86
+ "type": "event"
87
+ },
88
+ {
89
+ "anonymous": false,
90
+ "inputs": [
91
+ {
92
+ "indexed": false,
93
+ "internalType": "address",
94
+ "name": "receiver",
95
+ "type": "address"
96
+ },
97
+ {
98
+ "indexed": false,
99
+ "internalType": "uint32",
100
+ "name": "eid",
101
+ "type": "uint32"
102
+ },
103
+ {
104
+ "indexed": false,
105
+ "internalType": "address",
106
+ "name": "oldLib",
107
+ "type": "address"
108
+ },
109
+ {
110
+ "indexed": false,
111
+ "internalType": "address",
112
+ "name": "newLib",
113
+ "type": "address"
114
+ }
115
+ ],
116
+ "name": "ReceiveLibrarySet",
117
+ "type": "event"
118
+ },
119
+ {
120
+ "anonymous": false,
121
+ "inputs": [
122
+ {
123
+ "indexed": false,
124
+ "internalType": "address",
125
+ "name": "receiver",
126
+ "type": "address"
127
+ },
128
+ {
129
+ "indexed": false,
130
+ "internalType": "uint32",
131
+ "name": "eid",
132
+ "type": "uint32"
133
+ },
134
+ {
135
+ "indexed": false,
136
+ "internalType": "address",
137
+ "name": "oldLib",
138
+ "type": "address"
139
+ },
140
+ {
141
+ "indexed": false,
142
+ "internalType": "uint256",
143
+ "name": "timeout",
144
+ "type": "uint256"
145
+ }
146
+ ],
147
+ "name": "ReceiveLibraryTimeoutSet",
148
+ "type": "event"
149
+ },
150
+ {
151
+ "anonymous": false,
152
+ "inputs": [
153
+ {
154
+ "indexed": false,
155
+ "internalType": "address",
156
+ "name": "sender",
157
+ "type": "address"
158
+ },
159
+ {
160
+ "indexed": false,
161
+ "internalType": "uint32",
162
+ "name": "eid",
163
+ "type": "uint32"
164
+ },
165
+ {
166
+ "indexed": false,
167
+ "internalType": "address",
168
+ "name": "newLib",
169
+ "type": "address"
170
+ }
171
+ ],
172
+ "name": "SendLibrarySet",
173
+ "type": "event"
174
+ },
175
+ {
176
+ "inputs": [
177
+ {
178
+ "internalType": "uint32",
179
+ "name": "_eid",
180
+ "type": "uint32"
181
+ }
182
+ ],
183
+ "name": "defaultReceiveLibrary",
184
+ "outputs": [
185
+ {
186
+ "internalType": "address",
187
+ "name": "",
188
+ "type": "address"
189
+ }
190
+ ],
191
+ "stateMutability": "view",
192
+ "type": "function"
193
+ },
194
+ {
195
+ "inputs": [
196
+ {
197
+ "internalType": "uint32",
198
+ "name": "_eid",
199
+ "type": "uint32"
200
+ }
201
+ ],
202
+ "name": "defaultReceiveLibraryTimeout",
203
+ "outputs": [
204
+ {
205
+ "internalType": "address",
206
+ "name": "lib",
207
+ "type": "address"
208
+ },
209
+ {
210
+ "internalType": "uint256",
211
+ "name": "expiry",
212
+ "type": "uint256"
213
+ }
214
+ ],
215
+ "stateMutability": "view",
216
+ "type": "function"
217
+ },
218
+ {
219
+ "inputs": [
220
+ {
221
+ "internalType": "uint32",
222
+ "name": "_eid",
223
+ "type": "uint32"
224
+ }
225
+ ],
226
+ "name": "defaultSendLibrary",
227
+ "outputs": [
228
+ {
229
+ "internalType": "address",
230
+ "name": "",
231
+ "type": "address"
232
+ }
233
+ ],
234
+ "stateMutability": "view",
235
+ "type": "function"
236
+ },
237
+ {
238
+ "inputs": [
239
+ {
240
+ "internalType": "address",
241
+ "name": "_oapp",
242
+ "type": "address"
243
+ },
244
+ {
245
+ "internalType": "address",
246
+ "name": "_lib",
247
+ "type": "address"
248
+ },
249
+ {
250
+ "internalType": "uint32",
251
+ "name": "_eid",
252
+ "type": "uint32"
253
+ },
254
+ {
255
+ "internalType": "uint32",
256
+ "name": "_configType",
257
+ "type": "uint32"
258
+ }
259
+ ],
260
+ "name": "getConfig",
261
+ "outputs": [
262
+ {
263
+ "internalType": "bytes",
264
+ "name": "config",
265
+ "type": "bytes"
266
+ }
267
+ ],
268
+ "stateMutability": "view",
269
+ "type": "function"
270
+ },
271
+ {
272
+ "inputs": [
273
+ {
274
+ "internalType": "address",
275
+ "name": "_receiver",
276
+ "type": "address"
277
+ },
278
+ {
279
+ "internalType": "uint32",
280
+ "name": "_eid",
281
+ "type": "uint32"
282
+ }
283
+ ],
284
+ "name": "getReceiveLibrary",
285
+ "outputs": [
286
+ {
287
+ "internalType": "address",
288
+ "name": "lib",
289
+ "type": "address"
290
+ },
291
+ {
292
+ "internalType": "bool",
293
+ "name": "isDefault",
294
+ "type": "bool"
295
+ }
296
+ ],
297
+ "stateMutability": "view",
298
+ "type": "function"
299
+ },
300
+ {
301
+ "inputs": [],
302
+ "name": "getRegisteredLibraries",
303
+ "outputs": [
304
+ {
305
+ "internalType": "address[]",
306
+ "name": "",
307
+ "type": "address[]"
308
+ }
309
+ ],
310
+ "stateMutability": "view",
311
+ "type": "function"
312
+ },
313
+ {
314
+ "inputs": [
315
+ {
316
+ "internalType": "address",
317
+ "name": "_sender",
318
+ "type": "address"
319
+ },
320
+ {
321
+ "internalType": "uint32",
322
+ "name": "_eid",
323
+ "type": "uint32"
324
+ }
325
+ ],
326
+ "name": "getSendLibrary",
327
+ "outputs": [
328
+ {
329
+ "internalType": "address",
330
+ "name": "lib",
331
+ "type": "address"
332
+ }
333
+ ],
334
+ "stateMutability": "view",
335
+ "type": "function"
336
+ },
337
+ {
338
+ "inputs": [
339
+ {
340
+ "internalType": "address",
341
+ "name": "_sender",
342
+ "type": "address"
343
+ },
344
+ {
345
+ "internalType": "uint32",
346
+ "name": "_eid",
347
+ "type": "uint32"
348
+ }
349
+ ],
350
+ "name": "isDefaultSendLibrary",
351
+ "outputs": [
352
+ {
353
+ "internalType": "bool",
354
+ "name": "",
355
+ "type": "bool"
356
+ }
357
+ ],
358
+ "stateMutability": "view",
359
+ "type": "function"
360
+ },
361
+ {
362
+ "inputs": [
363
+ {
364
+ "internalType": "address",
365
+ "name": "_lib",
366
+ "type": "address"
367
+ }
368
+ ],
369
+ "name": "isRegisteredLibrary",
370
+ "outputs": [
371
+ {
372
+ "internalType": "bool",
373
+ "name": "",
374
+ "type": "bool"
375
+ }
376
+ ],
377
+ "stateMutability": "view",
378
+ "type": "function"
379
+ },
380
+ {
381
+ "inputs": [
382
+ {
383
+ "internalType": "uint32",
384
+ "name": "_eid",
385
+ "type": "uint32"
386
+ }
387
+ ],
388
+ "name": "isSupportedEid",
389
+ "outputs": [
390
+ {
391
+ "internalType": "bool",
392
+ "name": "",
393
+ "type": "bool"
394
+ }
395
+ ],
396
+ "stateMutability": "view",
397
+ "type": "function"
398
+ },
399
+ {
400
+ "inputs": [
401
+ {
402
+ "internalType": "address",
403
+ "name": "_receiver",
404
+ "type": "address"
405
+ },
406
+ {
407
+ "internalType": "uint32",
408
+ "name": "_eid",
409
+ "type": "uint32"
410
+ }
411
+ ],
412
+ "name": "receiveLibraryTimeout",
413
+ "outputs": [
414
+ {
415
+ "internalType": "address",
416
+ "name": "lib",
417
+ "type": "address"
418
+ },
419
+ {
420
+ "internalType": "uint256",
421
+ "name": "expiry",
422
+ "type": "uint256"
423
+ }
424
+ ],
425
+ "stateMutability": "view",
426
+ "type": "function"
427
+ },
428
+ {
429
+ "inputs": [
430
+ {
431
+ "internalType": "address",
432
+ "name": "_lib",
433
+ "type": "address"
434
+ }
435
+ ],
436
+ "name": "registerLibrary",
437
+ "outputs": [],
438
+ "stateMutability": "nonpayable",
439
+ "type": "function"
440
+ },
441
+ {
442
+ "inputs": [
443
+ {
444
+ "internalType": "address",
445
+ "name": "_oapp",
446
+ "type": "address"
447
+ },
448
+ {
449
+ "internalType": "address",
450
+ "name": "_lib",
451
+ "type": "address"
452
+ },
453
+ {
454
+ "components": [
455
+ {
456
+ "internalType": "uint32",
457
+ "name": "eid",
458
+ "type": "uint32"
459
+ },
460
+ {
461
+ "internalType": "uint32",
462
+ "name": "configType",
463
+ "type": "uint32"
464
+ },
465
+ {
466
+ "internalType": "bytes",
467
+ "name": "config",
468
+ "type": "bytes"
469
+ }
470
+ ],
471
+ "internalType": "struct SetConfigParam[]",
472
+ "name": "_params",
473
+ "type": "tuple[]"
474
+ }
475
+ ],
476
+ "name": "setConfig",
477
+ "outputs": [],
478
+ "stateMutability": "nonpayable",
479
+ "type": "function"
480
+ },
481
+ {
482
+ "inputs": [
483
+ {
484
+ "internalType": "uint32",
485
+ "name": "_eid",
486
+ "type": "uint32"
487
+ },
488
+ {
489
+ "internalType": "address",
490
+ "name": "_newLib",
491
+ "type": "address"
492
+ },
493
+ {
494
+ "internalType": "uint256",
495
+ "name": "_timeout",
496
+ "type": "uint256"
497
+ }
498
+ ],
499
+ "name": "setDefaultReceiveLibrary",
500
+ "outputs": [],
501
+ "stateMutability": "nonpayable",
502
+ "type": "function"
503
+ },
504
+ {
505
+ "inputs": [
506
+ {
507
+ "internalType": "uint32",
508
+ "name": "_eid",
509
+ "type": "uint32"
510
+ },
511
+ {
512
+ "internalType": "address",
513
+ "name": "_lib",
514
+ "type": "address"
515
+ },
516
+ {
517
+ "internalType": "uint256",
518
+ "name": "_expiry",
519
+ "type": "uint256"
520
+ }
521
+ ],
522
+ "name": "setDefaultReceiveLibraryTimeout",
523
+ "outputs": [],
524
+ "stateMutability": "nonpayable",
525
+ "type": "function"
526
+ },
527
+ {
528
+ "inputs": [
529
+ {
530
+ "internalType": "uint32",
531
+ "name": "_eid",
532
+ "type": "uint32"
533
+ },
534
+ {
535
+ "internalType": "address",
536
+ "name": "_newLib",
537
+ "type": "address"
538
+ }
539
+ ],
540
+ "name": "setDefaultSendLibrary",
541
+ "outputs": [],
542
+ "stateMutability": "nonpayable",
543
+ "type": "function"
544
+ },
545
+ {
546
+ "inputs": [
547
+ {
548
+ "internalType": "address",
549
+ "name": "_oapp",
550
+ "type": "address"
551
+ },
552
+ {
553
+ "internalType": "uint32",
554
+ "name": "_eid",
555
+ "type": "uint32"
556
+ },
557
+ {
558
+ "internalType": "address",
559
+ "name": "_newLib",
560
+ "type": "address"
561
+ },
562
+ {
563
+ "internalType": "uint256",
564
+ "name": "_gracePeriod",
565
+ "type": "uint256"
566
+ }
567
+ ],
568
+ "name": "setReceiveLibrary",
569
+ "outputs": [],
570
+ "stateMutability": "nonpayable",
571
+ "type": "function"
572
+ },
573
+ {
574
+ "inputs": [
575
+ {
576
+ "internalType": "address",
577
+ "name": "_oapp",
578
+ "type": "address"
579
+ },
580
+ {
581
+ "internalType": "uint32",
582
+ "name": "_eid",
583
+ "type": "uint32"
584
+ },
585
+ {
586
+ "internalType": "address",
587
+ "name": "_lib",
588
+ "type": "address"
589
+ },
590
+ {
591
+ "internalType": "uint256",
592
+ "name": "_gracePeriod",
593
+ "type": "uint256"
594
+ }
595
+ ],
596
+ "name": "setReceiveLibraryTimeout",
597
+ "outputs": [],
598
+ "stateMutability": "nonpayable",
599
+ "type": "function"
600
+ },
601
+ {
602
+ "inputs": [
603
+ {
604
+ "internalType": "address",
605
+ "name": "_oapp",
606
+ "type": "address"
607
+ },
608
+ {
609
+ "internalType": "uint32",
610
+ "name": "_eid",
611
+ "type": "uint32"
612
+ },
613
+ {
614
+ "internalType": "address",
615
+ "name": "_newLib",
616
+ "type": "address"
617
+ }
618
+ ],
619
+ "name": "setSendLibrary",
620
+ "outputs": [],
621
+ "stateMutability": "nonpayable",
622
+ "type": "function"
623
+ }
624
+ ],
625
+ "bytecode": "0x",
626
+ "deployedBytecode": "0x",
627
+ "linkReferences": {},
628
+ "deployedLinkReferences": {}
629
+ }