traceroute
command is
not stored on your regular path, try looking in /sbin
and
/usr/sbin
directories. Equivalent command line utility under Windows
is called tracert
. You are required to use the command line tool.
Results from the web or GUI-based applications will not be accepted. Submit your
conclusions, not the outputs of running the commands.132.176.0.11 132.177.1.22 132.177.2.33 132.177.3.44 132.177.8.5 132.177.17.16
of the host that you are connected to. Repeat this on several hosts/devices, preferably connected to different networks. List the commands that you used.
tcpdump
. Alternatively,
you can view the trace using CloudShark service (http://www.cloudshark.org/captures/a23a79af90ae)
provided by QA Cafe, a local
company with many UNH-CS and IOL connections.Study the trace and answer the following questions:
Write a simple program that takes an IPv4 address and a prefix length and calculates:
The program should perform basic error checking on the user input (e.g., values out of range). The IP address can be entered as a whole or as 4 values for each of its bytes. A run of your program may look like this (bold font indicates user input):
Enter IP address: 192.168.1.32 Enter prefix length: 24 Subnet address: 192.168.1.0 First host: 192.168.1.1 Last host: 192.168.1.254 Broadcast address: 192.168.1.255 Subnet mask: 255.255.255.0
Your are allowed to use any programming language, platform, and development environment. There will be an extra credit component to the assignment grade that will award points based on how few of the students chosen to use the same language and platform. However, keep in mind that the next assignment will ask you to implement the same calculation as a web service.
Write a report (two pages maximum) that outlines the approach that you took. There are two parts to the report. In the first one you will describe the part of the program that actually performs the calculation. Ignore everything else: interaction with the user, standard code that one would find in every program. You are to include snippets of your code, provided they are well described. For example, a line of code b4 = a % 256
can be described as modulo 256 operation isolates the least significant byte. Just stating in English what the code does, for example b4 gets the value of a modulo 256 is not sufficient.
The second part of the report shows a representative run of your program together with appropriate explanations. Important: by showing an execution of your program, you are making a statement that your program, as submitted, works as shown. An attempt to "fake" a run, for example by writing a program that ignores input and just prints answers regardless of input, will be considered as cheating. Finally, remember, you may be asked to give a demo of your program. If your program does not implement all required functionalities, you have to make it clear in the report.
The report must be in PDF format. Other formats, including but not limited to MS Word, plain text, HTML, RTF, or OpenOffice, will be not accepted. Every recent text processing application that I know of is capable of producing PDF files. If you are not sure how to do it, ask.
Follow the standard assignment submission instructions. Note that the report submission must be in PDF format.