diff --git a/internal/client/index.go b/internal/client/index.go index c6a17cb3703..a7f36c482c7 100644 --- a/internal/client/index.go +++ b/internal/client/index.go @@ -192,6 +192,8 @@ func (ci *Index) Find(id string) (c *Persistent, ok bool) { // find finds persistent client by IP address. func (ci *Index) findByIP(ip netip.Addr) (c *Persistent, found bool) { + ip = ip.WithZone("") + uid, found := ci.ipToUID[ip] if found { return ci.uidToClient[uid], true diff --git a/internal/client/persistent.go b/internal/client/persistent.go index 06e346f4dfc..8345f41896a 100644 --- a/internal/client/persistent.go +++ b/internal/client/persistent.go @@ -161,7 +161,7 @@ func (c *Persistent) setID(id string) (err error) { var ip netip.Addr if ip, err = netip.ParseAddr(id); err == nil { - c.IPs = append(c.IPs, ip) + c.IPs = append(c.IPs, ip.WithZone("")) return nil }