1 2018-04-24 15:39:27 <robzon> hmm I'm playing around with theoretical data structures for blockchain... currently an OutPoint is pretty hefty (32b txid + 4b txo idx) and I was thinking whether it could be replaced with a different addressing format, like <height><tx index><output index>, which would effectively be 8b or so (assuming uint32 for height, uint16 for both tx index and txout index), but... this way would be vulnerable
2 2018-04-24 15:39:33 <robzon> to chain reorgs (ie block at referenced height has changed, but the pkscript at the address would still evaluate to true, and the tx would spend the unintended output). I thought the solution might be to add chain id to the transaction header, so that the tx would be only valid if a block with a specified hash existed in the chain. that way a reorg would invalidate the tx while preserving 8-byte
3 2018-04-24 15:39:39 <robzon> addressing
4 2018-04-24 15:42:41 <robzon> what do you think? can you see any other problems with this solution?
5 2018-04-24 15:51:01 <robzon> one more thing I see here is that txs with very recent chain id (younger than, say, 6 blocks) could not be trusted since a reorg would completely invalidate them
6 2018-04-24 15:59:49 <robzon> it would also work as a future-proof replay protection