sparrowwallet / sparrow

Desktop Bitcoin Wallet focused on security and privacy. Free and open source.
https://sparrowwallet.com/
Apache License 2.0
1.28k stars 180 forks source link

Prevent Sparrow from showing combined transactions history and balance of two wallets #1447

Open stackingsaunter opened 2 months ago

stackingsaunter commented 2 months ago

I recently made a typo in my passphrase, didn't properly check the fingerprint, and entered a wallet.

I saw balance and transaction history of my wallet (with correct passphrase). So I thought everything is OK, copied receive address and sent bitcoin to that address. A few mins later I saw balance updated with the bitcoin I sent, and the transaction was pending at the top of the list.

A few minutes later the transaction disappeared and balance was lowered to the number before this transaction. Confused, I closed and opened Sparrow again, but couldn't find the transaction anymore. After opening Sparrow again, I of course entered passphrase correctly, so I entered another wallet.

Later I managed to get to the wallet with typo passphrase and get my funds back.

I understand labels are stored locally and can be displayed in a different wallet, but I can't understand why I've seen combined balance and transactions history of 2 different wallets (one from correct passphrase and one from typo)? That feels like a serious bug imho.

Is there a way to add some checks to prevent this? That would prevent lots of losses when users mistype passphrase and don't realize it.

craigraw commented 2 months ago

I can't understand why I've seen combined balance and transactions history of 2 different wallets

There are two processes that happened here - one was the long running process that loaded your most recent wallet history, discovered there were changes to every address, and refreshed the entire wallet. For a wallet of any size, loaded from a remote (maybe public) server, this may take some minutes to complete. The second process was sending from the wallet, which happens independently. Making these two processes dependant on each other would mean for example the wallet loading must complete before sending can take place, which would generally be a poorer user experience.

I am considering adding a dialog to warn the user when a complete wallet refresh is necessary, and a passphrase has been used.

Andrucoin commented 1 month ago

No meu caso fiz uma transação com a passphase correta, copie um endereço via qrcode com a carteira samurai offline,fiz a transaçao com o hex assinado e joquei na mempool space via tor para meu endereço.....a transaçao chegou e foi confirmada, não prestei muita atenção no endereço q chegou, era outro endereço so q tanto aparece o endereço q enviei como um outro onde foi os fundos. tipo 2 carteiras. Por um momento digitei a passfrase e vi a transação, fotografei a tela do computador e depois perdi novamente....Nunca mais consegui vê a transação....ja tentei varias variantes da minha passfrase.....mas não entendo como o endereço mudou no qrcode?????????????????????????????????????

Endereço q envie para receber Endereço para onde foi os fundos Hex na samurai.txt