Enable various p2sh-p2wpkh functionality #11089

pull luke-jr wants to merge 5 commits into bitcoin:master from luke-jr:p2shp2wpkhstuff changing 6 files +50 −2
  1. luke-jr commented at 4:33 pm on August 18, 2017: member
    A subset of #9017
  2. in src/base58.cpp:289 in 83c37fd1ea outdated
    280@@ -281,6 +281,15 @@ bool CBitcoinAddress::GetKeyID(CKeyID& keyID) const
    281     return true;
    282 }
    283 
    284+bool CBitcoinAddress::GetScriptID(CScriptID& scriptID) const
    285+{
    286+    if (!IsValid() || vchVersion != Params().Base58Prefix(CChainParams::SCRIPT_ADDRESS)) {
    287+        return false;
    288+    }
    289+    memcpy(scriptID.begin(), &vchData[0], 20);
    


    meshcollider commented at 1:07 am on August 19, 2017:
    Prefer vchData.data() over &vchData[0]
  3. fanquake added the label Wallet on Aug 20, 2017
  4. luke-jr force-pushed on Aug 21, 2017
  5. Add function to retrieve nested p2sh witness program keyhash from keystore 98f6455628
  6. Enable pubkey lookup for p2sh-p2wpkh in validateaddress 84d4fba710
  7. Add CBitcoinAddress::GetScriptID 17350fe417
  8. Enable dumpprivkey for p2sh-p2wpkh b4008bca7d
  9. Accept p2sh-p2wpkh addr in createmultisig_redeemScript 0c4572c375
  10. luke-jr force-pushed on Aug 21, 2017
  11. in src/base58.cpp:286 in 0c4572c375
    280@@ -281,6 +281,15 @@ bool CBitcoinAddress::GetKeyID(CKeyID& keyID) const
    281     return true;
    282 }
    283 
    284+bool CBitcoinAddress::GetScriptID(CScriptID& scriptID) const
    285+{
    286+    if (!IsValid() || vchVersion != Params().Base58Prefix(CChainParams::SCRIPT_ADDRESS)) {
    


    jimpo commented at 7:27 pm on August 23, 2017:
    nit: Use if (!IsScript())
  12. laanwj added this to the milestone 0.15.1 on Aug 23, 2017
  13. laanwj commented at 7:53 pm on August 23, 2017: member
    Added 0.15.1 milestone
  14. luke-jr commented at 8:01 pm on August 23, 2017: member
    IMO it’s a 0.16 thing. IMO segwit-interim-release ought to have been called 0.16, but apparently it’s 0.15.1. I don’t mind in that case.
  15. laanwj added the label Needs backport on Aug 23, 2017
  16. instagibbs commented at 7:16 pm on September 7, 2017: member
    needs rebase
  17. laanwj added this to the "Blockers" column in a project

  18. sipa commented at 8:54 pm on September 24, 2017: member

    This needs a rebase after CBitcoinAddress was removed in #11117. However, this will become much easier after #11167, as then native witness destinations can be used.

    Also, I’m not convinced that dumpprivkey for (p2sh or not) segwit addresses is the right approach, as you can’t expect importprivkey to work for those.

  19. laanwj removed this from the "Blockers" column in a project

  20. MarcoFalke commented at 10:31 am on October 4, 2017: member
    Needs rebase
  21. promag commented at 10:18 pm on October 17, 2017: member
    Either close (because it’s in #11403) or rebase?
  22. MarcoFalke removed the label Needs backport on Nov 9, 2017
  23. MarcoFalke removed this from the milestone 0.15.2 on Nov 9, 2017
  24. MarcoFalke commented at 7:45 pm on November 9, 2017: member
    Removing from backport
  25. jonasschnelli referenced this in commit d889c036cd on Jan 11, 2018
  26. luke-jr commented at 6:18 am on March 2, 2018: member
    I don’t know how to rebase this.
  27. luke-jr closed this on Mar 2, 2018

  28. sipa commented at 3:22 pm on March 2, 2018: member
    Isn’t all the functionality in this PR merged through other patches? If something isn’t, I’d like to know.
  29. instagibbs commented at 3:27 pm on March 2, 2018: member

    I believe so.

    On Fri, Mar 2, 2018, 11:23 AM Pieter Wuille notifications@github.com wrote:

    Isn’t all the functionality in this PR merged through other patches? If something isn’t, I’d like to know.

    — You are receiving this because you commented. Reply to this email directly, view it on GitHub https://github.com/bitcoin/bitcoin/pull/11089#issuecomment-369950468, or mute the thread https://github.com/notifications/unsubscribe-auth/AFgC06R5bdjd25ARJGFe0TpQ6HouALGXks5taWQCgaJpZM4O7x6X .

  30. luke-jr commented at 4:17 pm on March 2, 2018: member

    This had 4 changes:

    • “pubkey” from DescribeAddressVisitor acting on a P2SH-wrapped Segwit address - This seems to be handled recursively or something now (although I don’t see logic to prevent P2SH-within-P2SH, but that’d be an unrelated bug)
    • validateaddress RPC gets metadata for 1-prefix addresses from witness addresses using it (if I’m reading the code correctly) - I don’t see this in the 0.16 code, but it seems like a bad idea anyway.
    • _createmultisig_redeemScript looked up full pubkey from Segwit addresses - Seems to be correctly handled in a very different way now.
    • dumpprivkey from witness address - Seems to be correctly handled in a different way now.
  31. meshcollider deleted a comment on Nov 12, 2018
  32. meshcollider deleted a comment on Nov 12, 2018
  33. MarcoFalke locked this on Sep 8, 2021

github-metadata-mirror

This is a metadata mirror of the GitHub repository bitcoin/bitcoin. This site is not affiliated with GitHub. Content is generated from a GitHub metadata backup.
generated: 2024-06-26 13:12 UTC

This site is hosted by @0xB10C
More mirrored repositories can be found on mirror.b10c.me