MCPcopy Create free account
hub / github.com/tailscale/tailcat / IsMeowPacket

Function IsMeowPacket

disco.go:26–28  ·  view source on GitHub ↗

IsMeowPacket reports whether pkt starts with the meow magic prefix.

(pkt []byte)

Source from the content-addressed store, hash-verified

24
25// IsMeowPacket reports whether pkt starts with the meow magic prefix.
26func IsMeowPacket(pkt []byte) bool {
27 return len(pkt) >= 4 && [4]byte(pkt[:4]) == meowMagic
28}
29
30// EncodeMeowPing encodes a meow ping packet containing the sender's
31// node public key and disco public key.

Callers 2

StartMethod · 0.85
initLockedMethod · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected