From 16352f14023f71145c80d48197d50727280a8460 Mon Sep 17 00:00:00 2001 From: Rithvik Vibhu Date: Fri, 25 Aug 2023 22:51:19 +0530 Subject: [PATCH 1/3] chain: set bits for non-force deployments also reverts partial 5928e80 --- lib/blockchain/chain.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/blockchain/chain.js b/lib/blockchain/chain.js index bacee34a2..7e943a0b5 100644 --- a/lib/blockchain/chain.js +++ b/lib/blockchain/chain.js @@ -3582,7 +3582,7 @@ class Chain extends AsyncEmitter { const state = await this.getState(prev, deployment); if (state === thresholdStates.LOCKED_IN - || (state === thresholdStates.STARTED && deployment.force)) { + || state === thresholdStates.STARTED) { version |= 1 << deployment.bit; } } From 02bb45dded6077567884a1bc13febe125595f968 Mon Sep 17 00:00:00 2001 From: Rithvik Vibhu Date: Fri, 25 Aug 2023 22:53:52 +0530 Subject: [PATCH 2/3] miner: default block version to chain calculated reverts 5e20a5a which was meant to be temporary --- lib/mining/miner.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/mining/miner.js b/lib/mining/miner.js index daa067eeb..9a8913c78 100644 --- a/lib/mining/miner.js +++ b/lib/mining/miner.js @@ -469,7 +469,7 @@ class MinerOptions { this.chain = null; this.mempool = null; - this.version = 0; + this.version = -1; this.addresses = []; this.coinbaseFlags = Buffer.from(`mined by ${pkg.name}`, 'ascii'); this.preverify = false; From ab0fa43dcc8ca0806477d6537e103019e5ee7040 Mon Sep 17 00:00:00 2001 From: Rithvik Vibhu Date: Sat, 26 Aug 2023 15:02:39 +0530 Subject: [PATCH 3/3] test: disable hardening in icann lockup test --- test/chain-icann-lockup-test.js | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/test/chain-icann-lockup-test.js b/test/chain-icann-lockup-test.js index f5b79c05f..477624cf3 100644 --- a/test/chain-icann-lockup-test.js +++ b/test/chain-icann-lockup-test.js @@ -1062,6 +1062,10 @@ async function mineBlock(node, opts = {}) { const job = await miner.cpu.createJob(chain.tip); + // opt out of all (esp. `hardening`) as + // some domains in this test still use RSA-1024 + job.attempt.version = 0; + if (setICANNLockup) job.attempt.version |= (1 << deployments[SOFT_FORK_NAME].bit);