Network

An IP address (with IP for Internet Protocol) is an identifier, which is assigned, permanently or temporarily, to each machine connected to a computer network (PC, telephone, smart TV, connected object, ...).

IPv4 (version 4) addresses are 32-bit coded. They are generally represented in decimal notation with four numbers between 0 and 255, separated by dots. Example: 172.16.254.1

A server has as many addresses as there are network cards. Some addresses have a reserved use:

  • 127.0.0.1, called loopback designates our server.
  • 0.0.0.0.0, designates all the IP addresses of our server.


Subnetwork

The first bits of the IP address specify the network number, the next bits the host number. The number of bits in the network is specified by the network mask:

  • 10.10.0.0/16 => Network 10.10.x.x, there are 65534 IP available on this network.
  • 10.10.10.0/24 => Network 10.10.10.x, there are 254 IP available on this network.

When we scan 10.10.10.1/24, we test all addresses from 10.10.10.1 to 10.10.10.255.


192.168.X.X/16, 172.16.0.0/12 and 10.X.X.X/8

The 192.168.X.X/16, 172.16.0.0/12 and 10.X.X.X/8 networks are dedicated to local networks. Such adresses should never be forwarded by routers or boxes to Internet. You must train scans and exploits ONLY on hosts on those networks.

Wikipedia: https://en.wikipedia.org/wiki/IP_address

Video

Few interresting video: