Author

Topic: BTC stuck in Electrum multi-sig (will pay $1k reward) (Read 488 times)

legendary
Activity: 3290
Merit: 16489
Thick-Skinned Gang Leader and Golden Feather 2021
Technical issues like that is what puts me off using hardware wallets, which is why I like to keep it simple and sign via electrum air gapped computer.
A multisig with 2 different hardware wallets isn't the most standard way to use hardware wallets, so I don't think this should be a reason not to use them. I would however recommend funding and withdrawing a small amount before putting your life savings into a multisig address. It also doesn't hurt to verify you can do the same from your (seed word) backups.
member
Activity: 81
Merit: 30
Glad it worked out for you.  Smiley

Technical issues like that is what puts me off using hardware wallets, which is why I like to keep it simple and sign via electrum air gapped computer.
legendary
Activity: 952
Merit: 1386
Very nice kung-fu! Congratulations!
newbie
Activity: 7
Merit: 31
Hi all,

Thanks for all your help, but I was able to figure it out.

Here's what I did in case anyone has the same problem:

1. Used someone's Windows computer
2. Loaded up Electrum on there - same version 3.3.8 - with Electrum + Ledger wallet files
3. Ran Electrum as administrator (may or may not have helped)
4. Signed transactions from Electrum wallet file
5. Before signing + broadcasting with Ledger (via Electrum), I did this:

