MCPcopy Create free account
hub / github.com/encodeous/nylon / LookupPeer

Method LookupPeer

polyamide/device/device.go:349–354  ·  view source on GitHub ↗
(pk NoisePublicKey)

Source from the content-addressed store, hash-verified

347}
348
349func (device *Device) LookupPeer(pk NoisePublicKey) *Peer {
350 device.peers.RLock()
351 defer device.peers.RUnlock()
352
353 return device.peers.keyMap[pk]
354}
355
356func (device *Device) GetPeers() []*Peer {
357 device.peers.RLock()

Callers 8

handlePublicKeyLineMethod · 0.95
hasWGPeerFunction · 0.80
TableInsertRouteMethod · 0.80
flushIOMethod · 0.80
SyncWireGuardMethod · 0.80
ProbeMethod · 0.80

Implementers 4

NativeTunpolyamide/tun/tun_linux.go
netTunpolyamide/tun/netstack/tun.go
chTunpolyamide/tun/tuntest/tuntest.go
fakeTUNDeviceSizedpolyamide/device/device_test.go

Calls

no outgoing calls

Tested by 1

hasWGPeerFunction · 0.64