You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
For EVM compatibility, Hedera Smart Contract Service will assemble the correct Delegation Indicator (i.e. prefix the `delegation_address` with `0xef0100`) for any bytecode queries of an EOA.
91
+
For EVM compatibility, Hiero Smart Contract Service will assemble the correct Delegation Indicator (i.e. prefix the `delegation_address` with `0xef0100`) for any bytecode queries of an EOA.
91
92
92
93
For external observers, for example those using ContractGetBytecode queries, the code of an EOA will no longer be fixed to the account facade proxy code (the impact on the facade proxy mechanism has been described in more detail below). It will be either empty (no delegation) or an EVM-compatible Delegation Indicator.
93
94
@@ -117,7 +118,7 @@ message AccountInfo {
117
118
118
119
#### Updating Code Delegation of an EOA
119
120
120
-
We propose to enable two ways of setting/updating the Code Delegation. One using Hedera-specific API, and another one using a new EVM transaction type following the specification of EIP-7702.
121
+
We propose to enable two ways of setting/updating the Code Delegation. One using Hiero-specific API, and another one using a new EVM transaction type following the specification of EIP-7702.
121
122
122
123
##### Updating Code Delegation Via CryptoCreate or CryptoUpdate Transaction
123
124
@@ -229,7 +230,7 @@ The following checks will be applied before executing the EVM code of the target
229
230
- targetting a system account address results in a no-op code execution
230
231
- targetting an existing EOA with empty code results in a no-op code execution
231
232
- targetting an existing EOA, which itself contains code delegation results in literal execution of the delegation indicator (which will fail since `0xef` is a banned op code)
232
-
- targetting an existing contract with non-empty code results in the execution of its EVM code, with the exception of calls matching one of Hedera Account Service proxy methods (described in detail below)
233
+
- targetting an existing contract with non-empty code results in the execution of its EVM code, with the exception of calls matching one of Hiero Account Service proxy methods (described in detail below)
233
234
234
235
In case Code Delegation points to another delegation, creating a potential chain or loop of delegations, only the first one will be resolved and the code of the target address will be interpreted literally, even if it's a Delegation Indicator.
235
236
@@ -240,7 +241,7 @@ native `ContractCallTransaction` and native `ContractCreateTransaction`.
240
241
241
242
### Example User Flows
242
243
243
-
Below we present two complete example user flow diagrams: one utilizing an EVM type 4 transaction (e.g. when the user uses standard Ethereum-compatible tools) and another one demonstrating the Code Delegation feature using solely Hedera-native operations.
244
+
Below we present two complete example user flow diagrams: one utilizing an EVM type 4 transaction (e.g. when the user uses standard Ethereum-compatible tools) and another one demonstrating the Code Delegation feature using solely Hiero-native operations.
244
245
245
246
Ethereum-compatible example utilizing an EVM type 4 transaction:
246
247
@@ -272,7 +273,7 @@ Execution Logic Changes:
272
273
273
274
### Impact on Proxy/Facade Calls
274
275
275
-
HIP-218, followed by HIP-719 (later extended by HIP-755 and HIP-906) introduced the concept of proxy/facade calls, where a call can be made directly to an EVM address of a Hedera-native entity (e.g. an HTS token or an account).
276
+
HIP-218, followed by HIP-719 (later extended by HIP-755 and HIP-906) introduced the concept of proxy/facade calls, where a call can be made directly to an EVM address of a Hiero-native entity (e.g. an HTS token or an account).
276
277
The implementation of this facility currently relies on an intermediate, hardcoded and dynamic piece of EVM code that is being run when such a call is made.
277
278
While functional, this has two main downsides:
278
279
@@ -332,7 +333,7 @@ Hooks have a dedicated storage namespace, so the fact that Code Delegation might
332
333
333
334
Mirror Node will be impacted in the following ways:
334
335
335
-
-`CryptoCreate` / `CryptoUpdate` transaction body will be updated
336
+
-`CryptoCreate` / `CryptoUpdate` transaction body parsing in the imported will be updated
336
337
- A new field will be added to the `Account` entity
337
338
- EOA storage slots will be mutable
338
339
- The code (as returned by ContractGetBytecode) of HTS tokens and HSS schedule addresses will be updated to a Delegation Indicator targetting a corresponding System Contract address
@@ -561,16 +562,16 @@ to
561
562
562
563
The security is in the hands of the user - EOA owner - as they are the ones deciding which contract code they wish to delegate the execution to. If any System Contract is called within the delegated contract code, it will have full EOA rights, as it is executed in the context of EOA. This complies to the V2 security model, as it's only the user who can set up the delegation in the first place.
563
564
564
-
In summary, there are no new threats or risks for Hedera, aside the inherent risks of the EIP-7702 Code Delegation adoption within the Ethereum Ecosystem.
565
+
In summary, there are no new threats or risks for Hiero networks, aside the inherent risks of the EIP-7702 Code Delegation adoption within the Ethereum Ecosystem.
565
566
There is a considerable amount of educational materials (articles, blog posts) in the Ethereum community that explain the inherent risks of EIP-7702 and establish best practices for using this feature.
566
567
567
568
Code Delegation directly to System Contracts will be forbidden for regular EOA accounts (no-op, as described in the appropriate section above) and will only be permited for the following native entities: Token Proxy Account, Schedule Proxy Account to facilitate the proxy/facade mechanism described earlier.
568
569
569
570
## How to Teach This
570
571
571
-
Hedera will support EIP-7702-like EOA Code Delegation, with the following modifications:
572
-
-Hedera's account creation cost will be charged when setting Code Delegation for new accounts
573
-
- Users can use either Ethereum-compatible tools or Hedera native transactions to modify their Code Delegations
572
+
Hiero will support EIP-7702-like EOA Code Delegation, with the following modifications:
573
+
-Hiero's account creation cost will be charged when setting Code Delegation for new accounts
574
+
- Users can use either Ethereum-compatible tools or Hiero native transactions to modify their Code Delegations
574
575
- Delegations to functions matching the signatures of HAS will not work (HAS calls have precedence)
575
576
- HTS/HSS proxy/facade calls remain unchanged from user’s perspective
0 commit comments