|
Ran
|
Jobs
1
|
Files
1328
|
Run time
3min
|
Badge
README BADGES
|
push
github
feat(keys)!: introduce a new keystore v2 format and migrate from the current one while keeping a backup of the files (#7704) # Description of change * Introduce a new keystore v2 format. If a keystore v1 file (`iota.keystore` + `iota.aliases`) is found then they are automatically migrated while keeping a copy of the old data named as (`iota.keystore.migrated` + `iota.aliases.migrated`). ```json { "version": 2, "keys": [ { "alias": "xenodochial-amethyst", "address": "0x6a0e268bf793f1d9c21f7f8faee6f4b68", "key": { "type": "external", "value": { "source": "ledger", "derivation_path": "m/44'/4218'/0'/0'/0'", "public_key_base64": "AA2itppp6zFjp9f6onzcTSyDbp8KymT2gCpQAHj7KL+o" } } }, { "alias": "zealous-agates", "address": "0xaa0ebe1d294429ac738d69861dc9d49ce", "key": { "type": "external", "value": { "source": "some_kms", "public_key_base64": "AMkjtEDVFIxuAIbTTUHxCU0zVxujbL6A5ovdB/9rRxLz" } } }, { "alias": "condescending-jet", "address": "0xfeebd0a88da361c317a6f0419dee0a699", "key": { "type": "key_pair", "value": "iotaprivkey1qpkfvwk4re9hd04c900hy4d2h6qtyqks0j58gr877xs6668q6czg2vt6ysm" } } ] } ``` * The new keystore v2 supports adding keys from external sources, where only the public key is added to the store and an optional bip32 derivation path. This allows the CLI to store references to keys managed from e.g. Ledger hardware wallets. ## Links to any relevant issues Fixes #5849 ## How the change has been tested - [x] Basic tests (linting, compilation, formatting, unit/integration tests) - [ ] Patch-specific tests (correctness, functionality coverage) - [x] I have added tests that prove my fix is effective or that my feature works - [x] I have c... (continued)
294 of 373 new or added lines in 11 files covered. (78.82%)
178 existing lines in 20 files now uncovered.229092 of 349018 relevant lines covered (65.64%)
2326543.78 hits per line
| Lines | Coverage | ∆ | File |
|---|---|---|---|
| 61 |
83.44 |
-5.02% | crates/iota-keys/src/keystore.rs |
| 12 |
33.33 |
1.02% | crates/iota/src/keytool.rs |
| 2 |
61.22 |
-0.0% | crates/iota/src/client_commands.rs |
| 2 |
51.99 |
0.07% | crates/iota/src/validator_commands.rs |
| 1 |
0.0 |
0.0% | crates/iota-benchmark/src/util.rs |
| 1 |
0.0 |
0.0% | crates/iota-rpc-loadgen/src/main.rs |
| ID | Job ID | Ran | Files | Coverage | |
|---|---|---|---|---|---|
| 1 | nextest+simtest - 16281819432.1 | 1330 |
65.62 |
GitHub Action Run |
| Coverage | ∆ | File | Lines | Relevant | Covered | Missed | Hits/Line |
|---|