1
0
Fork 0
mirror of https://github.com/anyproto/any-sync.git synced 2025-06-08 05:57:03 +09:00

remove priv keys from nodes conf

This commit is contained in:
Sergey Cherepanov 2023-02-23 16:55:10 +03:00 committed by Mikhail Iudin
parent 6eb84043f0
commit 92fb54a3e4
No known key found for this signature in database
GPG key ID: FAAAA8BAABDFF1C0
3 changed files with 22 additions and 16 deletions

View file

@ -62,18 +62,13 @@ func (s *AccountTestService) Account() *accountdata.AccountData {
}
func (s *AccountTestService) NodeConf(addrs []string) nodeconf.NodeConfig {
encSk, err := keys.EncodeKeyToString(s.acc.SignKey)
if err != nil {
panic(err)
}
encEk, err := keys.EncodeKeyToString(s.acc.EncKey)
encEk, err := keys.EncodeKeyToString(s.acc.EncKey.GetPublic())
if err != nil {
panic(err)
}
return nodeconf.NodeConfig{
PeerId: s.acc.PeerId,
Addresses: addrs,
SigningKey: encSk,
EncryptionKey: encEk,
Types: []nodeconf.NodeType{nodeconf.NodeTypeTree},
}