eth 0.5.8 → 0.5.10
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/.github/workflows/spec.yml +2 -1
- data/CHANGELOG.md +32 -0
- data/CODE_OF_CONDUCT.md +122 -0
- data/CONTRIBUTING.md +61 -0
- data/LICENSE.txt +1 -1
- data/README.md +6 -2
- data/SECURITY.md +24 -0
- data/abi/ens_registry.json +436 -0
- data/abi/ens_resolver.json +885 -0
- data/lib/eth/abi/event.rb +1 -1
- data/lib/eth/abi/type.rb +46 -12
- data/lib/eth/abi.rb +72 -14
- data/lib/eth/address.rb +2 -2
- data/lib/eth/api.rb +1 -1
- data/lib/eth/chain.rb +19 -7
- data/lib/eth/client/http.rb +1 -1
- data/lib/eth/client/http_auth.rb +1 -1
- data/lib/eth/client/ipc.rb +1 -1
- data/lib/eth/client.rb +118 -16
- data/lib/eth/constant.rb +1 -1
- data/lib/eth/contract/event.rb +1 -1
- data/lib/eth/contract/function.rb +2 -2
- data/lib/eth/contract/function_input.rb +7 -2
- data/lib/eth/contract/function_output.rb +1 -1
- data/lib/eth/contract/initializer.rb +1 -1
- data/lib/eth/contract.rb +1 -1
- data/lib/eth/eip712.rb +2 -2
- data/lib/eth/ens/coin_type.rb +50 -0
- data/lib/eth/ens/resolver.rb +68 -24
- data/lib/eth/ens.rb +28 -0
- data/lib/eth/key/decrypter.rb +1 -1
- data/lib/eth/key/encrypter.rb +1 -1
- data/lib/eth/key.rb +5 -5
- data/lib/eth/rlp/decoder.rb +2 -2
- data/lib/eth/rlp/encoder.rb +3 -3
- data/lib/eth/rlp/sedes/big_endian_int.rb +1 -1
- data/lib/eth/rlp/sedes/binary.rb +2 -2
- data/lib/eth/rlp/sedes/list.rb +5 -5
- data/lib/eth/rlp/sedes.rb +4 -4
- data/lib/eth/rlp.rb +1 -1
- data/lib/eth/signature.rb +4 -4
- data/lib/eth/solidity.rb +5 -3
- data/lib/eth/tx/eip1559.rb +3 -3
- data/lib/eth/tx/eip2930.rb +3 -3
- data/lib/eth/tx/legacy.rb +3 -3
- data/lib/eth/tx.rb +5 -5
- data/lib/eth/unit.rb +1 -1
- data/lib/eth/util.rb +14 -14
- data/lib/eth/version.rb +2 -2
- data/lib/eth.rb +2 -2
- metadata +9 -3
- data/abis/ens.json +0 -422
@@ -0,0 +1,436 @@
|
|
1
|
+
[
|
2
|
+
{
|
3
|
+
"inputs":[
|
4
|
+
{
|
5
|
+
"internalType":"contract ENS",
|
6
|
+
"name":"_old",
|
7
|
+
"type":"address"
|
8
|
+
}
|
9
|
+
],
|
10
|
+
"payable":false,
|
11
|
+
"stateMutability":"nonpayable",
|
12
|
+
"type":"constructor"
|
13
|
+
},
|
14
|
+
{
|
15
|
+
"anonymous":false,
|
16
|
+
"inputs":[
|
17
|
+
{
|
18
|
+
"indexed":true,
|
19
|
+
"internalType":"address",
|
20
|
+
"name":"owner",
|
21
|
+
"type":"address"
|
22
|
+
},
|
23
|
+
{
|
24
|
+
"indexed":true,
|
25
|
+
"internalType":"address",
|
26
|
+
"name":"operator",
|
27
|
+
"type":"address"
|
28
|
+
},
|
29
|
+
{
|
30
|
+
"indexed":false,
|
31
|
+
"internalType":"bool",
|
32
|
+
"name":"approved",
|
33
|
+
"type":"bool"
|
34
|
+
}
|
35
|
+
],
|
36
|
+
"name":"ApprovalForAll",
|
37
|
+
"type":"event"
|
38
|
+
},
|
39
|
+
{
|
40
|
+
"anonymous":false,
|
41
|
+
"inputs":[
|
42
|
+
{
|
43
|
+
"indexed":true,
|
44
|
+
"internalType":"bytes32",
|
45
|
+
"name":"node",
|
46
|
+
"type":"bytes32"
|
47
|
+
},
|
48
|
+
{
|
49
|
+
"indexed":true,
|
50
|
+
"internalType":"bytes32",
|
51
|
+
"name":"label",
|
52
|
+
"type":"bytes32"
|
53
|
+
},
|
54
|
+
{
|
55
|
+
"indexed":false,
|
56
|
+
"internalType":"address",
|
57
|
+
"name":"owner",
|
58
|
+
"type":"address"
|
59
|
+
}
|
60
|
+
],
|
61
|
+
"name":"NewOwner",
|
62
|
+
"type":"event"
|
63
|
+
},
|
64
|
+
{
|
65
|
+
"anonymous":false,
|
66
|
+
"inputs":[
|
67
|
+
{
|
68
|
+
"indexed":true,
|
69
|
+
"internalType":"bytes32",
|
70
|
+
"name":"node",
|
71
|
+
"type":"bytes32"
|
72
|
+
},
|
73
|
+
{
|
74
|
+
"indexed":false,
|
75
|
+
"internalType":"address",
|
76
|
+
"name":"resolver",
|
77
|
+
"type":"address"
|
78
|
+
}
|
79
|
+
],
|
80
|
+
"name":"NewResolver",
|
81
|
+
"type":"event"
|
82
|
+
},
|
83
|
+
{
|
84
|
+
"anonymous":false,
|
85
|
+
"inputs":[
|
86
|
+
{
|
87
|
+
"indexed":true,
|
88
|
+
"internalType":"bytes32",
|
89
|
+
"name":"node",
|
90
|
+
"type":"bytes32"
|
91
|
+
},
|
92
|
+
{
|
93
|
+
"indexed":false,
|
94
|
+
"internalType":"uint64",
|
95
|
+
"name":"ttl",
|
96
|
+
"type":"uint64"
|
97
|
+
}
|
98
|
+
],
|
99
|
+
"name":"NewTTL",
|
100
|
+
"type":"event"
|
101
|
+
},
|
102
|
+
{
|
103
|
+
"anonymous":false,
|
104
|
+
"inputs":[
|
105
|
+
{
|
106
|
+
"indexed":true,
|
107
|
+
"internalType":"bytes32",
|
108
|
+
"name":"node",
|
109
|
+
"type":"bytes32"
|
110
|
+
},
|
111
|
+
{
|
112
|
+
"indexed":false,
|
113
|
+
"internalType":"address",
|
114
|
+
"name":"owner",
|
115
|
+
"type":"address"
|
116
|
+
}
|
117
|
+
],
|
118
|
+
"name":"Transfer",
|
119
|
+
"type":"event"
|
120
|
+
},
|
121
|
+
{
|
122
|
+
"constant":true,
|
123
|
+
"inputs":[
|
124
|
+
{
|
125
|
+
"internalType":"address",
|
126
|
+
"name":"owner",
|
127
|
+
"type":"address"
|
128
|
+
},
|
129
|
+
{
|
130
|
+
"internalType":"address",
|
131
|
+
"name":"operator",
|
132
|
+
"type":"address"
|
133
|
+
}
|
134
|
+
],
|
135
|
+
"name":"isApprovedForAll",
|
136
|
+
"outputs":[
|
137
|
+
{
|
138
|
+
"internalType":"bool",
|
139
|
+
"name":"",
|
140
|
+
"type":"bool"
|
141
|
+
}
|
142
|
+
],
|
143
|
+
"payable":false,
|
144
|
+
"stateMutability":"view",
|
145
|
+
"type":"function"
|
146
|
+
},
|
147
|
+
{
|
148
|
+
"constant":true,
|
149
|
+
"inputs":[
|
150
|
+
|
151
|
+
],
|
152
|
+
"name":"old",
|
153
|
+
"outputs":[
|
154
|
+
{
|
155
|
+
"internalType":"contract ENS",
|
156
|
+
"name":"",
|
157
|
+
"type":"address"
|
158
|
+
}
|
159
|
+
],
|
160
|
+
"payable":false,
|
161
|
+
"stateMutability":"view",
|
162
|
+
"type":"function"
|
163
|
+
},
|
164
|
+
{
|
165
|
+
"constant":true,
|
166
|
+
"inputs":[
|
167
|
+
{
|
168
|
+
"internalType":"bytes32",
|
169
|
+
"name":"node",
|
170
|
+
"type":"bytes32"
|
171
|
+
}
|
172
|
+
],
|
173
|
+
"name":"owner",
|
174
|
+
"outputs":[
|
175
|
+
{
|
176
|
+
"internalType":"address",
|
177
|
+
"name":"",
|
178
|
+
"type":"address"
|
179
|
+
}
|
180
|
+
],
|
181
|
+
"payable":false,
|
182
|
+
"stateMutability":"view",
|
183
|
+
"type":"function"
|
184
|
+
},
|
185
|
+
{
|
186
|
+
"constant":true,
|
187
|
+
"inputs":[
|
188
|
+
{
|
189
|
+
"internalType":"bytes32",
|
190
|
+
"name":"node",
|
191
|
+
"type":"bytes32"
|
192
|
+
}
|
193
|
+
],
|
194
|
+
"name":"recordExists",
|
195
|
+
"outputs":[
|
196
|
+
{
|
197
|
+
"internalType":"bool",
|
198
|
+
"name":"",
|
199
|
+
"type":"bool"
|
200
|
+
}
|
201
|
+
],
|
202
|
+
"payable":false,
|
203
|
+
"stateMutability":"view",
|
204
|
+
"type":"function"
|
205
|
+
},
|
206
|
+
{
|
207
|
+
"constant":true,
|
208
|
+
"inputs":[
|
209
|
+
{
|
210
|
+
"internalType":"bytes32",
|
211
|
+
"name":"node",
|
212
|
+
"type":"bytes32"
|
213
|
+
}
|
214
|
+
],
|
215
|
+
"name":"resolver",
|
216
|
+
"outputs":[
|
217
|
+
{
|
218
|
+
"internalType":"address",
|
219
|
+
"name":"",
|
220
|
+
"type":"address"
|
221
|
+
}
|
222
|
+
],
|
223
|
+
"payable":false,
|
224
|
+
"stateMutability":"view",
|
225
|
+
"type":"function"
|
226
|
+
},
|
227
|
+
{
|
228
|
+
"constant":false,
|
229
|
+
"inputs":[
|
230
|
+
{
|
231
|
+
"internalType":"address",
|
232
|
+
"name":"operator",
|
233
|
+
"type":"address"
|
234
|
+
},
|
235
|
+
{
|
236
|
+
"internalType":"bool",
|
237
|
+
"name":"approved",
|
238
|
+
"type":"bool"
|
239
|
+
}
|
240
|
+
],
|
241
|
+
"name":"setApprovalForAll",
|
242
|
+
"outputs":[
|
243
|
+
|
244
|
+
],
|
245
|
+
"payable":false,
|
246
|
+
"stateMutability":"nonpayable",
|
247
|
+
"type":"function"
|
248
|
+
},
|
249
|
+
{
|
250
|
+
"constant":false,
|
251
|
+
"inputs":[
|
252
|
+
{
|
253
|
+
"internalType":"bytes32",
|
254
|
+
"name":"node",
|
255
|
+
"type":"bytes32"
|
256
|
+
},
|
257
|
+
{
|
258
|
+
"internalType":"address",
|
259
|
+
"name":"owner",
|
260
|
+
"type":"address"
|
261
|
+
}
|
262
|
+
],
|
263
|
+
"name":"setOwner",
|
264
|
+
"outputs":[
|
265
|
+
|
266
|
+
],
|
267
|
+
"payable":false,
|
268
|
+
"stateMutability":"nonpayable",
|
269
|
+
"type":"function"
|
270
|
+
},
|
271
|
+
{
|
272
|
+
"constant":false,
|
273
|
+
"inputs":[
|
274
|
+
{
|
275
|
+
"internalType":"bytes32",
|
276
|
+
"name":"node",
|
277
|
+
"type":"bytes32"
|
278
|
+
},
|
279
|
+
{
|
280
|
+
"internalType":"address",
|
281
|
+
"name":"owner",
|
282
|
+
"type":"address"
|
283
|
+
},
|
284
|
+
{
|
285
|
+
"internalType":"address",
|
286
|
+
"name":"resolver",
|
287
|
+
"type":"address"
|
288
|
+
},
|
289
|
+
{
|
290
|
+
"internalType":"uint64",
|
291
|
+
"name":"ttl",
|
292
|
+
"type":"uint64"
|
293
|
+
}
|
294
|
+
],
|
295
|
+
"name":"setRecord",
|
296
|
+
"outputs":[
|
297
|
+
|
298
|
+
],
|
299
|
+
"payable":false,
|
300
|
+
"stateMutability":"nonpayable",
|
301
|
+
"type":"function"
|
302
|
+
},
|
303
|
+
{
|
304
|
+
"constant":false,
|
305
|
+
"inputs":[
|
306
|
+
{
|
307
|
+
"internalType":"bytes32",
|
308
|
+
"name":"node",
|
309
|
+
"type":"bytes32"
|
310
|
+
},
|
311
|
+
{
|
312
|
+
"internalType":"address",
|
313
|
+
"name":"resolver",
|
314
|
+
"type":"address"
|
315
|
+
}
|
316
|
+
],
|
317
|
+
"name":"setResolver",
|
318
|
+
"outputs":[
|
319
|
+
|
320
|
+
],
|
321
|
+
"payable":false,
|
322
|
+
"stateMutability":"nonpayable",
|
323
|
+
"type":"function"
|
324
|
+
},
|
325
|
+
{
|
326
|
+
"constant":false,
|
327
|
+
"inputs":[
|
328
|
+
{
|
329
|
+
"internalType":"bytes32",
|
330
|
+
"name":"node",
|
331
|
+
"type":"bytes32"
|
332
|
+
},
|
333
|
+
{
|
334
|
+
"internalType":"bytes32",
|
335
|
+
"name":"label",
|
336
|
+
"type":"bytes32"
|
337
|
+
},
|
338
|
+
{
|
339
|
+
"internalType":"address",
|
340
|
+
"name":"owner",
|
341
|
+
"type":"address"
|
342
|
+
}
|
343
|
+
],
|
344
|
+
"name":"setSubnodeOwner",
|
345
|
+
"outputs":[
|
346
|
+
{
|
347
|
+
"internalType":"bytes32",
|
348
|
+
"name":"",
|
349
|
+
"type":"bytes32"
|
350
|
+
}
|
351
|
+
],
|
352
|
+
"payable":false,
|
353
|
+
"stateMutability":"nonpayable",
|
354
|
+
"type":"function"
|
355
|
+
},
|
356
|
+
{
|
357
|
+
"constant":false,
|
358
|
+
"inputs":[
|
359
|
+
{
|
360
|
+
"internalType":"bytes32",
|
361
|
+
"name":"node",
|
362
|
+
"type":"bytes32"
|
363
|
+
},
|
364
|
+
{
|
365
|
+
"internalType":"bytes32",
|
366
|
+
"name":"label",
|
367
|
+
"type":"bytes32"
|
368
|
+
},
|
369
|
+
{
|
370
|
+
"internalType":"address",
|
371
|
+
"name":"owner",
|
372
|
+
"type":"address"
|
373
|
+
},
|
374
|
+
{
|
375
|
+
"internalType":"address",
|
376
|
+
"name":"resolver",
|
377
|
+
"type":"address"
|
378
|
+
},
|
379
|
+
{
|
380
|
+
"internalType":"uint64",
|
381
|
+
"name":"ttl",
|
382
|
+
"type":"uint64"
|
383
|
+
}
|
384
|
+
],
|
385
|
+
"name":"setSubnodeRecord",
|
386
|
+
"outputs":[
|
387
|
+
|
388
|
+
],
|
389
|
+
"payable":false,
|
390
|
+
"stateMutability":"nonpayable",
|
391
|
+
"type":"function"
|
392
|
+
},
|
393
|
+
{
|
394
|
+
"constant":false,
|
395
|
+
"inputs":[
|
396
|
+
{
|
397
|
+
"internalType":"bytes32",
|
398
|
+
"name":"node",
|
399
|
+
"type":"bytes32"
|
400
|
+
},
|
401
|
+
{
|
402
|
+
"internalType":"uint64",
|
403
|
+
"name":"ttl",
|
404
|
+
"type":"uint64"
|
405
|
+
}
|
406
|
+
],
|
407
|
+
"name":"setTTL",
|
408
|
+
"outputs":[
|
409
|
+
|
410
|
+
],
|
411
|
+
"payable":false,
|
412
|
+
"stateMutability":"nonpayable",
|
413
|
+
"type":"function"
|
414
|
+
},
|
415
|
+
{
|
416
|
+
"constant":true,
|
417
|
+
"inputs":[
|
418
|
+
{
|
419
|
+
"internalType":"bytes32",
|
420
|
+
"name":"node",
|
421
|
+
"type":"bytes32"
|
422
|
+
}
|
423
|
+
],
|
424
|
+
"name":"ttl",
|
425
|
+
"outputs":[
|
426
|
+
{
|
427
|
+
"internalType":"uint64",
|
428
|
+
"name":"",
|
429
|
+
"type":"uint64"
|
430
|
+
}
|
431
|
+
],
|
432
|
+
"payable":false,
|
433
|
+
"stateMutability":"view",
|
434
|
+
"type":"function"
|
435
|
+
}
|
436
|
+
]
|