Quote
You need to modify the ledger.py file found in x:\Program Files (x86)\Electrum-RVN\electrum\plugins\ledger.
You can use notepad to modify it. Under DEVICE_IDS = [ you should see something like (0x2c97, 0x0001), # Nano-S
You need to change it to (0x2c97, 0x1015), # Nano-S
Here are the codes for the different Ledger
Ledger Nano S : Product ID 0x1015
Ledger Blue : Product ID 0x0015
Ledger Nano X : Product ID 0x4015
Hope this helps

Personally I changed the DEVICE_ID to (0x2c97, 0x1011) after (0x2c97, 0x1015) didn't work because:

Quote
You can find your product ID in Windows device manager in the details tab of your Nano. It looks like USB\VID_2C97&PID_1011
https://www.ledger.com/windows-10-update-sunsetting-u2f-tunnel-transport-for-ledger-devices#:~:text=Ledger%20Blue%20%3A%20Product%20ID%200x0011,Nano%20X%20%3A%20Product%20ID%200x4011

(Credit to this person who helped someone with an Electrum Ravencoin issue:
https://www.reddit.com/r/Ravencoin/comments/k473eb/ledger_electrumrvn_338rvn3_wont_detect_device/gnai1oi/)

6. After making the above change to the ledger.py file in the Electrum program files, Electrum detected the Ledger, and I was able to sign transactions and broadcast them!

7. I had to wait a bit for the transactions to sign + confirm (I think because I had a lot of inputs), but damn it finally worked

Again, thanks to everyone for their help. And I hope no one has to go through this

What I thought would be a nice HODL ended up being very stressful.

I think the lesson is to not overcomplicate things if you aren't a pro
legendary
Activity: 2268
Merit: 18771
o_e_l_e_o he also has to select legacy p2sh as the script type.
I'm not sure he does. If he enters his Electum seed phrase as the first signer, then Electrum will automatically choose the matching script type for the two hardware wallets and he won't get a choice. He'll only get shown a choice if he enters one of the hardware wallets as the first cosigner, but if he picks the wrong script type then Electrum will return an error when he tries to enter his Electrum seed phrase and he won't be able to generate a wallet at all.

CMIIW though.
legendary
Activity: 3710
Merit: 1586
o_e_l_e_o he also has to select legacy p2sh as the script type.
legendary
Activity: 2268
Merit: 18771
So reading through that very incorrect guide you followed again, here is what I think you need to do to solve this issue:

  • Open Electrum and create a new wallet
  • Select "Multi-signature wallet" followed by 2-of-3
  • For the first signer, select "I already have a seed" and enter your Electrum seed phrase
  • For the second signer, attach one of your hardware wallets, select "Cosign with hardware device", and then change the derivation path to m/49'/0'/0'
  • Repeat the previous step for the third signer with your other hardware wallet attached
  • Open the wallet and see if the addresses match up/the funds are visible

This is assuming you used the derivation path m/49'/0'/0' as that guide incorrectly states you should. If you used either m/44'/0'/0' or m/84'/0'/0' (or something else entirely), then substitute that in above.

If that all fails, then the next solution is going to be to try to recreate your hardware-wallet linked Electrum wallets from the relevant seed phrases on an airgapped computer, extract their master private keys, and then use those to recover your multi-sig wallet.
legendary
Activity: 3710
Merit: 1586
To add to what nc50lc is saying a standard wallet (single sig) will have a different derivation path than that for a multisig wallet so doing it like that could create more issues down the road.

edit: when restoring the multisig wallet from seed you will have to enter the same derivation path as in the guide  i.e. bip49.
legendary
Activity: 2618
Merit: 6452
Self-proclaimed Genius
That guide shouldn't be followed since it's not the correct way to set-up a MultiSig Electrum wallet using hardware devices.
But you already did and here we are.

The users don't need to create a standard wallet in order to get the hardware wallet's xpubs (master public key).
During the creation process, each cosigners should start creating a MultiSig wallet right from the start until the point when they'll be presented with their "Master Public Key".
Then send it to other cosigners (as that cosigner receive theirs) to finish their own MultiSig wallets.
HCP
legendary
Activity: 2086
Merit: 4363
Unfortunately don't see any balance when I do this
(when I create a new Electrum 2/3 multi-sig using my Electrum seed phrase and public keys from hardware wallets, I see my coins though)
So creating a 2-of-3 Multisig using "Seed" + hardware device + hardware device == incorrect wallet... but 2-of-3 Multisig using "seed" + "master public key" + "master public key" does work? If so, then it very much sounds like a "derivation" path and/or "Script Type" issue.

Having said that, it depends on how you try and set up the wallet as to what options Electrum will give you. If you put the "seed" in first, it should automatically detect if it is a "legacy" seed, or if it is a native segwit seed etc... and only prompt for derivation path:

"Legacy" seed used:



"Native Segwit" seed used:



If however, you try and use the "hardware key" first... it will give you the full "script type" and "derivation path" prompt:



So, when you are creating the wallet... what is the "seed type" that shows when you enter it? Huh

legendary
Activity: 952
Merit: 1386
If OP knows how to restore wallet from backup, he should definitely do this, the options are:
- on his mac using different path - to fix issue with Trezor
- on other machine (windows, linux, mobile) - to make Ledger working
I am not sure if intermediary solution -linux on virtualbox- would solve the issue.

Of course we assume both firmwares and Electrum are up to date.

Just a question- is seed based on Electrum dictionary?
legendary
Activity: 2268
Merit: 18771
Would derivation path cause these issues?  Just asking.
The error with the Ledger? No, that wouldn't be caused by an incorrect derivation path. If the derivation path was wrong, Electrum should still detect the Ledger, but just show a different wallet or be unable to sign transactions using it. That is more likely a problem with hardware, drivers, some other software accessing the Ledger at the same time, etc.

The error with the Trezor? Yes, potentially. If he has the wrong derivation path then he is opening a different wallet, which will obviously fail to detect the input in question from the original wallet and therefore return an error.
member
Activity: 81
Merit: 30

When I try to sign a transaction with Electrum (and then sign + broadcast with Ledger Nano S), it won't work because Electrum won't detect the Ledger Nano S.

When I try to sign a transaction with Electrum (and then sign + broadcast with Trezor One), it won't work because of the error "DataError: Expected input with amount".


Would derivation path cause these issues?  Just asking.
legendary
Activity: 952
Merit: 1386

I think the issue here is likely going to be derivation path related. That guide you linked to has you using m/49'/0'/0'. This is the standard derivation path for single sig P2WPKH-P2SH, but this is not the derivation path Electrum uses for multi-sig wallets. What are the first four character of your public keys from your hardware wallets (include capitalization if it is there please)?

Do you expect that problem?
https://bitcoin.stackexchange.com/questions/92533/why-do-the-xpubs-from-electrum-and-trezor-not-match-when-creating-a-multisig-wal

Like I said before, I think problem could be related to derivation paths, I see no point why trezor didn’t detect input.
Explained: https://www.reddit.com/r/Electrum/comments/bptrdj/electrum_multisig_derivation_path_for_different/
legendary
Activity: 2268
Merit: 18771
Right. So just to confirm you've got your three seed phrases, imported them no problem in to a new 2-of-3 multi-sig wallet (you didn't get any warnings like "checksum failed" or "unknown wordlist"?), generated a new wallet, and you've generated different addresses than you were expecting? (Note as above that if you do this on an airgapped device the balance will always be zero - you'll need to manually check if the addresses match.)

Can I also check what character do the addresses in your original multi-sig wallet start with? "1", "3", to "bc1"? What about the addresses in that new multi-sig wallet you just recovered using your seed phrases?

I think the issue here is likely going to be derivation path related. That guide you linked to has you using m/49'/0'/0'. This is the standard derivation path for single sig P2WPKH-P2SH, but this is not the derivation path Electrum uses for multi-sig wallets. What are the first four character of your public keys from your hardware wallets (include capitalization if it is there please)?

