From 3a8cb6a40ead3ee48a12e2838c8e7091879d679a Mon Sep 17 00:00:00 2001 From: Abhishek Kondur Date: Fri, 16 Sep 2022 11:48:55 +0530 Subject: [PATCH] avoid generating certs for broker on pull --- netclient/command/commands.go | 21 --------------------- 1 file changed, 21 deletions(-) diff --git a/netclient/command/commands.go b/netclient/command/commands.go index 4f081bda..f0d3700b 100644 --- a/netclient/command/commands.go +++ b/netclient/command/commands.go @@ -90,29 +90,8 @@ func Pull(cfg *config.ClientConfig) error { currentServers[currCfg.Server.Server] = *currCfg } - // //generate new client key if one doesn' exist - // var private *ed25519.PrivateKey - // private, err = tls.ReadKeyFromFile(ncutils.GetNetclientPath() + ncutils.GetSeparator() + "client.key") - // if err != nil { - // _, newKey, err := ed25519.GenerateKey(rand.Reader) - // if err != nil { - // return err - // } - // if err := tls.SaveKeyToFile(ncutils.GetNetclientPath(), ncutils.GetSeparator()+"client.key", newKey); err != nil { - // return err - // } - // private = &newKey - // } - // // re-register with server -- get new certs for broker - // for _, clientCfg := range currentServers { - // if err = functions.RegisterWithServer(private, &clientCfg); err != nil { - // logger.Log(0, "registration error", err.Error()) - // } else { daemon.Restart() - // } - // } logger.Log(1, "reset network", cfg.Network, "and peer configs") - return err }