Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Refactor/polish of the wallet wizard.
- Loading branch information
1 parent
784e9c9
commit 71a039d
Showing
17 changed files
with
1,025 additions
and
701 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,108 @@ | ||
<h2>Choosing a wallet</h2> | ||
<p> | ||
This page allows you to either create a new wallet or select an existing wallet to load. | ||
If you want to create a new wallet, click on the button provided for that purpose. Otherwise, | ||
if you want to select an existing wallet there are a range of ways you can do this. | ||
|
||
<ul> | ||
<li>If the wallet you want to select is one of those that were most recently opened, you | ||
can locate it in the list of recently opened wallets and either double-click on it | ||
or click on the button provided to open a selected wallet.</li> | ||
<li>If the wallet you want to select is not in the list of recently opened wallets, you | ||
can click on the button provided to open another wallet.</li> | ||
</ul> | ||
</p> | ||
<h3>Creating a new wallet</h3> | ||
<p> | ||
On choosing to create a new wallet, you will be first asked to select where it will be located | ||
and what it will be called. After doing so, you will then be asked to provide a password for | ||
the wallet — while in the past it was possible to have a wallet without a password, this | ||
is no longer supported. Finally, the new and empty wallet will be created and this wizard will | ||
close and the wallet user interface opened. | ||
</p> | ||
<p> | ||
New wallets require their user to create an initial account before they can be used. For now, | ||
a wallet can only have one account, but when the wallet user interface has been redesigned | ||
to support multiple accounts this restriction will be removed. | ||
</p> | ||
<h3>Selecting an existing wallet</h3> | ||
<p> | ||
Whichever method you use to select an existing wallet, depending on what that wallet is, | ||
there are several things that might happen. If the wallet storage is the latest one required | ||
by this version of ElectrumSV, then it will be opened. If it is an older storage format, then | ||
it required going through a migration process to update it, before it can open. | ||
</p> | ||
<h4>Wallet storage formats</h4> | ||
<p> | ||
As of ElectrumSV 1.3.0, the wallet storage has changed from a JSON file to a database file. | ||
There are numerous reasons for this change that will not be documented here. Versions 1.2.5 | ||
and earlier use a JSON file. Versions 1.3.0 and above use a database file. | ||
</p> | ||
<p> | ||
There are three different ways in which a wallet in the older JSON format might work: | ||
|
||
<ol> | ||
<li><b>Unpassworded:</b> The saved wallet file was just the direct text of the JSON format. | ||
Anyone could open the file in a text editor and see not only the private keys, but | ||
also any seed words for that wallet.</li> | ||
<li><b>Password with key encryption:</b> The saved wallet file was the direct text of the | ||
JSON format. However the most critical data like private keys and seed words was | ||
encrypted with the password.</li> | ||
<li><b>Password with file encryption:</b> The saved wallet file was completely encrypted | ||
with the password. In addition to this, critical data was also encrypted according | ||
in the same way as basic passworded wallets. | ||
</li> | ||
</ol> | ||
</p> | ||
<h4>Migration</h4> | ||
<p> | ||
The specific subject of wallet migration is not covered in this document, you can read about | ||
that if you are on the wallet migration wizard step. However, what the wallet selection process | ||
will ask you to do before proceeding to that step, depends on your wallet's format. | ||
</p> | ||
<p> | ||
Unpassworded JSON wallets will require the user to provide a password, before migration is | ||
attempted. The password will be used to encrypt keys in the database, that were not previously | ||
encrypted in the original JSON wallet. Passworded wallets will require the user to provide the | ||
JSON wallet's existing password. | ||
</p> | ||
<h3>Wallet encryption</h3> | ||
<p> | ||
The naive way the wallets were stored using JSON was problematic, but because it was naive | ||
it allowed a simple encryption of the entire wallet file as part of the process of writing | ||
all the wallet data to disk. As long as no-one really used their wallets much, and they didn't | ||
create many transactions this was fine and it was workable. | ||
</p> | ||
<p> | ||
With Bitcoin SV, a user may decide to store all their data on-chain. To continue to use the | ||
JSON files, would mean that potentially gigabytes if not terabytes of data would need to be | ||
loaded and decrypted every time the wallet was used. And it would all need to be encrypted and | ||
saved every time the wallet was exited. | ||
</p> | ||
<p> | ||
For now the new database wallet files use key encryption. This is where only critical private | ||
key-related data like actual private keys or seed words, are encrypted in the database. | ||
We did prototype full privacy, but it complicated things to the point where it was unlikely | ||
we would ever make a release. So we stepped back and did what was feasible. | ||
</p> | ||
<h4>Privacy</h4> | ||
<p> | ||
One concern about there no longer a way for wallets to have full encryption of all data, | ||
is that the balance, transactions and other data can be viewed if someone has access to | ||
your computer. However, if someone has access to your computer this is of less concern | ||
than their ability to run software that may extract your private keys when you access them | ||
— something that can be done regardless of full on-disk encryption of a wallet! | ||
</p> | ||
<p> | ||
If a user really wants full privacy, and full on-disk encryption of their wallet they have | ||
two options. | ||
|
||
<ul> | ||
<li>They can work with us and write support for it and we can merge their implementation | ||
in for all users.</li> | ||
<li>They can decrypt their wallet database before they load it, and encrypt it after they | ||
have finished with it. This could be done manually each time, within a script that | ||
automates wallet loading or implicitly done with full encryption of the disk the wallet | ||
is stored on.</li> | ||
</ul> | ||
</p> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,65 @@ | ||
<h2>Wallet migration</h2> | ||
<p> | ||
There are two situations where a wallet needs to be migrated. Older JSON wallets are migrated | ||
to the latest database format. And more recent database wallets are also migrated to the latest | ||
format when necessary. | ||
</p> | ||
<p> | ||
If your wallet migrated successfully, just click the finish button and this wizard will close | ||
and your wallet will open. | ||
</p> | ||
<h3>Backups</h3> | ||
<p> | ||
All wallet migrations back up the wallet within the same directory the original wallet | ||
file is located. The process can be illustrated as follows: | ||
<ol> | ||
<li>A user opens a wallet named <code>mywallet</code>.</li> | ||
<li>The migration process will rename <code>mywallet</code> to | ||
<code>mywallet.backup.1</code>. If that file name is already in use, then it will | ||
increase the number at the end. It will try and use <code>mywallet.backup.2</code>, | ||
and if that fails it will try <code>mywallet.backup.3</code> and so on.</li> | ||
<li>The migration process will create the migrated wallet as | ||
<code>mywallet.sqlite</code></li> | ||
</ol> | ||
</p> | ||
<h3>Migration problems</h3> | ||
<p> | ||
For the most part, there will not be any problems encountered when migrating your wallet. | ||
But some wallets will fail to migrate, and if that happens to you, you should be able to | ||
use the information below to aid you in discovering why or what to do in this situation. | ||
</p> | ||
<h4>Why did it fail?</h4> | ||
<p> | ||
There is only one identified situation where wallet migration fails. This is where the wallet | ||
data is incomplete, and the migration process cannot link it together and finds that data it | ||
needs is missing. | ||
</p> | ||
<h4>What can I do?</h4> | ||
<p> | ||
Open the wallet using ElectrumSV 1.2.5 and wait for it to synchronize. Make sure it connected | ||
to the network to do so, and that it is fully up-to-date. In order to maintain sane wallet | ||
file names you may want to: | ||
<ol> | ||
<li>Delete the failed <code>.sqlite</code> migrated wallet.</li> | ||
<li>Rename the <code>.backup.1</code> file to it's original name.</li> | ||
</ol> | ||
To understand the cause of the naming, it may help to read the backup section above. | ||
</p> | ||
<p> | ||
Otherwise, please follow these steps: | ||
<ol> | ||
<li>Open a DOS window, shell or terminal depending on your operating system.</li> | ||
<li>Run ElectrumSV from the command-line with the extra argument <code>-v=debug</code>. For | ||
example:<br/><br/> | ||
MacOS: <code>/Applications/ElectrumSV.app/Contents/MacOS/1.3.0 -v=debug</code><br/> | ||
Windows: <code>ElectrumSV-1.3.0.exe -v=debug</code><br/> | ||
This should output debugging information which will be useful for whomever attempts | ||
to fix the problem. | ||
</li> | ||
<li>Find the original wallet file, or the backup the failed migration process created, | ||
and open it. It should fail migration again.</li> | ||
<li>Exit ElectrumSV, and then copy the output which should also include an error.</li> | ||
<li><a href="https://github.com/electrumsv/electrumsv/issues">Submit an issue</a> providing | ||
both that output and as much information as possible.</li> | ||
</ol> | ||
</p> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,13 @@ | ||
<p> | ||
Changes included in this version of ElectrumSV are documented in a more readable | ||
form within the following article: <a href="https://medium.com/@roger.taylor/electrumsv-1-3-0b3-multisig-51b97311caae">ElectrumSV 1.3.0</a> | ||
</p> | ||
<p> | ||
The most prominent changes are also summarised below for convenience, if you wish to read more | ||
about any given change, please read the linked article. | ||
<ul> | ||
<li>The wallet storage has changed from a JSON file to an Sqlite database.</li> | ||
<li>A wallet can now have multiple accounts, although they are currently limited to having | ||
only one account until the user interface is reworked to support more than that.</li> | ||
</ul> | ||
</p> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.