4
0
mirror of https://github.com/cwinfo/yggdrasil-go.git synced 2025-07-04 17:07:47 +00:00

Add FriendlyName option, show friendly name and real endpoint in admin socket/yggdrasilctl

This commit is contained in:
Neil Alexander
2018-10-21 17:57:48 +01:00
parent a9f72a6ee1
commit b809adf981
7 changed files with 67 additions and 40 deletions

View File

@ -287,7 +287,7 @@ func (iface *tcpInterface) handler(sock net.Conn, incoming bool) {
}()
// Note that multiple connections to the same node are allowed
// E.g. over different interfaces
p := iface.core.peers.newPeer(&info.box, &info.sig, getSharedKey(myLinkPriv, &meta.link))
p := iface.core.peers.newPeer(&info.box, &info.sig, getSharedKey(myLinkPriv, &meta.link), sock.RemoteAddr().String(), "(none)")
p.linkOut = make(chan []byte, 1)
in := func(bs []byte) {
p.handlePacket(bs)