Have you ever been able to spend coins from this wallet? Did you test you could recreate it at any time before sending coins to it?
newbie
Activity: 7
Merit: 31
When I open ex) the Trezor file, I don't see any balance
Then those files are set up incorrectly. Every one of the three multi-sig files should show the same addresses and the same balance when you open them. This probably explains why you cannot currently spend your coins.

In the first instance, I would try creating a brand new Electrum wallet using your two hardware devices and your Electrum seed phrase, and without importing any master public keys/xpubs/ypubs/zpubs. This should create a new 2-of-3 multi-sig wallet which shows your coins, and which you can spend from. This is safe enough to do on your current computer since you are still protected by your hardware wallets. If doing this generates a different wallet with different addresses than your funded 2-of-3 multi-sig, then we have other issues to address before addressing any errors you are experiencing.

How long ago did you set up this multi-sig wallet? Do you remember how you did it? Have you reset either of the hardware wallets since you did it? Have you ever used a passphrase/13th word/25th word/seed extension?


"I would try creating a brand new Electrum wallet using your two hardware devices and your Electrum seed phrase, and without importing any master public keys/xpubs/ypubs/zpubs. This should create a new 2-of-3 multi-sig wallet which shows your coins, and which you can spend from. This is safe enough to do on your current computer since you are still protected by your hardware wallets. If doing this generates a different wallet with different addresses than your funded 2-of-3 multi-sig, then we have other issues to address before addressing any errors you are experiencing."

Unfortunately don't see any balance when I do this
(when I create a new Electrum 2/3 multi-sig using my Electrum seed phrase and public keys from hardware wallets, I see my coins though)

"How long ago did you set up this multi-sig wallet? Do you remember how you did it? Have you reset either of the hardware wallets since you did it? Have you ever used a passphrase/13th word/25th word/seed extension?"

I believe in early 2019

I did it following this guide
https://medium.com/@tiero/how-to-bitcoin-multi-signature-wallet-using-electrum-and-several-ledger-nano-s-225867e3b726

I am pretty sure I did the following:

Create 2/3 multi-sig wallet in Electrum
#1 = Electrum (the app)
#2 = import cosigner key from Ledger
#3 = import cosigner key from Trezor

If by resetting hardware wallets, you mean changing the seed, no I did not

"Have you ever used a passphrase/13th word/25th word/seed extension?"
Is this adding a password/extra word when entering your seed somewhere? If so, I didn't use anything like that
legendary
Activity: 952
Merit: 1386
I'm no expert but would try this,

Buy cheap android phone £50 and Install Electrum from Google play or better from Electrum.org using their method to verify the download is genuine.

From this point make sure the phone NEVER has internet until funds moved to your new hardware wallet address.

Using Anroid phone import a 2of2 multisig into Electrum with option "I already have seeds".  Use Bip39 when importing the hardware wallet seed.  The share addresses should match those on Mac when setup complete.

Now create the online transaction with your Mac computer and export the QR code so the phone can scan and sign the transaction.

Export the signed QR code from phone back to the Mac computer using scan option and transmit the transaction from your Mac computer to your new hardware wallet address.

Obviously the two sets of the seeds you used to recreate the multisig on the the phone  would have to be 2 of the 3 used when you created the Mac multisig.



I think I have a cheap never used phone before, so will give this a try

But what he wrote not really makes any sense, it is like creation of new wallet from backup. Could be on phone, on computer…
And take into regards what was written above about restoring from seed.
legendary
Activity: 2268
Merit: 18771
I think I have a cheap never used phone before, so will give this a try
Ok. This is essentially the same advice as I gave on the first page of this thread but using an airgapped phone instead of an airgapped computer. An airgapped phone is not as secure as a computer, so do so at your own risk. To be as safe as possible, you should reset the phone to factory settings, turn off all connectivity and turn on flight mode, download and verify the Electrum .apk from https://electrum.org/#download on your computer before transferring it to the phone via a clean and formatted SD card or similar.

You will need to import all three seed phrases (not just two), and select BIP39 for the two hardware wallet seed phrases.

The wallet on your phone will show zero balance since it does not have internet connectivity. You will need to check if the actual addresses match those from your funded multi-sig wallet.
newbie
Activity: 7
Merit: 31
I'm no expert but would try this,

Buy cheap android phone £50 and Install Electrum from Google play or better from Electrum.org using their method to verify the download is genuine.

From this point make sure the phone NEVER has internet until funds moved to your new hardware wallet address.

Using Anroid phone import a 2of2 multisig into Electrum with option "I already have seeds".  Use Bip39 when importing the hardware wallet seed.  The share addresses should match those on Mac when setup complete.

Now create the online transaction with your Mac computer and export the QR code so the phone can scan and sign the transaction.

Export the signed QR code from phone back to the Mac computer using scan option and transmit the transaction from your Mac computer to your new hardware wallet address.

