Search Options

Results per page
Sort
Preferred Languages
Advance

Results 1 - 2 of 2 for IsZeroCIDR (0.09 sec)

  1. pkg/proxy/util/utils.go

    // isValidEndpoint checks that the given host / port pair are valid endpoint
    func isValidEndpoint(host string, port int) bool {
    	return host != "" && port > 0
    }
    
    // IsZeroCIDR checks whether the input CIDR string is either
    // the IPv4 or IPv6 zero CIDR
    func IsZeroCIDR(cidr string) bool {
    	if cidr == IPv4ZeroCIDR || cidr == IPv6ZeroCIDR {
    		return true
    	}
    	return false
    }
    
    Registered: Sat Jun 15 01:39:40 UTC 2024
    - Last Modified: Mon May 20 11:57:43 UTC 2024
    - 7.4K bytes
    - Viewed (0)
  2. pkg/proxy/util/nodeport_addresses.go

    		_, cidr, _ := netutils.ParseCIDRSloppy(str)
    
    		if netutils.IsIPv4CIDR(cidr) {
    			if cidr.IP.IsLoopback() || cidr.Contains(ipv4LoopbackStart) {
    				npa.containsIPv4Loopback = true
    			}
    		}
    
    		if IsZeroCIDR(str) {
    			// Ignore everything else
    			npa.cidrs = []*net.IPNet{cidr}
    			npa.matchAll = true
    			break
    		}
    
    		npa.cidrs = append(npa.cidrs, cidr)
    	}
    
    	return npa
    }
    
    Registered: Sat Jun 15 01:39:40 UTC 2024
    - Last Modified: Thu Apr 18 13:25:06 UTC 2024
    - 3.6K bytes
    - Viewed (0)
Back to top