From: Michael Snyder (msnyder@revolutioncomputer.com)
Date: Sat Feb 14 2004 - 01:59:04 GMT-3
Wanted to post a brief note. I've posted how to use the logic operators
to summarize anything that uses a wildcard or mask. In those posts I
never could figure out how to explain why it worked, or an easy way to
remember it. Of course logic works in any number base.
So, here's why it works, and how to remember it.
Mask logic
When you `and` a set of values, you get the most common element of the
values.
When you `or` a set of values you get the scope of the elements.
When you `xor` the common value, against the scope of the elements, you
get the offset of the two in wildcard format.
This works for any thing in access-list format. IP addresses, MAC
addresses, SAPS all come to mind.
--------------------------------------------------------------
If you need a mask, we all know that it's 255-wildcard equals mask per
octet.
I have step by step examples in my other posts.
Mainly take a set of octets, `and` them one at a time together, that's
your common element. (most often your network number)
Take the same set, `or` them together, that's the scope. (doesn't show
up directly in the final answer)
Common `xor` Scope = Offset (wildcard)
Michael Snyder
Lead Network Engineer
CCSP/DP, MCSE
Revolution Computer Systems
(270) 443-7400
This archive was generated by hypermail 2.1.4 : Fri Mar 05 2004 - 07:13:49 GMT-3