Obviously the two sets of the seeds you used to recreate the multisig on the the phone  would have to be 2 of the 3 used when you created the Mac multisig.



I think I have a cheap never used phone before, so will give this a try
legendary
Activity: 2268
Merit: 18771
Correct!   Need all three sets of seeds to recreate the multisig.
Again, not quite. Tongue (I swear I'm not just being pedantic for the sake of it!)

You do not need all three seed phrases to recreate a 2-of-3 multi-sig. You need at least two seed phrases or master private keys, but the information you obtain from the third share could be a seed phrase, master private key, or master public key. You only need the seed phrase/master private key for the threshold number of shares (2 in this case), but you need one of those or the master public key from every share (3 in this case).

This is important when backing up your multi-sig wallet, since if you have two seed phrases but no information at all from the third share you will not be able to recover the wallet and spend your coins.
member
Activity: 81
Merit: 30
Correct!   Need all three sets of seeds to recreate the multisig.


legendary
Activity: 2268
Merit: 18771
When I open ex) the Trezor file, I don't see any balance
Then those files are set up incorrectly. Every one of the three multi-sig files should show the same addresses and the same balance when you open them. This probably explains why you cannot currently spend your coins.

In the first instance, I would try creating a brand new Electrum wallet using your two hardware devices and your Electrum seed phrase, and without importing any master public keys/xpubs/ypubs/zpubs. This should create a new 2-of-3 multi-sig wallet which shows your coins, and which you can spend from. This is safe enough to do on your current computer since you are still protected by your hardware wallets. If doing this generates a different wallet with different addresses than your funded 2-of-3 multi-sig, then we have other issues to address before addressing any errors you are experiencing.

How long ago did you set up this multi-sig wallet? Do you remember how you did it? Have you reset either of the hardware wallets since you did it? Have you ever used a passphrase/13th word/25th word/seed extension?

Obviously the two sets of the seeds you used to recreate the multisig on the the phone  would have to be 2 of the 3 used when you created the Mac multisig.
This is not how multi-sig works. You cannot "convert" a 2-of-3 multi-sig in to a 2-of-2 multi-sig by recovering from only 2 out of the 3 seeds. You must use information from all 3 shares, be that hardware wallets, seed phrases, or master public keys.
legendary
Activity: 952
Merit: 1386
Is it possible that you somehow misconfigured hardware wallet? Is it possible that wallet is created with a wrong derivation path and that's why Trezor does not detect amount input?
Did you try to create a brand new wallet (I mean restore from backup) and verify again derivation path?
You may want to take a look: https://bitcoin.stackexchange.com/questions/108296/cant-sign-using-trezor-t-derived-multisig-wallet-using-electrum-invalid-scrip
You are not the only one who has problems with multisig... https://github.com/spesmilo/electrum/issues/1383

Would it change anything if you try to do it on Linux machine (maybe emulated via https://www.virtualbox.org/wiki/Downloads + for example https://kubuntu.org/getkubuntu/) ? Or on Windows, but then probably you need another machine or play with https://support.apple.com/en-us/HT201468

Or take a look at that article, maybe 'how to restore' part would help you: https://saleemrashid.com/2018/01/27/hardware-wallet-electrum-multisig/
member
Activity: 81
Merit: 30
I'm no expert but would try this,

Buy cheap android phone £50 and Install Electrum from Google play or better from Electrum.org using their method to verify the download is genuine.

From this point make sure the phone NEVER has internet until funds moved to your new hardware wallet address.

Using Anroid phone import a 2of2 multisig into Electrum with option "I already have seeds".  Use Bip39 when importing the hardware wallet seed.  The share addresses should match those on Mac when setup complete.

Now create the online transaction with your Mac computer and export the QR code so the phone can scan and sign the transaction.

Export the signed QR code from phone back to the Mac computer using scan option and transmit the transaction from your Mac computer to your new hardware wallet address.

Obviously the two sets of the seeds you used to recreate the multisig on the the phone  would have to be 2 of the 3 used when you created the Mac multisig.

newbie
Activity: 7
Merit: 31
Not sure if that makes sense
Not really, lol.

When you say you open the hardware wallet with Electrum, are you opening the 2-of-3 multi-sig wallet that we are discussing here? Or are you just opening a standard single sig wallet with your hardware wallet connected?

If you are opening Electrum on its own and seeing one balance, and opening Electrum with the hardware wallet attached and seeing a different balance, then you are opening two different wallets. You will never be able to sign a transaction from a multi-sig doing this. You should be opening the same wallet in both situations.

So I have different Electrum wallet files for the Electrum multi-sig, Trezor, and Ledger.

It's only when I open the Electrum multi-sig file that I see my balance that I want to access.

When I open ex) the Trezor file, I don't see any balance
legendary
Activity: 2268
Merit: 18771
Not sure if that makes sense
Not really, lol.

