There is no validation on wallet name while importing new wallets from *.json file
See original GitHub issueWallet version or commit SHA:
design-v2
branch (b2519ef)
Environment: MacBook Pro (13-inch, 2017), macOS Mojave 10.14
Reproduction steps:
- Create a new wallet named “test”
- Login to newly created wallet
- Click on “Settings” button in the left menu
- Click on “Export” button and save *.json file anywhere
- Close your Neon wallet and clear it’s app data (fresh Neon wallet installation)
- Start Neon wallet
- Create a new wallet named “test”
- Login to newly created wallet
- Click on “Settings” button in the left menu
- Click on “Import” button and choose previously saved *.json file
- Logout from current wallet
- Click on drop-down with saved wallet => you can see 2x “test”, both of them will login you to the wallet which was created as 1st
Description: If you have a saved wallet named “test” and then you import a *.json file with another wallet which has exactly the same name (“test”) - you will end up having 2x “test” wallet in the app. You’re able to login only to first wallet created (saved wallet in this case), doesn’t matter which “test” wallet you’re going to choose from drop-down list (1st “test” or 2nd “test”) - it will always log you in to the 1st one.
Screenshots/Video: Video is taken from 6th reproduction step (after saving *.json file with a wallet named “test”): https://i.imgur.com/h3LEgkq.gifv
Issue Analytics
- State:
- Created 5 years ago
- Comments:5 (2 by maintainers)
Top Results From Across the Web
bitcoinlib.wallets module
Generate masterkey or import key when specified. When only a name is specified a legacy Wallet with a single masterkey is created with...
Read more >"JSON data is not expected" when trying to import crypto ...
The error message "JSON data is not expected" pops up when the user is trying to import crypto wallets into Brave Wallet.
Read more >How do I import an existing wallet? - AlphaWallet
How do I import an existing wallet? Click Settings, then click Change / Add Wallet, then click Add(on top right corner), then click...
Read more >Wallet Developer Guide: Pass Design and Creation
At the center of the pass is a JSON file named pass.json , which ... In addition to the pass type identifier and...
Read more >5. Transactions - Mastering Bitcoin [Book] - O'Reilly
In effect, there is no such thing as a stored balance of a bitcoin address or ... get unspent outputs from blockchain API...
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
@ranbena @evgenyboxer This seems to be partially solved. Currently (after recent changes), if you try to import a *.json file which contains a wallet with the same name as one of the saved wallets, you will get following error:
I think that it’s quite unclear in situation if you’re trying to import a file with more than 1 wallet (for example 5 wallets in *.json file). You will end up having no idea which wallet blocks the import. It would be good to show names of the wallets that are blocking the import, so user is aware which wallet names to change. What do you think?
Looks good now, thanks 👍.