Update for 14th Sept 2018
So we had our first practice hard-fork on T3, which was simply a test that changed a few header fields around. Other than a small mining hiccup, it all seems to have gone well.
All the required work for the upcoming Testnet4 is next, which involves updates, fixes and changes for aggsig, bulletproofs, wallet BIP32 support and dual POW. Because of the way libsecp is structured and tagged, we’re likely going to end up with a couple of massive Franken-PRs that we’ll merge into a test T4 branch shortly before we launch it. Most of my work this week has been on just such a PR at https://github.com/mimblewimble/grin/pull/1501, which I’ll explain in a moment.
As I’ve mentioned before My main focus right now is getting BIP32 support into the wallet, which from an end-user perspective means that instead of having a single wallet with a single key derivation path, a wallet will be able to support multiple ‘accounts’ in a branching tree structure. So that involved:
-
libsecp256k work, mostly to support the migration of wallet key derivation from our existing setup to BIP 32. Most notably, I’ve inserted an optional 16 bytes worth of message into to a bullet proof. This will allow wallet restore from a seed by inserting and restoring BIP32 derivation paths into the bullet proof, (an impossiblity otherwise, as there would have been too many key paths to grind through to try to find the right key derivation index during a wallet restore.) This will also solve a long-standing annoyance in wallet restore. Since the key index is stored the wallet restore no longer has to try and find the right derivation for each output it identifies in the UTXO set, which will greatly reduce the amount of time it takes to restore a wallet.
-
The main PR integrating this into Grin, building on last week’s work merging in the BIP32 code from rust-bitcoin. This is all mostly working now with tests exercising multiple accounts in a wallet, and I’ll soon be adding a ‘–account’ flag to the wallet command line as well as an ‘account create’ command of some description (which just stores a map of labels to BIP32 paths). This is going to end up including all of the latest libsecp changes as well as I need to update the linked libsecp version to support bulletproof messages as described above. But that’s also going to include the aggsig changes to support atomic swaps, and other bulletproof changes to support multi-party proofs. So we’ll probably end up with 2 large PRs to merge for T4, this one and one that includes the planned dual-PoW work.
Next couple of days are going to be about, (roughly):
- updating grin to work with the newest version of our libsecp256k library (the interfaces will have changed, and the aggsig signature message needs to change)
- integrating BIP32 identifiers into the bulletproof message in grin
- fixing/updating wallet restore to use these identifiers
- Updating the command-line wallet commands to handle multiple accounts
- merging some preliminary BIP39 work @mcdallas (though will probably wait until after T4 to integrate this into the user experience)
And then I’ll pile onto the needed updates to grin/cuckoo-miner for the dual PoW changes, depending on where we are when I’m done with BIP32 changes.
And that’s just me. The amount of work being done on Grin seems to be accelerating, and there’s plenty on everyone’s plate for the foreseeable future.
Have a good weekend, and to everyone working on Grin: Remember to have a weekend.