Signing Transactions on Offline Computer without Blockchain #19810

issue Rspigler openend this issue on August 26, 2020
  1. Rspigler commented at 1:38 am on August 26, 2020: contributor

    Is your feature request related to a problem? Please describe. I am working with a team on Yeti (https://github.com/JWWeatherman/yeticold), which is a script for a UI for setting up offline, HD multisig with only minimal software beyond Bitcoin Core. Only QR codes are used for transferring private keys. As Core continues to merge PRs on offline, multisig, and UI work, Yeti will remove its own written code for the more peer reviewed Core releases. The goal is that Yeti is eventually not needed at all.

    Currently, Core needs a blockchain to sign transactions, even if the wallet is offline (and doesn’t truly need a blockchain). This means that although the wallet is getting the data it needs to sign from the QR code, the process now must look like this:

    The computer needs to be online for days first in order to sync the blockchain (even though it’ll never be used), then network access can be disabled, and descriptors generated. This could be made much simpler without having to sync.

    Describe the solution you’d like I know there is a lot of work on making Core more modular (https://github.com/bitcoin/bitcoin/projects/10). Once that project is finished, is it part of the plan to be able to sign transactions without a blockchain present?

  2. Rspigler added the label Feature on Aug 26, 2020
  3. sipa commented at 1:41 am on August 26, 2020: member

    PSBT and raw transaction signing should work fine without the blockchain synced.

    What specifically does not work?

  4. MarcoFalke commented at 5:43 am on August 26, 2020: member
    Offline signing should work out of the box. Please include the error message you encounter.
  5. MarcoFalke added the label Waiting for author on Aug 26, 2020
  6. willweatherman commented at 10:15 pm on August 26, 2020: none
    Hi, I am Will Weatherman, also working on yeti. The error I am running into is: “error”: “Input not found or already spent” When signing a raw transaction with the key without the blockchain synced.
  7. willweatherman commented at 10:16 pm on August 26, 2020: none
    I have been able to sign a transaction with a blockchain out of sync by a couple of transactions by specifying the utxos in between but that would not work when you have 10 years of utxos to trace back to the original transaction.
  8. sipa commented at 10:20 pm on August 26, 2020: member

    You can’t sign a transaction without knowing the UTXOs that it spends, so that information has to come from somewhere - there is no way around that. It can come from the chainstate (built when syncing the blockchain), from the local wallet (also built while syncing), or be passed as an RPC argument to signrawtransaction*, or come all together with the rest of the transaction to sign using PSBT.

    If you don’t have the blockchain, you’ll need to pass it using one of the other methods. PSBT is definitely the easiest, as it means that information is just provided by the entity proposing the transaction (which tends to be on online system that has access to the UTXOs being spent).

  9. willweatherman commented at 11:23 pm on August 26, 2020: none
    Just figured out how to use the PSBTs and sign a transaction without the blockchain. This will save yeti users days of waiting for the blockchain to download. Thank you.
  10. Rspigler commented at 0:40 am on August 27, 2020: contributor

    I misunderstood the error. My apologies. Thank you for your help!

    Closing.

  11. Rspigler closed this on Aug 27, 2020

  12. DrahtBot locked this on Feb 15, 2022

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-10-31 03:12 UTC

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