Skip to content

Commit e9378fe

Browse files
authored
Update Backwards Compatibility Section
Update backwards compatibility section. Signed-off-by: Keith Kowal <keith.kowal@swirldslabs.com>
1 parent a4303e9 commit e9378fe

1 file changed

Lines changed: 33 additions & 1 deletion

File tree

HIP/hip-1340.md

Lines changed: 33 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -545,8 +545,40 @@ SDKs will also need to support the new field in CryptoCreate / CryptoUpdate tran
545545
- The explorer should show the new/modified authorizations that have been set while processing `EthereumTransaction` (V4), `CryptoUpdate` or `CryptoCreate`.
546546

547547
## Backwards Compatibility
548+
HIP-1340 introduces EOA code delegation by adding an optional delegation_address field to Hedera accounts and enabling delegation configuration through both Ethereum Type 4 transactions, and native HAPI transactions.
549+
The proposal is backward compatible at the protocol, data model, and transaction validity levels. No existing accounts are invalidated, and no previously valid transactions become invalid. However, the proposal expands the execution semantics of EOAs and invalidates certain historical assumptions about EOA behavior.
550+
551+
### Behavioral Assumption Changes
552+
Although backward compatible in terms of transaction validity and account structure, HIP-1340 expands EOA behavior and invalidates certain prior assumptions, including:
553+
- The assumption that EOAs always have empty bytecode.
554+
- The assumption that calls to EOAs never execute code.
555+
- The assumption that msg.sender == tx.origin occurs only in the topmost execution frame.
556+
557+
After delegation is enabled on an account:
558+
- eth_getCode(account) may return non-empty code.
559+
- Calls to an EOA may trigger delegated execution.
560+
- msg.sender == tx.origin may occur in deeper execution frames due to delegation semantics.
561+
562+
These behavioral changes are opt-in and apply only to accounts with a configured delegation_address. Accounts without delegation behave exactly as they did prior to this HIP.
563+
564+
### Delegation Applicability Across Account Types
565+
Delegation is a protocol-level feature and may be applied to all Hedera account types. HIP-1340 does not change any existing account characteristics. Hedera currently supports three account configurations:
566+
- ED25519 accounts
567+
- ECDSA accounts with an Account Alias derived from AccountID (Long-zero alias)
568+
- ECDSA accounts with an Account Alias derived from the public key
569+
The mechanism used to configure delegation depends on the transaction path.
570+
571+
#### Ethereum Transaction Path (Type 4)
572+
Only ECDSA accounts with an Account Alias derived from the public key are capable of submitting Ethereum transactions on Hedera. Consequently:
573+
Only these accounts may configure or update delegation via Ethereum Type 4 transactions (as defined by EIP-7702).
574+
This limitation reflects existing Ethereum transaction compatibility rules and is not introduced by HIP-1340.
575+
ED25519 accounts and ECDSA accounts using AccountID-derived (Long-zero) aliases cannot submit Ethereum transactions and therefore cannot use the Type 4 configuration path.
576+
577+
#### Native HAPI Transaction Path
578+
All account types may configure or update delegation via native HAPI transactions (e.g., CryptoCreate, CryptoUpdate).
579+
Once delegation is configured, execution semantics are uniform across account types.
580+
Native HAPI transaction behavior — including CryptoTransfer signature validation and authorization requirements — remains unchanged by this proposal.
548581

549-
The change itself is backwards compatible, but it significantly modifies the behavior of calls to EOAs and invalidates some previous assumptions, for example that the code of an EOA is always empty or that `msg.sender == tx.origin` only happens in the topmost execution frame.
550582

551583
## Security Implications
552584

0 commit comments

Comments
 (0)