-
Notifications
You must be signed in to change notification settings - Fork 147
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Implement BIP 101 and accurate sigop/sighash counting #22
Commits on Jul 3, 2015
-
assets-attribution: Update typicons to MIT license
stephenhutchings commented 3 Jul 2015, 6:35 GMT: > Hi Luke, happy for these to be distributed under the terms of the MIT licence. > Let me know if you need anything further from me.
Configuration menu - View commit details
-
Copy full SHA for dae0a89 - Browse repository at this point
Copy the full SHA dae0a89View commit details -
dae0a89 assets-attribution: Update typicons to MIT license (Luke Dashjr)
Configuration menu - View commit details
-
Copy full SHA for 7bf37e1 - Browse repository at this point
Copy the full SHA 7bf37e1View commit details
Commits on Jul 6, 2015
-
Configuration menu - View commit details
-
Copy full SHA for 9a2469e - Browse repository at this point
Copy the full SHA 9a2469eView commit details -
9a2469e release notes for fee estimation changes (Alex Morcos)
Configuration menu - View commit details
-
Copy full SHA for ebad618 - Browse repository at this point
Copy the full SHA ebad618View commit details
Commits on Jul 8, 2015
-
Configuration menu - View commit details
-
Copy full SHA for 5460b24 - Browse repository at this point
Copy the full SHA 5460b24View commit details -
Configuration menu - View commit details
-
Copy full SHA for 757ceaa - Browse repository at this point
Copy the full SHA 757ceaaView commit details
Commits on Jul 10, 2015
-
Configuration menu - View commit details
-
Copy full SHA for d26f951 - Browse repository at this point
Copy the full SHA d26f951View commit details
Commits on Jul 27, 2015
-
Refactor: protect mapNodeState with its own lock
Encapsulate mapNodeState in a smart-pointer class with its own lock. Why? So Misbehaving() can be called from the sanity-check-a-message code without holding cs_main. And to get better exception safety (the smart-pointer approach gives RAII semantics). And because protecting fewer things with cs_main is a good idea. Tested by compiling with -DDEBUG_LOCKORDER, running all of the qa/rpc-tests, and running a node on the main network overnight.
Configuration menu - View commit details
-
Copy full SHA for 1e67b90 - Browse repository at this point
Copy the full SHA 1e67b90View commit details -
Refactor, new CNode::FinalizeHeader method
I need this to write some unit tests for the CNode::ReceiveMsgBytes() function.
Configuration menu - View commit details
-
Copy full SHA for 59fd6fc - Browse repository at this point
Copy the full SHA 59fd6fcView commit details -
Configuration menu - View commit details
-
Copy full SHA for c0dbdd5 - Browse repository at this point
Copy the full SHA c0dbdd5View commit details -
Configuration menu - View commit details
-
Copy full SHA for 4004cda - Browse repository at this point
Copy the full SHA 4004cdaView commit details -
Testing infrastructure: mocktime fixes
New, undocumented-on-purpose -mocktime=timestamp command-line argument to startup with mocktime set. Needed because time-related blockchain sanity checks are done on startup, before a test has a chance to make a setmocktime RPC call. And changed the setmocktime RPC call so calling it will not result in currently connected peers being disconnected due to inactivity timeouts.
Configuration menu - View commit details
-
Copy full SHA for b4f2d1d - Browse repository at this point
Copy the full SHA b4f2d1dView commit details -
Testing: remove coinbase payment key from keypool
Blocks generated in -regtest mode would pay to a key that was left in the keypool, which can cause subtle bugs. In particular, I expected every block generated to be unique, but got duplicate blocks between calls to setgenerate. Fixes Bitcoin Core issue 6268.
Configuration menu - View commit details
-
Copy full SHA for 4d03e8d - Browse repository at this point
Copy the full SHA 4d03e8dView commit details
Commits on Aug 4, 2015
-
Implement hard fork to allow bigger blocks
Unit test and code for a bigger-block hard fork. Parameters are: 8MB cap ... doubling every two years (so 16MB in 2018) ... for twenty years ... earliest possible chain fork: 11 Jan 2016 ... after miner supermajority ... and grace period once miner supermajority achieved qa/rpc-tests/bigblocks.py mines a 50% upgraded -regtest chain, generates 4MB of transactions, and then tests the upgrade and mining code to make sure larger blocks are only created when the fork conditions are met. The activation state of the fork is stored in the block tree database; it is written when the threshold is met (and unwritten if the threshold block is re-orged out of the best chain), and read at startup. Code review and bug fixes by Mike Hearn.
Configuration menu - View commit details
-
Copy full SHA for bd82dd5 - Browse repository at this point
Copy the full SHA bd82dd5View commit details -
Configuration menu - View commit details
-
Copy full SHA for 2264ba1 - Browse repository at this point
Copy the full SHA 2264ba1View commit details -
Set default block size for miners to be equal to the hard limit by de…
…fault. This avoids the situation that has happened several times where the network starts running out of capacity and miners must be manually contacted in a rush to tell them about the command line flag.
Configuration menu - View commit details
-
Copy full SHA for ae1cc25 - Browse repository at this point
Copy the full SHA ae1cc25View commit details -
Make fork warning use version bit masking, on the assumption that fro…
…m this point on all changes will be triggered by a bit in nVersion rather than an incrementing integer.
Configuration menu - View commit details
-
Copy full SHA for 13d2024 - Browse repository at this point
Copy the full SHA 13d2024View commit details -
Allow precise tracking of validation sigops / bytes hashed
Adds a BlockValidationResourceTracker class that is passed to CheckInputs() / CScriptCheck() to keep track of the exact number of signature operations required to validate a block, and the exact number of bytes hashed to compute signature hashes. Also extends CHashWriter to keep track of number of bytes hashed. Intended to be the starting point for consensus rule changes to replace the incorrect, messy sigop counting and size-limiting rules currently in place.
Configuration menu - View commit details
-
Copy full SHA for b1e5f5b - Browse repository at this point
Copy the full SHA b1e5f5bView commit details -
Implement accurate sigop / sighashbytes counting block consensus rules
Replace the inaccurate / somewhat ineffective consensus rule for number of signature operations per block with new consensus rules that accurately count the number of ECDSA signature operations needed to validate a block, and the number of bytes of data needed to compute signature hashes (to mitigate the attack described in CVE-2013-2292). BIP number for this to be determined. Constants were chosen such that any 'non-attack' transaction valid under the old rules is also valid under the new rules, but maximum possible block validation times are well-bounded, but tied to block size increases. Summary of old rules / new rules: Old rules: 20,000 inaccurately-counted-sigops for a 1MB block New: 80,000 accurately-counted sigops for an 8MB block A scan of the last 100,000 blocks for high-sigop blocks gets a maximum of 7,350 sigops in block 364,773 (in a single, huge, ~1MB transaction). For reference, Pieter Wuille's libsecp256k1 validation code validates about 10,000 signatures per second on a single 2.7GHZ CPU core. Old rules: no limit for number of bytes hashed to generate signature hashes New rule: 1.3gigabytes hashed per 8MB block to generate signature hashes Block 364,422 contains a single ~1MB transaction that requires 1.2GB of data hashed to generate signature hashes.
Configuration menu - View commit details
-
Copy full SHA for 2030a5a - Browse repository at this point
Copy the full SHA 2030a5aView commit details