From 033e7521c8d8085e6af18739accead2aa0545d60 Mon Sep 17 00:00:00 2001 From: Maisem Ali Date: Fri, 27 Jan 2023 16:01:27 -0800 Subject: [PATCH] ipn/ipnlocal: remove unused TestOnlyPublicKeys function #cleanup Signed-off-by: Maisem Ali --- ipn/ipnlocal/local.go | 18 ------------------ 1 file changed, 18 deletions(-) diff --git a/ipn/ipnlocal/local.go b/ipn/ipnlocal/local.go index e87f2365f..484485f36 100644 --- a/ipn/ipnlocal/local.go +++ b/ipn/ipnlocal/local.go @@ -3994,24 +3994,6 @@ func (b *LocalBackend) OperatorUserID() string { return u.Uid } -// TestOnlyPublicKeys returns the current machine and node public -// keys. Used in tests only to facilitate automated node authorization -// in the test harness. -func (b *LocalBackend) TestOnlyPublicKeys() (machineKey key.MachinePublic, nodeKey key.NodePublic) { - b.mu.Lock() - machinePrivKey := b.machinePrivKey - prefs := b.pm.CurrentPrefs() - b.mu.Unlock() - - if !prefs.Valid() || machinePrivKey.IsZero() { - return - } - - mk := machinePrivKey.Public() - nk := prefs.Persist().PublicNodeKey() - return mk, nk -} - func (b *LocalBackend) removeFileWaiter(handle set.Handle) { b.mu.Lock() defer b.mu.Unlock()