Ravencoin icon indicating copy to clipboard operation
Ravencoin copied to clipboard

Add P2SH support for tagging addresses

Open blondfrogs opened this issue 2 years ago • 0 comments

  • This fixes the issue which was shared with me from @jeroz1.

This was the bug If you try to tag a P2SH address with a Qualifier, the tag lands instead on the P2PKH address whose HASH160 is the same as the hash of the redeem script of the intended P2SH address. In English: you can't tag P2SH addresses because the tag goes to a different address.

This fix was written and tested via regtest. If this was to go live without the proper bip9 activation the chain could suffer a fork. Would probably be a good idea to wrap these changes with the P2SH bip9 if it hasn't gone to mainnet yet.

Feel free to cherry-pick this commit, add the proper bip9 activation code before releasing to testnet / mainnet.

blondfrogs avatar Jun 30 '22 19:06 blondfrogs