mirror of
https://github.com/tailscale/tailscale.git
synced 2025-10-09 08:01:31 +00:00
wgengine/magicsock: change API to not permit disco key changes
Generate the disco key ourselves and give out the public half instead. Fixes #525
This commit is contained in:
@@ -361,9 +361,7 @@ func (b *LocalBackend) Start(opts Options) error {
|
||||
|
||||
var discoPublic tailcfg.DiscoKey
|
||||
if controlclient.Debug.Disco {
|
||||
discoPrivate := key.NewPrivate()
|
||||
b.e.SetDiscoPrivateKey(discoPrivate)
|
||||
discoPublic = tailcfg.DiscoKey(discoPrivate.Public())
|
||||
discoPublic = b.e.DiscoPublicKey()
|
||||
}
|
||||
|
||||
var err error
|
||||
|
Reference in New Issue
Block a user