Skip to content

Instantly share code, notes, and snippets.

Embed
What would you like to do?
Networking Stuff
Legend:
IPv4/CIDR = Starting IPv4 - Ending IPv4 | Number of IP addresses (Binary Formatting of Subnet) - Subnet Address
0.0.0.0/32 = 0.0.0.0 - 0.0.0.0 | 1 address (11111111 11111111 11111111 11111111) - 255.255.255.255
0.0.0.0/31 = 0.0.0.0 - 0.0.0.1 | 2 addresses (11111111 11111111 11111111 11111110) - 255.255.255.254
0.0.0.0/30 = 0.0.0.0 - 0.0.0.3 | 4 addresses (11111111 11111111 11111111 11111100) - 255.255.255.252
0.0.0.0/29 = 0.0.0.0 - 0.0.0.7 | 8 addresses (11111111 11111111 11111111 11111000) - 255.255.255.248
0.0.0.0/28 = 0.0.0.0 - 0.0.0.15 | 16 addresses (11111111 11111111 11111111 11110000) - 255.255.255.240
0.0.0.0/27 = 0.0.0.0 - 0.0.0.31 | 32 addresses (11111111 11111111 11111111 11100000) - 255.255.255.224
0.0.0.0/26 = 0.0.0.0 - 0.0.0.63 | 64 addresses (11111111 11111111 11111111 11000000) - 255.255.255.192
0.0.0.0/25 = 0.0.0.0 - 0.0.0.127 | 128 addresses (11111111 11111111 11111111 10000000) - 255.255.255.128
0.0.0.0/24 = 0.0.0.0 - 0.0.0.255 | 256 addresses (11111111 11111111 11111111 00000000) - 255.255.255.0
0.0.0.0/23 = 0.0.0.0 - 0.0.1.255 | 512 addresses (11111111 11111111 11111110 00000000) - 255.255.254.0
0.0.0.0/22 = 0.0.0.0 - 0.0.3.255 | 1024 addresses (11111111 11111111 11111100 00000000) - 255.255.252.0
0.0.0.0/21 = 0.0.0.0 - 0.0.7.255 | 2048 addresses (11111111 11111111 11111000 00000000) - 255.255.248.0
0.0.0.0/20 = 0.0.0.0 - 0.0.15.255 | 4096 addresses (11111111 11111111 11110000 00000000) - 255.255.240.0
0.0.0.0/19 = 0.0.0.0 - 0.0.31.255 | 8192 addresses (11111111 11111111 11100000 00000000) - 255.255.224.0
0.0.0.0/18 = 0.0.0.0 - 0.0.63.255 | 16384 addresses (11111111 11111111 11000000 00000000) - 255.255.192.0
0.0.0.0/17 = 0.0.0.0 - 0.0.127.255 | 32768 addresses (11111111 11111111 10000000 00000000) - 255.255.128.0
0.0.0.0/16 = 0.0.0.0 - 0.0.255.255 | 65536 addresses (11111111 11111111 00000000 00000000) - 255.255.0.0
0.0.0.0/15 = 0.0.0.0 - 0.1.255.255 | 131072 addresses (11111111 11111110 00000000 00000000) - 255.254.0.0
0.0.0.0/14 = 0.0.0.0 - 0.3.255.255 | 262144 addresses (11111111 11111100 00000000 00000000) - 255.252.0.0
0.0.0.0/13 = 0.0.0.0 - 0.7.255.255 | 524288 addresses (11111111 11111000 00000000 00000000) - 255.248.0.0
0.0.0.0/12 = 0.0.0.0 - 0.15.255.255 | 1048576 addresses (11111111 11110000 00000000 00000000) - 255.240.0.0
0.0.0.0/11 = 0.0.0.0 - 0.31.255.255 | 2097152 addresses (11111111 11100000 00000000 00000000) - 255.224.0.0
0.0.0.0/10 = 0.0.0.0 - 0.63.255.255 | 4194304 addresses (11111111 11000000 00000000 00000000) - 255.192.0.0
0.0.0.0/9 = 0.0.0.0 - 0.127.255.255 | 8388608 addresses (11111111 10000000 00000000 00000000) - 255.128.0.0
0.0.0.0/8 = 0.0.0.0 - 0.255.255.255 | 16777216 addresses (11111111 00000000 00000000 00000000) - 255.0.0.0
0.0.0.0/7 = 0.0.0.0 - 1.255.255.255 | 33554432 addresses (11111110 00000000 00000000 00000000) - 254.0.0.0
0.0.0.0/6 = 0.0.0.0 - 3.255.255.255 | 67108864 addresses (11111100 00000000 00000000 00000000) - 252.0.0.0
0.0.0.0/5 = 0.0.0.0 - 7.255.255.255 | 134217728 addresses (11111000 00000000 00000000 00000000) - 248.0.0.0
0.0.0.0/4 = 0.0.0.0 - 15.255.255.255 | 268435456 addresses (11110000 00000000 00000000 00000000) - 240.0.0.0
0.0.0.0/3 = 0.0.0.0 - 31.255.255.255 | 536870912 addresses (11100000 00000000 00000000 00000000) - 224.0.0.0
0.0.0.0/2 = 0.0.0.0 - 63.255.255.255 | 1073741824 addresses (11000000 00000000 00000000 00000000) - 192.0.0.0
0.0.0.0/1 = 0.0.0.0 - 127.255.255.255 | 2147483648 addresses (10000000 00000000 00000000 00000000) - 128.0.0.0
0.0.0.0/0 = 0.0.0.0 - 255.255.255.255 | 4294967296 addresses (00000000 00000000 00000000 00000000) - 0.0.0.0

What is IPv4?

Internet Protocol version 4 (IPv4) is a 32-bit digital address used to assist with the routing of packets in a network.

You can think of an IP address as you would a street address. Here's a quick example of a local network address setup:

10.11.0.0/16 gives us a total of 65,536 addresses (only 65,534 are usable, 10.11.0.0 and 10.11.255.255 are reserved)

Let's say we have 3 classrooms, the computers that are for non-faculty use will route their traffic through the
 faculty computer which will be connected to a managed switch. This switch is where the 3 classrooms traffic
 meets to be routed to and from the internet.
 
Classroom 1 can use 10.11.1.0/24 for a total of 256 addresses
 (only 254 are usable, 10.11.1.0 and 10.11.1.255 are reserved)
 
Classroom 2 can use 10.11.2.0/24 for a total of 256 addresses
 (only 254 are usable, 10.11.2.0 and 10.11.2.255 are reserved)
 
Classroom 3 can use 10.11.3.0/24 for a total of 256 addresses
 (only 254 are usable, 10.11.3.0 and 10.11.3.255 are reserved)

The faculty computer behaves like a gateway for the non-faculty computers, thus the faculty computers will have 
 the lowermost non-reserved IP addresses:
 
Classroom 1 Faculty will use 10.11.1.1
Classroom 2 Faculty will use 10.11.2.1
Classroom 3 Faculty will use 10.11.3.1

Every computer will then use each subsequently non-reserved IP address.
Let's say you're working as the network security manager and you are noticing unusually high traffic from the
 following IP address: 10.11.2.7
  
This means that the offending traffic is coming from the 7th non-faculty computer in classroom 2.
You can scale this to a total of 65,534 devices on the local network at any given moment if need be.

Knowing how a network is set up and which rooms correspond to which IP address range can make it easier to maintain control over a relatively large network with hundreds to thousands of concurrent hosts.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.