mirror of
https://github.com/status-im/EIPs.git
synced 2025-02-22 11:48:19 +00:00
2976: Adds Receipts (#3254)
This commit is contained in:
parent
ab52366caf
commit
3ec9510e81
@ -3,7 +3,7 @@ eip: 2976
|
||||
title: 'Typed Transactions over Gossip'
|
||||
author: Micah Zoltu (@MicahZoltu)
|
||||
discussions-to: https://ethereum-magicians.org/t/eip-2976-eth-typed-transactions-over-gossip/4610
|
||||
status: Draft
|
||||
status: Review
|
||||
type: Standards Track
|
||||
category: Networking
|
||||
created: 2020-09-13
|
||||
@ -41,6 +41,11 @@ All changes specified below apply to all protocol/versions retroactively.
|
||||
* `LegacyTransaction` is an array of the form `[nonce, gasPrice, gasLimit, to, value, data, v, r, s]`
|
||||
* `LegacyTransactionHash` is `keccak256(rlp(LegacyTransaction))`
|
||||
* `TransactionId` is `keccak256(TypedTransactionHash | LegacyTransactionHash)`
|
||||
* `Receipt` is either `TypedReceipt` or `LegacyReceipt`
|
||||
* `TypedReceipt` is a byte array containing `TransactionType || ReceiptPayload`
|
||||
* `ReceiptPayload` is an opaque byte array whose interpretation is dependent on the `TransactionType` and defined in future EIPs
|
||||
* `LegacyReceipt` is an array of the form `[status, cumulativeGasUsed, logsBloom, logs]`
|
||||
* `LegacyReceiptHash` is `keccak256(rlp(LegacyReceipt))`
|
||||
|
||||
### Protocol Behavior
|
||||
If a client receives a `TransactionType` it doesn't recognize via any message, it **SHOULD** disconnect the peer that sent it.
|
||||
@ -71,6 +76,9 @@ Clients **MAY** disconnect peers who send transactions of a new `TransactionType
|
||||
|
||||
`PooledTransactions (0x0a)`: `[Transaction_0, Transaction_1, ..., Transaction_n]`
|
||||
|
||||
`Receipts (0x10)`: `[ReceiptList_0, ReceiptList_1, ..., ReceiptList_n]` where:
|
||||
* `ReceiptList` is `[Receipt_0, Receipt_1, ..., Receipt_n]`
|
||||
|
||||
## Rationale
|
||||
### Why not specify each transaction type at the protocol layer?
|
||||
We could have chosen to make the protocol aware of the shape of the transaction payloads.
|
||||
@ -83,12 +91,6 @@ Also, in most cases we expect that by the time new transaction types are being s
|
||||
## Backwards Compatibility
|
||||
Legacy transactions are still supported.
|
||||
|
||||
## Test Cases
|
||||
TBD
|
||||
|
||||
## Implementation
|
||||
TBD
|
||||
|
||||
## Security Considerations
|
||||
If a client chooses to ignore the **SHOULD** recommendation for disconnecting peers that send unknown transaction types they may be susceptible to DoS attacks.
|
||||
Ignoring this recommendation should be limited to trusted peers only, or other situations where the risk of DoS is extremely low.
|
||||
|
Loading…
x
Reference in New Issue
Block a user