From 73e99fa59072672cd2eab69eaf30e62679cc2a20 Mon Sep 17 00:00:00 2001 From: Leonard Lyubich Date: Thu, 14 Jan 2021 10:48:59 +0300 Subject: [PATCH] [#306] cmd/node: Rename permitted_keys config value to authorized_keys Signed-off-by: Leonard Lyubich --- cmd/neofs-node/config.go | 2 +- cmd/neofs-node/control.go | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/cmd/neofs-node/config.go b/cmd/neofs-node/config.go index 19f5f741a..ec4660898 100644 --- a/cmd/neofs-node/config.go +++ b/cmd/neofs-node/config.go @@ -424,7 +424,7 @@ func defaultConfiguration(v *viper.Viper) { v.SetDefault(cfgObjectRangePoolSize, 10) v.SetDefault(cfgObjectRangeHashPoolSize, 10) - v.SetDefault(cfgCtrlSvcAllowedKeys, []string{}) + v.SetDefault(cfgCtrlSvcAuthorizedKeys, []string{}) } func (c *cfg) LocalAddress() *network.Address { diff --git a/cmd/neofs-node/control.go b/cmd/neofs-node/control.go index 42fae8d4e..db1447a01 100644 --- a/cmd/neofs-node/control.go +++ b/cmd/neofs-node/control.go @@ -15,14 +15,14 @@ import ( const ( cfgCtrlSvcSection = "control" - cfgCtrlSvcAllowedKeys = cfgCtrlSvcSection + ".permitted_keys" + cfgCtrlSvcAuthorizedKeys = cfgCtrlSvcSection + ".authorized_keys" cfgCtrlSvcGRPCSection = cfgCtrlSvcSection + ".grpc" cfgCtrlGRPCEndpoint = cfgCtrlSvcGRPCSection + ".endpoint" ) func initControlService(c *cfg) { - strKeys := c.viper.GetStringSlice(cfgCtrlSvcAllowedKeys) + strKeys := c.viper.GetStringSlice(cfgCtrlSvcAuthorizedKeys) keys := make([][]byte, 0, len(strKeys)+1) // +1 for node key keys = append(keys, crypto.MarshalPublicKey(&c.key.PublicKey))