When you say you open the hardware wallet with Electrum, are you opening the 2-of-3 multi-sig wallet that we are discussing here? Or are you just opening a standard single sig wallet with your hardware wallet connected?

If you are opening Electrum on its own and seeing one balance, and opening Electrum with the hardware wallet attached and seeing a different balance, then you are opening two different wallets. You will never be able to sign a transaction from a multi-sig doing this. You should be opening the same wallet in both situations.
newbie
Activity: 7
Merit: 31
~
This didn't work
(Though I don't know how to do the part "create the transaction with the hardware wallet" - if you can let me know/link to a good guide on how to do that, I can give it a try)

What I meant was that you can try starting the process with the hardware wallet, rather than your Electrum wallet.  So, open your hardware wallet, create a new transaction that you want to make, sign it, and save it.  Then import the partially signed transaction into the (non-hardware) Electrum wallet to add the second signature and broadcast.

Doing things in this order has worked for me in the past, but I use a Trezor wallet.  I have never played with a multi-sig wallet using the Nano.  It sounds like you have one of each brand, so it may work with one or the other hardware wallet.

So when I open the hardware wallet with Electrum, it doesn't show the coins I have in the non-hardware Electrum wallet

For example, let's say I have 1 BTC in the non-hardware wallet.

When I open the hardware wallet, that 1 BTC doesn't show, and I don't think I can make a txn with 1 BTC from the non-hardware wallet?

Not sure if that makes sense
HCP
legendary
Activity: 2086
Merit: 4363
Yes the Ledger Nano S works correctly with Ledger Live
Also, I don't have Ledger Live open when running Electrum
...

I tried opening just the Ledger wallet, and it still couldn't find the device
If the Nano S is working fine with Ledger Live, then it would appear that the issue is specifically with Electrum and it's Ledger plugin. You might want to raise an issue on the Electrum Github Issue tracker: https://github.com/spesmilo/electrum/issues

Note that the Devs will require that you're trying this on the latest version of Electrum (currently 4.1.5) before they offer any support.
copper member
Activity: 2338
Merit: 4543
Join the world-leading crypto sportsbook NOW!
~
This didn't work
(Though I don't know how to do the part "create the transaction with the hardware wallet" - if you can let me know/link to a good guide on how to do that, I can give it a try)

What I meant was that you can try starting the process with the hardware wallet, rather than your Electrum wallet.  So, open your hardware wallet, create a new transaction that you want to make, sign it, and save it.  Then import the partially signed transaction into the (non-hardware) Electrum wallet to add the second signature and broadcast.

Doing things in this order has worked for me in the past, but I use a Trezor wallet.  I have never played with a multi-sig wallet using the Nano.  It sounds like you have one of each brand, so it may work with one or the other hardware wallet.
legendary
Activity: 2268
Merit: 18771
However, If I buy a new computer/laptop, create a brand new 2-of-3 multi-sig wallet in Electrum, import the three seed phrases, and then sign a transaction from that single wallet, would it be ok to use that computer later on as my main computer (with Internet access)?
Presumably you would want to move all the coins out of this broken multi-sig wallet to a new wallet set up which you can access properly, such as a single sig hardware wallet, or a new multi-sig without the hardware wallets. Once you have done that, then there is no major security risk to that device then going online, since the old multi-sig wallet will be empty.

There is still a risk to your privacy if you were to leak the addresses from that wallet (if that concerns you), or a risk to the coins if you were to accidentally receive some coins to this old multi-sig set up in the future. I would probably just format the hard drive once I was done and start fresh. Alternatively, boot the new computer to a live Linux OS for the purposes of restoring your wallet, and then boot to the hard drive once you are done and want to use it as a regular computer.
newbie
Activity: 7
Merit: 31

When I try to sign a transaction with Electrum (and then sign + broadcast with Ledger Nano S), it won't work because Electrum won't detect the Ledger Nano S.

Which OS version do you have? Newer than 10.14? Does Nano S works correctly with Ledger Live?

macOS Big Sur 11.6

And yes Nano S works well with Ledger Live

Have you installed the firmware for your ledger nano s? Normally there's a driver or something you have to install to get it to work, ledger will likely have it on their website.

This link contain info on installing the ledger firmware: https://support.ledger.com/hc/en-us/articles/360002731113-Update-Ledger-Nano-S-firmware?docs=true
This is then the one for connecting the ledger to electrum (just in case you get a problem): https://support.ledger.com/hc/en-us/articles/115005161925-Set-up-and-use-Electrum?docs=true

Yep updated all firmware


When I try to sign a transaction with Electrum (and then sign + broadcast with Ledger Nano S), it won't work because Electrum won't detect the Ledger Nano S.
Why does that happen? When you made the setup, didn't it detect it?

Not sure and yes but I setup the wallet years ago. I think due to the various changes that have happened since then with Electrum/Trezor/Ledger, things are breaking


Is it possible that you selected several inputs and at least one of them is empty?



First at all - did you update firmware on both hardware wallets?


No inputs are empty

And firmware on both hardware wallets is up to date


Does the Ledger Nano S work correctly if you use Ledger Live? If not, then maybe try following the MacOS troubleshooting here: https://support.ledger.com/hc/en-us/articles/115005165269-Fix-USB-connection-issues-with-Ledger-Live?support=true

If it normally works with Ledger Live OK, did you have Ledger Live open and running when trying to use Electrum? Often, having multiple applications that are attempting to communicate with the Ledger device at the same time will cause problems. I've had issues in the past with Electrum being unable to communicate with a Nano S if Ledger Live was running. So, make sure Ledger Live is not running before you start Electrum and see if that helps with the communication process between Electrum and the Nano S.


NOTE: I have a Ledger Nano S and a Trezor ONE, and am able to use both with an Electrum 4.1.5 MultiSig "OK"... but I'm running Windows 10.

Yes the Ledger Nano S works correctly with Ledger Live

Also, I don't have Ledger Live open when running Electrum


Another method that may work is to open a watch only version of the wallet, create an unsigned transaction, sign it with the hardware wallet first, then import it into the Electrum wallet to add the second signature and broadcast.  I had a similar issue some time ago, sorry I don't remember the exact details, but signing the transaction with the hardware wallet first was effective.  Simply creating the transaction with the hardware wallet might also work.

I hope that helps, and best of luck.

This didn't work
(Though I don't know how to do the part "create the transaction with the hardware wallet" - if you can let me know/link to a good guide on how to do that, I can give it a try)


Another thought occurred to me... Do you just have one wallet file setup within Electrum... or did you create different wallet files for each hardware device using the Master Public Keys from the other device and the "normal" Electrum wallet? Huh

I was just mucking around testing some stuff... and found that the Ledger detection could be a bit "inconsistent" with multiple wallets open within Electrum... sometimes it would find it, sometimes it worked first time, sometimes it just refused to find it no matter how many times I rescanned etc.

With just a single wallet open, it was much more reliable, finding the device every time.


I tried opening just the Ledger wallet, and it still couldn't find the device



Thank you everyone for your responses so far...

I'm going to contact Ledger and Trezor support now (and post on their Reddits).

Also, I will try o_e_l_e_o 's method, but need to buy a new computer first.
(I've been meaning to buy a new one, but I guess this sped up my decision  Smiley)

However, If I buy a new computer/laptop, create a brand new 2-of-3 multi-sig wallet in Electrum, import the three seed phrases, and then sign a transaction from that single wallet, would it be ok to use that computer later on as my main computer (with Internet access)?

Or should I buy a new computer/laptop specifically to fix this wallet issue and never connect it to the Internet afterwards?

Thank you all!
legendary
Activity: 2268
Merit: 18771
Or you could do what Leo said and import your seed phrases from one of the hardware wallets into a new wallet in Electrum. But you'll need to figure out what derivation path your hardware wallet used.
The default derivation paths for Electrum multi-sigs are as follows:

Hardware wallets via Electrum:
Legacy (P2SH) - m/45'/0
P2SH-segwit (P2WSH-P2SH) - m/48'/0'/0'/1'
Segwit (P2WSH) - m/48'/0'/0'/2'

Electrum seed phrases:
Legacy: m
Segwit: m/1'
hero member
Activity: 2800
Merit: 595
https://www.betcoin.ag
Do you have the seed phrases backed up for the three parts of your multi-sig wallet? If you do, then I would think the easiest solution here would be to just create a brand new 2-of-3 multi-sig wallet in Electrum, and import the three seed phrases (remembering to select BIP39 for the two hardware wallet seed phrases). You can then sign a transaction from that single wallet without having to worry about compatibility issues with your two hardware wallets.

The downside to this is that you completely lose the security of your multi-sig wallet by importing all three seed phrases in to the same wallet. Therefore, you should only do this on a clean and airgapped computer.

He is about to send $1K to someone who can help anyway I think he will be glad to send all his funds to a safer version of the wallet.
Importing the three seed phrases will be the best option if I were him. It would however be great to send the error to the devs of the wallets particularly the Trezor for them to fix for the next update.  I guess Leo's suggestion fixes your issue.
legendary
Activity: 3472
Merit: 10611
After SegWit the signer needs the amount of each input to be included during the signing operation when the hash is produced. It also became mandatory to prevent some exploits in hardware wallets that could lead to losses either through huge fees or even sending to a maliciously included output.
This is why you need to upgrade and use the new format with your hardware wallets.

I'd focus on figuring out why new version of Electrum couldn't be installed on your system. You could also use a live offline Linux to run the latest version a lot easier and even with more security compared to your closed source Mac OS!

Or you could do what Leo said and import your seed phrases from one of the hardware wallets into a new wallet in Electrum. But you'll need to figure out what derivation path your hardware wallet used.
HCP
legendary
Activity: 2086
Merit: 4363
The wallet is set up as a 2/3 multi-sig wallet, with #1 being Electrum, #2 being Trezor One, and #3 being Ledger Nano S.

When I try to sign a transaction with Electrum (and then sign + broadcast with Ledger Nano S), it won't work because Electrum won't detect the Ledger Nano S.
When I try to sign a transaction with Electrum (and then sign + broadcast with Trezor One), it won't work because of the error "DataError: Expected input with amount".
Another thought occurred to me... Do you just have one wallet file setup within Electrum... or did you create different wallet files for each hardware device using the Master Public Keys from the other device and the "normal" Electrum wallet? Huh

I was just mucking around testing some stuff... and found that the Ledger detection could be a bit "inconsistent" with multiple wallets open within Electrum... sometimes it would find it, sometimes it worked first time, sometimes it just refused to find it no matter how many times I rescanned etc.

With just a single wallet open, it was much more reliable, finding the device every time.
copper member
Activity: 2338
Merit: 4543
Join the world-leading crypto sportsbook NOW!
I second o_e_l_e_o's advice.  Hardware wallets are notorious for having issues with multi-sig.  For holding large sums I prefer cold wallets, which can also be multi-sig.  To reap the full benefit of having multi-sig cold wallets you'll want to recover them only when absolutely needed and only on an air-gapped machine, or have them loaded on multiple air-gapped machines that are stored separately.

Another method that may work is to open a watch only version of the wallet, create an unsigned transaction, sign it with the hardware wallet first, then import it into the Electrum wallet to add the second signature and broadcast.  I had a similar issue some time ago, sorry I don't remember the exact details, but signing the transaction with the hardware wallet first was effective.  Simply creating the transaction with the hardware wallet might also work.

I hope that helps, and best of luck.
legendary
Activity: 952
Merit: 1386

When I try to sign a transaction with Electrum (and then sign + broadcast with Trezor One), it won't work because of the error "DataError: Expected input with amount".


There is a presentation of that operation: https://www.youtube.com/watch?v=40mdFIAEh4E&t=8376s
(jump to 2:48:27)
At which stage you have the problem?
legendary
Activity: 2268
Merit: 18771
Do you have the seed phrases backed up for the three parts of your multi-sig wallet? If you do, then I would think the easiest solution here would be to just create a brand new 2-of-3 multi-sig wallet in Electrum, and import the three seed phrases (remembering to select BIP39 for the two hardware wallet seed phrases). You can then sign a transaction from that single wallet without having to worry about compatibility issues with your two hardware wallets.

The downside to this is that you completely lose the security of your multi-sig wallet by importing all three seed phrases in to the same wallet. Therefore, you should only do this on a clean and airgapped computer.
HCP
legendary
Activity: 2086
Merit: 4363
The wallet is set up as a 2/3 multi-sig wallet, with #1 being Electrum, #2 being Trezor One, and #3 being Ledger Nano S.

When I try to sign a transaction with Electrum (and then sign + broadcast with Ledger Nano S), it won't work because Electrum won't detect the Ledger Nano S.

I am on Mac and using Electrum 3.3.8.
Does the Ledger Nano S work correctly if you use Ledger Live? If not, then maybe try following the MacOS troubleshooting here: https://support.ledger.com/hc/en-us/articles/115005165269-Fix-USB-connection-issues-with-Ledger-Live?support=true

If it normally works with Ledger Live OK, did you have Ledger Live open and running when trying to use Electrum? Often, having multiple applications that are attempting to communicate with the Ledger device at the same time will cause problems. I've had issues in the past with Electrum being unable to communicate with a Nano S if Ledger Live was running. So, make sure Ledger Live is not running before you start Electrum and see if that helps with the communication process between Electrum and the Nano S.


NOTE: I have a Ledger Nano S and a Trezor ONE, and am able to use both with an Electrum 4.1.5 MultiSig "OK"... but I'm running Windows 10.
legendary
Activity: 2618
Merit: 6452
Self-proclaimed Genius
(I tried updating to the most recent Electrum version, and it didn't work either. I think that's because according to the release notes, after 3.3.8 something changed with the Electrum partial transaction format - which I'm guessing applies to multi-sig transactions).
This only affects compatibility between the raw transactions exported by versions lower than 4.x and the newest.
So, it mainly affects Cold-Storage and MultiSig Electrum wallets that have different versions.

If you're using an outdated wallet for either 1 of the cosigners, update them all fist, then create the transaction.
legendary
Activity: 952
Merit: 1386

When I try to sign a transaction with Electrum (and then sign + broadcast with Trezor One), it won't work because of the error "DataError: Expected input with amount".
Hmm... Interesting. It appears that this is what it returns during an improper signing. Checking on github (#L134), there's a condition that isn't met (coin.force_bip143 or tx.overwintered).


There is also part (https://github.com/trezor/trezor-firmware/blob/master/legacy/firmware/signing.c):
Code:
if (!tx->inputs[0].has_amount) {
        fsm_sendFailure(FailureType_Failure_DataError,
                        _("Expected input with amount"));
        signing_abort();
        return;
      }

Is it possible that you selected several inputs and at least one of them is empty?


Also, as mentioned, I'm willing to pay $1k of BTC to whoever can help me fix this issue
We'll need more context to help you. I believe that it's easier to make Electrum detect your Ledger Nano S than the former, so let's focus on that.
I think so.

First at all - did you update firmware on both hardware wallets?

legendary
Activity: 1512
Merit: 7340
Farewell, Leo
Do not give any wallet files to any “helpful” users who'll reach you via PM. If their intention is to really help you, they'll talk with you in here.

When I try to sign a transaction with Electrum (and then sign + broadcast with Ledger Nano S), it won't work because Electrum won't detect the Ledger Nano S.
Why does that happen? When you made the setup, didn't it detect it?

When I try to sign a transaction with Electrum (and then sign + broadcast with Trezor One), it won't work because of the error "DataError: Expected input with amount".
Hmm... Interesting. It appears that this is what it returns during an improper signing. Checking on github (#L134), there's a condition that isn't met (coin.force_bip143 or tx.overwintered).

Also, as mentioned, I'm willing to pay $1k of BTC to whoever can help me fix this issue
We'll need more context to help you. I believe that it's easier to make Electrum detect your Ledger Nano S than the former, so let's focus on that.
legendary
Activity: 2212
Merit: 7064
I don't think this issue is related with Electrum wallet, and I suspect that Ledger or Trezor may cause this error because they are known to have bad multisig support,
on one of them you can't construct multisig or address can't be verified on this devices.
You can try contacting their slow support or write your issue on their reddit or github pages, and update all devices with latest firmware.
copper member
Activity: 2856
Merit: 3071
https://bit.ly/387FXHi lightning theory
Have you installed the firmware for your ledger nano s? Normally there's a driver or something you have to install to get it to work, ledger will likely have it on their website.

This link contain info on installing the ledger firmware: https://support.ledger.com/hc/en-us/articles/360002731113-Update-Ledger-Nano-S-firmware?docs=true
This is then the one for connecting the ledger to electrum (just in case you get a problem): https://support.ledger.com/hc/en-us/articles/115005161925-Set-up-and-use-Electrum?docs=true





When I try to sign a transaction with Electrum (and then sign + broadcast with Ledger Nano S), it won't work because Electrum won't detect the Ledger Nano S.

Which OS do you have? Newer than 10.14? Does Nano S works correctly with Ledger Live?

They did say they were using Mac.
legendary
Activity: 952
Merit: 1386

When I try to sign a transaction with Electrum (and then sign + broadcast with Ledger Nano S), it won't work because Electrum won't detect the Ledger Nano S.

Which OS version do you have? Newer than 10.14? Does Nano S works correctly with Ledger Live?
newbie
Activity: 7
Merit: 31
Hi there,

I have some BTC stuck in an Electrum multi-sig that I setup a couple of years ago.

The wallet is set up as a 2/3 multi-sig wallet, with #1 being Electrum, #2 being Trezor One, and #3 being Ledger Nano S.

When I try to sign a transaction with Electrum (and then sign + broadcast with Ledger Nano S), it won't work because Electrum won't detect the Ledger Nano S.

When I try to sign a transaction with Electrum (and then sign + broadcast with Trezor One), it won't work because of the error "DataError: Expected input with amount".

I am on Mac and using Electrum 3.3.8.

(I tried updating to the most recent Electrum version, and it didn't work either. I think that's because according to the release notes, after 3.3.8 something changed with the Electrum partial transaction format - which I'm guessing applies to multi-sig transactions).

^ Release notes (see under Release 4.0.1 - (July 3, 2020): https://github.com/spesmilo/electrum/blob/master/RELEASE-NOTES

Please let me know if there's any other information I could provide to fix this. I would be forever grateful to whoever can help.

Also, as mentioned, I'm willing to pay $1k of BTC to whoever can help me fix this issue

Thank you!
Jump to: