IP Address: | 205.215.175.94 | 11001101.11010111.10101111.01011110 |
---|---|---|
Subnet Mask: | 240.0.0.0 | 11110000.00000000.00000000.00000000 |
Wildcard Mask: | 15.255.255.255 | 00001111.11111111.11111111.11111111 |
Network Address: | 192.0.0.0/4 | 11000000.00000000.00000000.00000000 (Class C) |
Broadcast Address: | 207.255.255.255 | 11001111.11111111.11111111.11111111 |
First Host: | 192.0.0.1 | 11000000.00000000.00000000.00000001 |
Last Host: | 207.255.255.254 | 11001111.11111111.11111111.11111110 |
Row 1: Network 10.0.0.0 / 255.255.255.0
Row 2: Network 10.0.0.0 / 255.255.0.0
Row 3: Network 10.0.0.0 / 255.0.0.0
Then, when a packet comes in, destined to, say, 10.10.10.10, the router will start at the top of the routing table, performing a bitwise AND between the destination IP and the netmask of the route in that table row.
Key = SubnetId = IP & Mask;
No comments:
Post a Comment