|
|
@@ -265,9 +265,9 @@ CheckIPs:
|
|
|
// Check if allowed location IPs intersect with the allowed IPs.
|
|
|
// If the allowed location IP fully contains an allowed IP, that's fine -
|
|
|
// the more specific route will be used. Only warn if it's a partial overlap
|
|
|
- // or if the allowed IP contains the allowed location IP.
|
|
|
+ // where the allowed IP contains the allowed location IP.
|
|
|
for _, i := range s.allowedIPs {
|
|
|
- if intersect(ip, i) && !ip.Contains(i.IP) {
|
|
|
+ if i.Contains(ip.IP) && !ip.Contains(i.IP) {
|
|
|
_ = level.Warn(t.logger).Log("msg", "overlapping allowed location IPnet with allowed IPnets", "IP", ip.String(), "IP2", i.String(), "segment-location", s.location)
|
|
|
continue CheckIPs
|
|
|
}
|