Questions tagged [block-header]
The block-header tag has no usage guidance.
44 questions
0
votes
0
answers
17
views
Clique doesn't show address of validator
I want to use Clique consensus
By default it writes Coinbase.address as 0x0000...
I want to write always address of validator of a block
I have tried to add code to function "Finalize"
But ...
2
votes
1
answer
194
views
How are Ethereum 2 block hashes computed?
After the merge, the block hash computation has a different formula. Before that, the following data were used to compute the hash via feeding the list of hex values to an RLP encoder and hashing the ...
1
vote
0
answers
71
views
After the Merge with proof-of-stake, how a lightclient verify the block header?
In my understanding, date back to proof-of-work, the block header is self-verifiable because of the difficulty, nonce and block hash value. But after the Merge, the block is attested by several ...
0
votes
1
answer
645
views
Sync failed from archive nodes even after reset blockchain on private network
I am currently suffering from sync fail issue while running my own private network.
Over 20 nodes were fully connected each other and running consensus (or mining) as archive mode, with full sync mode ...
1
vote
0
answers
22
views
Ethereum yellow paper is-sibling property
I'm reading the yellow paper and having some problems understanding equation 169 from here - also below:
s(U,H) = (P(H) = P(U) ∧ H != U ∧ U !∈ B(H)_U)
I can understand the first two conditions:
The ...
0
votes
1
answer
276
views
How to determine if the hash is finalized?
For some reason, I am require to store the hash to database. I would like to know is there any criteria to determine that the hash is finalize?
For example,
Block #15000000 have hash value of
...
0
votes
1
answer
501
views
How Uncles (Ommers) Hash include in headers?
I'm confused with the definition of uncle block. I read every articles and they say basically uncle block is a block that valid but lose the race to main blockchain. All the blocks' hashes that lose ...
1
vote
1
answer
1k
views
The current provider doesn't support subscriptions: HDWalletProvider on Polygon (matic) blockchain
I use wss://rpc-mainnet.maticvigil.com/v1/MY-APP-ID as my polygon dApp provider, however I cannot subscribe on newBlockHeaders event with the following error:
Error: The current provider doesn't ...
1
vote
0
answers
277
views
What is the theoretical average latency of data transmission?
I concluded a pretty simple test to measure some latencies. I connected to two providers (Infura and Quiknode) with Web3.js and subscribed to new block headers. Then I compared the time of arrival and ...
0
votes
0
answers
16
views
Function L_H in YellowPaper
What's the difference between a Block header H and the header after it has been passed to function L_H?
L_H is defined in Section 4.4.3 Equation 32 and is used in Section 4.4.2 Equation 29(2nd)
Yellow ...
1
vote
1
answer
138
views
Get number of logs in block
Given logs are streamed to a client via the eth_subscribe(“logs”) rpc method with a logIndex, is there a way to tell the number of total logs in a block from its header?
1
vote
1
answer
419
views
Compute transactions trie root hash from a BlockBodies message using ethereumjs
Given a decoded BlockBodies message, I want to compute the root hash of the transactions trie, so that I can match it against block headers that my node has downloaded.
After reviewing How Ethereum ...
0
votes
1
answer
268
views
Is Ethereum block header a list?
Decoding a RLP encoded block using Eth specifications do we get header as list? But as per format i.e., [[blockHeader,transactionList,uncleList],totalDifficulty], blockHeader should have been string.
...
1
vote
1
answer
139
views
Fetching block template from node
The most famous opensource pool uses eth_getBlockByNumber method with parameter "pending" to get block template and generate jobs from it. But now, in parity, I found that this parameter is deprecated ...
4
votes
1
answer
361
views
Verify a block exists
I want to verify that a block exists in a trust-less manner - i.e. with on chain validation. This rules out the option of using an oracle.
I'm aware of this function: blockhash(uint blockNumber) ...
0
votes
1
answer
4k
views
Block header hash calculation [duplicate]
What inputs go into the RLP and Keccak function to calculate the block header hash?
I looked up the header struct. Which of those values are fed into the RLP, Keccak? Were nonce and mixed hash left ...
2
votes
1
answer
2k
views
block hash from block-header rlp [duplicate]
Given the RLP of a block header, how do i get the block hash?
https://github.com/ethereum/go-ethereum/blob/master/core/types/block.go#L99
The above link says: Hash returns the block hash of the ...
9
votes
3
answers
3k
views
block-header hash verification
As part of a validation service I am working on, I need to be able to verify that the blockHeader hash was created correctly. Based on my understanding following are the steps to regenerate the header ...
0
votes
2
answers
442
views
can only change header's extra data to mine a new block? [closed]
Fix 'nonce' and 'mixDigest', only change 'extra' to mine a new block.
0
votes
1
answer
48
views
Strange Ropsten Bug - transactionsRoot and recieptsRoot has same value
I'm testing some stuff on Ropsten network and I've found strange block:
4138624
When I run (using web3 injected in Metamask):
web3.eth.getBlock(4138624,function(err,res){
console.log(res);
})
I'm ...
1
vote
1
answer
53
views
Why is LH repeated in equation 35 of the yellow paper?
Excerpt from page 5 of the yellow paper, version e94ebda:
I understand that LX is the preparation function for serialising X, as follows:
LB for blocks
LH for block headers
LU for ommer block ...
0
votes
0
answers
294
views
how to check if a block has a transaction to an address only by using the block header
Question is self explanatory. How can I check if a block has a transaction to or from an address only by using the block header?
Question is prompted by this comment - How to explore all ...
1
vote
1
answer
145
views
Addresses in paths of State Patricia Trie
Every block header has 3 patricia trees. In State Patricia Trie, the paths are the sha3 of the ethereum addresses, and the value for any particular address is encoded with RLP.
But, what addresses ...
1
vote
1
answer
143
views
What would an Etheruem-like blockchain look like if each block were just an IPFS hash?
I see a lot of people tout the enormous benefits of using IPFS as a store of data. Meanwhile, the Ethereum blockchain is over 1TB in size, with quesitonable need to keep the earlier blocks.
In ...
3
votes
2
answers
1k
views
Is a block number unique or does it change if the block becomes uncle? Does the transaction hash include a block hash as input?
Is a block number unique or do I need to save block hash to identify a block?
Does transaction hash include a block hash as input?
4
votes
2
answers
644
views
How Geth and Parity resolve timestamps when validating block headers?
Geth and Parity nodes differ in a fundamental way when they validate block headers.
Background
According to the yellow paper
4.3 timestamp: A scalar value equal to the reasonable output of Unix's ...
1
vote
0
answers
260
views
Ethereum Node Connection Error
I'm having trouble getting into my Mist wallet as of a few days ago.
Error starting protocol stack: missing block number for head header hash.Having trouble with Ethereum's mist wallet. I have the ...
4
votes
2
answers
2k
views
Block header format
Does anyone understand what each element of a block header represents? I have an example block header represented here:
[
cd7bd64fba4cc782fe5474d3640882afece5887180591e72f80ce6916cf73526,
...
4
votes
2
answers
817
views
How is the nonce in a the block header arrived at?
My understanding is that the nonce in the header of an Ethereum block is an integer within a certain range (greater than 0).
However, when I look at the blocks through an online block explorer, such ...
1
vote
0
answers
187
views
Rolled back headers dropping the peer right after. geth 1.6.0 [duplicate]
As you can see in this picture I get the same problem over and over again. Headers aren't downloading, they always roll back to header # 1379306.
Does any body know what would be the problem here?
2
votes
1
answer
471
views
Can contracts access the block header extraData field?
The yellow paper (see section 4.4) defines an extraData header field as follows:
An arbitrary byte array containing
data relevant to this block. This must be 32 bytes
or fewer
Can contracts ...
2
votes
1
answer
108
views
How large are header scalar values?
The Yellow paper talks about "scalar values" in section 4.4 to describe block header fields. E.g.
difficulty: A scalar value corresponding to the dif-
ficulty level of this block. This can be ...
6
votes
1
answer
3k
views
How large are the Ethereum block headers?
I am interested in knowing the block header size to estimate the overhead of running an Ethereum light client.
56
votes
3
answers
38k
views
What is an Event?
What is an Event?
Are they only used in Solidity?
How are events defined?
How are events initiated?
Is there a standard term for an event's invocation (do you say an event "happened", "was called",...
1
vote
1
answer
876
views
How are the blocks traversed?
How are the blocks traversed? Is it using a linked list concept to traverse?
If I need to see all block details, will it traverse from the genesis block to the requested block or will it traverse ...
13
votes
3
answers
2k
views
Block header structure change under the Merge to Proof of Stake?
The yellow paper describes the below block header structure:
This includes difficulty, beneficiary, mixHash and nonce values. Presumably these will be redundant under Proof-of-Stake. How will the ...
4
votes
0
answers
866
views
geth throwing header invalid error all the time
lately my ethereum node is repeatedly throwing this error:
E0811 16:44:00.646126 core/blockchain.go:1128] uncle[0](30508438) header invalid: nonce for #2004585 [...
5
votes
2
answers
948
views
What is the beneficiary in block header?
There is the data called "beneficiary" in block header. What is this data?
4
votes
1
answer
815
views
Is block's timestamp current block's or previous block's timestamp?
When I call function giveTime, is the time stamp "now" from the block where my call is mined or from the previous block?
contract Time {
uint time;
function giveTime() {
time=now;
}
...
15
votes
1
answer
34k
views
What is a block hash?
When we look at this block - what does the first number
Hash: 0xfe88c94d860f01a17f961bf4bdfb6e0c6cd10d3fda5cc861e805ca1240c58553
actually mean? How is it calculated?
"Nonce" is the value that is ...
31
votes
2
answers
7k
views
Why are there no leading zeroes in ethereum block hash?
The block hash has to be below certain difficulty, right? In bitcoin this means, that there are many leading zeroes in hash value, eg. for bitcoin block #402329 hash is ...
1
vote
2
answers
868
views
What's the header hash displayed in the miner?
Is the "hash" value reported by geth: eth.getBlock("849245").hash, for example, the same "hash" that is given to the miner in the work package?
Sorry if this is a naive query. The reason for the ...
40
votes
3
answers
12k
views
Can a contract safely rely on block.timestamp?
How safe is it to use block.timestamp as contract expiration time? If a miner provides an incorrect timestamp in a block header, how much can it be off before it is rejected by other nodes? Is there a ...
115
votes
8
answers
97k
views
Ethereum block architecture
Where can I find a description (preferably a diagram like below) showing the block structure in an Ethereum blockchain?
Credits: Wikipedia