<ol>
<li><p>Yes, they can do that.</p></li>
<li><p>Correct, though the switchover requires a 95% threshold to make the chance that old nodes see confirmations on such blocks very small.</p></li>
<li><p>Segwit nodes never accept blocks that have a witness commitment but no witness section. Either the block must not have a commitment (in which case it will be invalid, as script validation fails), or it is outright not accepted (because there is missing data; similar to a block with missing transactions isn't accepted).</p></li>
<li><p>Miners that don't validate a block before mining on top of it violate the security assumptions of the network. We can't prevent them from doing so (with or without segwit), but that is one of the reasons why block propagation and block validation needs to be low-latency: so that the potential advantage miners get from SPV mining is not too significant.</p></li>
</ol>

CC BY-SA 3.0
2016-04-13T14:52:53.797Z
Why are there any requirements in step (2)? There is a valid PoW block at height N with valid transactions came from 0.9.x node which known nothing about segwit. And a valid block at height (N+1) with segwit-data. What block height will you start to mine? N or (N+1) or (N+2)?
amaclin
CC BY-SA 3.0
2016-04-13T22:03:57.367Z
Segwit transactions are non-standard to old versions very far back. A 0.9 node will never mine them unless they're modified to do so.
Pieter Wuille
CC BY-SA 3.0
2016-04-13T22:18:08.950Z
We are talking about transactions in block. v0.9.x will accept such block without segwit data, check it and relay to all peers. segwit transactions are quite correct in bitcoin block for such clients
amaclin
CC BY-SA 3.0
2016-04-14T11:35:49.233Z
0.9.x won't create blocks with segwit transactions, but yes, it will accept, so your point (2) is correct. However, mining such an invalid block will only happen intentionally, and is costly. Furthermore, because the rule only activates after 95% support, a chain not building on top will grow 20x faster, so confirmations on top are very unlikely.
Pieter Wuille
CC BY-SA 3.0
2016-04-14T12:02:52.150Z
[quote]However, mining such an invalid block will only happen intentionally, and is costly [/quote] 12.5+ btc - is not a big cost. I will pay these funds to a mining pool for creating a valid block with my content, broadcasting "standard" part to a network and withholding segwit part of it. just for fun :)
amaclin
CC BY-SA 3.0
2016-04-13T14:42:18.150Z
2016-04-13T14:42:18.150Z
Pieter Wuille
<p>Is the following scenario valid?</p>

<ol>
<li>Some unhonest segwit mining pool takes top-1000 segwit utxo and mines a block at height N with a transaction which transfers all funds to his p2pkh address</li>
<li>This block does not have segwit data portion, but it can be broadcasted to all non-segwit nodes on the network</li>
<li>All other pools have a dilema - wait the segwit data associated with this block or start mining block N+1 on the top of N</li>
<li>What if miners will use SPV-mining on the top of this block? They will create blocks at heights N+1, N+2... etc without checking the segwit-validity of block N</li>
</ol>

<p>Also asked here: <a href="https://bitcointalk.org/index.php?topic=1434842.0" rel="nofollow">https://bitcointalk.org/index.php?topic=1434842.0</a></p>

<segregated-witness>
SegWit and SPV-mining. What if...?
amaclin
# SegWit and SPV-mining. What if...?

(Asked by: username_0 on 2016-04-13)

Is the following scenario valid?

1. Some unhonest segwit mining pool takes top-1000 segwit utxo and mines a block at height N with a transaction which transfers all funds to his p2pkh address
2. This block does not have segwit data portion, but it can be broadcasted to all non-segwit nodes on the network
3. All other pools have a dilema - wait the segwit data associated with this block or start mining block N+1 on the top of N
4. What if miners will use SPV-mining on the top of this block? They will create blocks at heights N+1, N+2... etc without checking the segwit-validity of block N

Also asked here: <https://bitcointalk.org/index.php?topic=1434842.0>

**Tags:** segregated-witness


---

## 1 answers

### Answer by username_1 on 2016-04-13. Score: 4

1. Yes, they can do that.
2. Correct, though the switchover requires a 95% threshold to make the chance that old nodes see confirmations on such blocks very small.
3. Segwit nodes never accept blocks that have a witness commitment but no witness section. Either the block must not have a commitment (in which case it will be invalid, as script validation fails), or it is outright not accepted (because there is missing data; similar to a block with missing transactions isn't accepted).
4. Miners that don't validate a block before mining on top of it violate the security assumptions of the network. We can't prevent them from doing so (with or without segwit), but that is one of the reasons why block propagation and block validation needs to be low-latency: so that the potential advantage miners get from SPV mining is not too significant.

> **Comments:**
> **username_0**: Why are there any requirements in step (2)? There is a valid PoW block at height N with valid transactions came from 0.9.x node which known nothing about segwit. And a valid block at height (N+1) with segwit-data. What block height will you start to mine? N or (N+1) or (N+2)?  
> **username_1**: Segwit transactions are non-standard to old versions very far back. A 0.9 node will never mine them unless they're modified to do so.  
> **username_0**: We are talking about transactions in block. v0.9.x will accept such block without segwit data, check it and relay to all peers. segwit transactions are quite correct in bitcoin block for such clients  
> **username_1**: 0.9.x won't create blocks with segwit transactions, but yes, it will accept, so your point (2) is correct. However, mining such an invalid block will only happen intentionally, and is costly. Furthermore, because the rule only activates after 95% support, a chain not building on top will grow 20x faster, so confirmations on top are very unlikely.  
> **username_0**: [quote]However, mining such an invalid block will only happen intentionally, and is costly [/quote] 12.5+ btc - is not a big cost. I will pay these funds to a mining pool for creating a valid block with my content, broadcasting "standard" part to a network and withholding segwit part of it. just for fun :)  

---

