The Mask calculator

(This document is still under construction)

What is calcmask?

Calcmask convert between Cisco wildcards, CIDR notation and the long form of netmasks.

This is best explained by examples, so here goes:

root@oasis:~# mask cidr 18
CIDR mask: 18
Cisco wildcard:
root@oasis:~# mask netmask
CIDR mask: 14
Cisco wildcard:
root@oasis:~# mask wildcard
CIDR mask: 29
Cisco wildcard:

It will also do all validation checks for you, so if you enter an invalid mask, it will tell you what is wrong with it. Very useful if you want to learn how it works.

Here is an example of an invalid netmask:

root@oasis:~# mask netmask
invalid netmask ( doesn't convert to a bitmask of form 111... ...000)

I want it!

Calcmask is hosted on Sourceforge, so the latest version can always be downloaded the usual way:

There is a source tarball and debian package for the i386 platform. If enough people bug me about it I might release a binary tarball and/or Redhat rpm package, but I'm not really in the mood for that (:

Other stuff that might interest you!

If you like this program, you might be interested in the other isp utilities I've written. They can all be found here.

I have also written many other programs and scripts which might be of some use to you. They can all be found on my home page.

To comment on this page or the material presented here, drop me an email. My address is spam please.

Last updated: Thu Nov 22 13:43:57 2000