How to do Network Mapping using Traceroute? is it possible to map the network only by using the traceroute?the answer is yes 🙂
Network mapping is interesting because we will try to draw the computer network only from a data that we received from a command line.
According to wikipedia:
Network mapping is the study of the physical connectivity of networks. Network mapping discovers the devices on the network and their connectivity. It is not to be confused with network discovery or network enumerating which discovers devices on the network and their characteristics such as (operating system, open ports, listening network services, etc.).
Most of us are using ISP(Internet Service Provider) service to connect to the internet, but many of us don't know how do the ISP operate and how can we connected to the internet?How many router that we pass, and so on.
This tips and trick will cover about mapping the network related with the network devices called router.
What wikipedia says about a router:
A router is a device that forwards data packets between computer networks, creating an overlay internetwork. A router is connected to two or more data lines from different networks. When a data packet comes in one of the lines, the router reads the address information in the packet to determine its ultimate destination. Then, using information in its routing table or routing policy, it directs the packet to the next network on its journey. Routers perform the "traffic directing" functions on the Internet. A data packet is typically forwarded from one router to another through the networks that constitute the internetwork until it reaches its destination node.
So what' important and interesting after I know about the router?
When we open a web browser and type e.g: google.com, our computer forward the packet through many routers until it reach Google web server (see the picture).
The important thing is when we can do the mapping, we can guess about the network condition through the network address, or in other ways it will also help us to go further to network discovery.
1. SSH server or Telnet server
2. Command prompt or terminal
The client will using Command prompt to traceroute from user to the web server.
I use SSH server on the other side, so there will be a terminal.
1. Firstly you must have a SSH server or Telnet server. You can rent a yearly SSH server or find some free SSH server on the internet.
2. Let's open the command prompt (press windows logo + R and type cmd) and type:
on Linux you can use traceroute www.our_web_server.com. In this example we try to traceroute to .
3. After we finished the step 2 and get some information from there, firstly we must know our public IP address (check your public IP address). After that now we move to our server. We can connect using Putty if our server use Linux and telnet if using Windows. We will do the same traceroute comand as 2nd step, but we put our public IP address on the target IP.
4. If we see carefully and try to mix and match the result from step 2 and step 3, take a look to the IP address and see this three part (you must understand about subnetting).
XXX : XXX : XXX : XXX
result on step 4 no.14 will match with step 2 no.7; Result on step 4 no.12 and no.13 will match with step 2 no.9, and so on
5. With this information, we can draw and mapping the network (for the router) and counting the probability of their network address. With the information on step two and step three, I can draw the picture below.
1. On step 2 the total hop when doing traceroute is 21 hop, but on step 4 the total hop when doing traceroute is 14 hop. This can happen depending on how the network administrator route the network packet. Incoming and outgoing packet usually use a different routing.
2. Of course what we do on the step above is only guessing the network, it will not 100% accurate since outgoing and incoming routing is different, but at least we know how packets flow. If you want further information and more accurate results, you can search for other tools to do network mapping.
Hope you found it useful 🙂