mirror of
https://github.com/tailscale/tailscale.git
synced 2025-06-28 11:08:40 +00:00
cmd/tailscale: add tlpub: prefix to lock log output
Updates tailscale/corp#23258 Signed-off-by: Kristoffer Dalby <kristoffer@tailscale.com>
This commit is contained in:
parent
b32a01b2dc
commit
4a7b8afabf
@ -623,7 +623,7 @@ func nlDescribeUpdate(update ipnstate.NetworkLockUpdate, color bool) (string, er
|
||||
printKey := func(key *tka.Key, prefix string) {
|
||||
fmt.Fprintf(&stanza, "%sType: %s\n", prefix, key.Kind.String())
|
||||
if keyID, err := key.ID(); err == nil {
|
||||
fmt.Fprintf(&stanza, "%sKeyID: %x\n", prefix, keyID)
|
||||
fmt.Fprintf(&stanza, "%sKeyID: tlpub:%x\n", prefix, keyID)
|
||||
} else {
|
||||
// Older versions of the client shouldn't explode when they encounter an
|
||||
// unknown key type.
|
||||
@ -645,10 +645,10 @@ func nlDescribeUpdate(update ipnstate.NetworkLockUpdate, color bool) (string, er
|
||||
case tka.AUMAddKey.String():
|
||||
printKey(aum.Key, "")
|
||||
case tka.AUMRemoveKey.String():
|
||||
fmt.Fprintf(&stanza, "KeyID: %x\n", aum.KeyID)
|
||||
fmt.Fprintf(&stanza, "KeyID: tlpub:%x\n", aum.KeyID)
|
||||
|
||||
case tka.AUMUpdateKey.String():
|
||||
fmt.Fprintf(&stanza, "KeyID: %x\n", aum.KeyID)
|
||||
fmt.Fprintf(&stanza, "KeyID: tlpub:%x\n", aum.KeyID)
|
||||
if aum.Votes != nil {
|
||||
fmt.Fprintf(&stanza, "Votes: %d\n", aum.Votes)
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user