Skip to main content

cidr

Return the CIDR block as a string.


Examples

CIDR for an IPv4 address with mask:

ip("10.0.5.7/16").cidr

CIDR for an IPv6 network:

ip("2001:db8::1/48").cidr