The new
Electrum Bitcoin client uses a deterministic wallet. This allows users to recover their complete list of addresses and transaction history from a secret seed. (except for labels, which are not stored in the blockchain)
For the moment this feature allows users to restore their wallet in case of loss, or to easily transport their wallet on another machine. However, it does not automatically synchronize a wallet that is being used on two different machines. I would like to add this functionality. This would very much ressemble "cloud" services.
The idea, of course, is to use the blockchain as the only source of information; we do not want users to be tied to a third-party storage.
In order to achieve this, the client needs to watch the next addresses that are going to be used in its deterministic sequence. The Electrum wallet actually uses two distinct sequences: one for receiving addresses, one for change addresses. The sequence of receiving addresses might contain gaps (unused addresses), and the maximal size of these gaps is a parameter set by the user. The sequence of change addresses does not have gaps.
The problem of synchronization between two wallets is the following: If bitcoins are received at one of the addresses that are at the end of the current sequence, then the client needs to extend that sequence, in order to know whether the next addresses have been involved in transactions. For this, the client needs to generate new private keys, and therefore it needs the user's password.
So, we are left with the following dilemma: should the client pre-generate the next 100 addresses of its sequence and store them, or should it occasionally ask the user for his password when the wallet
receives some bitcoins? both solutions seem awkward to me. Is there a third solution?
UPDATE: this question has been answered below. Version 0.34 of Electrum implements a "type 2" wallet and multiple instances of the same wallets are synchronized automatically.