Hey everyone, does anyone know if there's a tool or script to find the nonce values of old blocks or transactions? I mean, we know the nonce for mined blocks, but can we get that info for historical data?
How to find nonce values in old blocks or transactions?
11 replies 304 views
Check this out. LoyceV put together a list of nonces from the blocks right here: https://loyce.club/blockdata/nonce.txt.
But I’m not sure about finding the extra nonce, that one's in the Coinbase transaction.
Thanks for the link! There’s always someone here with the right info. So this is historical block data, right? Any chance we can find the nonce for individual transactions?
So, the extraNonce isn't part of the block or header format. Theymos mentioned there's no nonce for single transactions because it’s only for block generation. Adding that to transactions would just bloat them.
The transaction nonce is actually used to make the signature for the transaction. It's secret since it involves the private key to sign things.
Is any of the info you need in these files?
http://blockdata.loyce.club/inputs/blockchair_bitcoin_inputs_20110615.tsv.gz
http://blockdata.loyce.club/outputs/blockchair_bitcoin_outputs_20110615.tsv.gz
http://blockdata.loyce.club/transactions/blockchair_bitcoin_transactions_20110615.tsv.gz
If it’s here, I can help you grab it.
But if it’s private, it won’t be on the blockchain, right?
Brute forcing it like mining is all I know to do.
Yep, it's in the Coinbase transaction. It can get tricky since it's not a standard protocol. Any change in transactions will mess up the merkle root, but using an extranonce could simplify it. Those r and s values are found in the signature. Good luck parsing that, not sure what you'll get since they should be random.
Got it. You're referring to the ECDSA signature algorithm where k, or the transaction nonce, is picked to create r and s.
It’s not in the raw transaction, but I mentioned earlier that I found a way to extract nonce k from the private key, the message data, and other values here: https://this forum.org/index.php?topic=5316741.msg56331333#msg56331333.
Right, exactly! I’m just struggling to find more data on it myself. Block nonces are typically 10 decimal digits or 8 hex 32-bit. I wonder what format the secret K is in. Is it also a 32-bit string?
Interesting thread, appreciate it. But why bother finding K if you already have P? Knowing K would give away P.
Check this out:
S1 = (h1+rx1*P)/k => k = (h1+rx1*P)/S1
S2 = (h2+rx2*P)/(k+1) => k+1 = (h2+rx2*P)/S2
There’s a whole calculation here...
Hey friends, I got inspired by the table from Iceland's rsz and made some Python code for cases with k, k+1, k+m. I don't know any private key examples to test, so I need you guys to check it out. If it works, I’ll share it on GitHub. Seems like there’s no resource like this yet, so it could help everyone!
Related topics
- Clipboard Vulnerabilities in Cryptocurrency Transactions 8
- Exploring n-values and b-values in secp256k1 19
- Questions about SegWit and Compatibility with Old Bitcoin Nodes 12
- New Bitcoin Improvement Proposal with $100 Reward 9
- Understanding the Differences Between Traditional and Simplified Chinese Mnemonics 6
- Understanding Fees with Taproot Script Usage 3