Skip to content

Commit

Permalink
fix(wallet): ensure that identity sig is stored on startup (#3951)
Browse files Browse the repository at this point in the history
Description
---
- adds code to store the identity signature

Motivation and Context
---
Whenever the node address changes, the identity signature is resigned for the new address. This identity signature should be preserved and reloaded later.

Ref #3950 

How Has This Been Tested?
---
Manually: Checking that identity signature is stored and doesnt change between reboots
  • Loading branch information
sdbondi committed Mar 23, 2022
1 parent 87b46b1 commit b8d08ed
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions base_layer/wallet/src/wallet.rs
Original file line number Diff line number Diff line change
Expand Up @@ -266,6 +266,9 @@ where
wallet_database
.set_node_features(comms.node_identity().features())
.await?;
if let Some(identity_sig) = comms.node_identity().identity_signature_read().as_ref().cloned() {
wallet_database.set_comms_identity_signature(identity_sig).await?;
}

Ok(Self {
network: config.network,
Expand Down

0 comments on commit b8d08ed

Please sign in to comment.