#cidr #calculator #routes #table #wireguard #subtraction #metrics

bin+lib cidr-calculator

CIDR addition / subtraction calculator. Maybe useful for setting route tables when metrics are not available (e.g. wireguard next-hop)

2 unstable releases

0.2.0 Feb 7, 2024
0.1.0 Jan 20, 2024

#5 in #subtraction

MIT license

27KB
701 lines

CIDR Calculator

Crates.io Version

CIDR addition / subtraction calculator. Maybe useful for setting route tables when metrics are not available (e.g. wireguard next-hop)

> let univ = ::/0
> univ - 2001:da8::/56
[
        ::/3
        2000::/16
        2001::/21
        2001:800::/22
        2001:c00::/24
        2001:d00::/25
        2001:d80::/27
        2001:da0::/29
        2001:da8:0:100::/56
        ...

Dependencies

~3–5MB
~97K SLoC