electrs
electrs copied to clipboard
Fix: Output index should be u32 to prevent clobbering when over 65536 outputs.
Warning: REQUIRES RE-INDEX!!!!
Problem: If tx has over 16 bits of outputs, the indexing will clobber index 0 with index 65536 and so on.
Solution: 4 billion outputs is impossible without a hard fork. Use u32.
Tested ACK @ 5b2075b2ec631d8126571add525a836a6dc6d932
Successfully reindexed both Liquid and testnet db. The out of range prevout bug, which reproduced locally on current electrs version, did not reproduced after reindexing on 5b2075b2ec631d8126571add525a836a6dc6d932.
On liquid, everything seems to work fine with the new index (peg ins and assets notably)