CS074-The Digital World

    Lab 9



Assigned Wednesday, April 15
Due Friday, April 24

There is no programming in this assignment.  Its purpose is to understand such basic terms as "IP address" and "network protocol".

1. What's my computer's IP address?

If you're on Windows, open the Command Prompt.  (You can probably find it in Programs/Accessories.)  Type ipconfig.  Note the IP address.

If you're on a Mac, open the Terminal utility (by going to Applications, and then Utilities) and type ipconfig getifaddr en0.  Note the IP address.

(a) What's your computer's IP address?

(b) Who provides your internet service?  (Are you hooked directly to BC's network?  Do you live off-campus and subscribe to an Internet Service Provider?)  If you're on BC's network then your IP address probably begings 136.167, as this range of addresses is assigned to Boston College.   If you have an IP address that begins 192.168, then you are probably on a private network.  These addresses do not uniquely identify your computer throughout the world, but only within your local network.  For instance, if I type ipconfig on the  computer on my desk at home, I get the result 192.168.2.24.  This address is assigned by the router in my home network.  The router itself is assigned a globablly unique address by my Internet Service Provider.

(c) Boston College has, in fact, been assigned all the IP addresses in the range 136.167.0.0 to 136.167.255.255.  How many addresses does that make in all?

2. Find the IP address of another computer.....

Choose an exotic locale, preferably in a foreign country, and try to find the Web address of an organization in that locale.  For instance, Buffalo, New York is decidedly not an exotic locale, but if I really thought it was, I might try typing "Stanford University" in my Web search engine, and  find the Web address "www.stanford.edu".  I can then take the host name "buffalo.edu" and determine its IP address by typing in the Command Prompt

ping stanford.edu

The "ping" program will look up the IP address associated with this host name. (buffalo.edu gave me 171.67.216.8) It will try to send a packet to that address (although it might not get a response) but in any case, you should see the IP address.  (Some apparent host names for very large organizations, for example "harvard.edu" can't be resolved to IP addresses.  Instead you have to narrow it down---for instance "math.harvard.edu" ---the Math department--- and "fas.harvard.edu"  --the Faculty of Arts and Sciences--- both work.)

On a Mac, ping seems to keep on sending packets until you stop it with control-C.  You can make sure it doesn't keep pinging by instead typing ping -c 1 stanford.edu.

Write the exotic locale you chose, the host, and the IP address.

...and trace the route that a packet travels

Use either the  host name from the preceding problem, or its IP address.  If you're on Windows, type tracert at the Command Prompt, followed by the host name or IP address. If you're on a Mac, type traceroute at the Terminal prompt followed by the hostname. You will get a report (possibly incomplete near the end) of the different "hops" your message took traveling from the source to the destination.  For instance, when I typed

traceroute stanford.edu

at the Mac in my office, I got this result for the first 15 hops:
 
1  136.167.230.1 (136.167.230.1)  0.756 ms  0.415 ms  0.331 ms
 2  136.167.6.130 (136.167.6.130)  0.367 ms  0.327 ms  0.324 ms
 3  136.167.9.241 (136.167.9.241)  0.974 ms  0.793 ms  0.847 ms
 4  nox1sumgw1-Vl-581-NoX-BC.nox.org (192.5.89.81)  1.240 ms  1.327 ms  1.173 ms
 5  nox300gw1-Vl-803-NoX.nox.org (192.5.89.238)  1.378 ms  1.190 ms  1.309 ms
 6  * nox300gw1-PEER-NoX-INTERNET2-192-5-89-222.nox.org (192.5.89.222)  189.217 ms *
 7  so-0-0-0.0.rtr.wash.net.internet2.edu (64.57.28.11)  11.604 ms  16.178 ms  15.158 ms
 8  so-0-0-0.0.rtr.atla.net.internet2.edu (64.57.28.6)  238.473 ms  242.431 ms  242.913 ms
 9  so-3-2-0.0.rtr.hous.net.internet2.edu (64.57.28.43)  48.596 ms  56.870 ms  48.377 ms
10  so-3-0-0.0.rtr.losa.net.internet2.edu (64.57.28.44)  80.162 ms  80.797 ms  90.529 ms
11  hpr-lax-hpr--i2-newnet.cenic.net (137.164.26.132)  80.530 ms  80.491 ms  80.422 ms
12  svl-hpr--lax-hpr-10ge.cenic.net (137.164.25.13)  88.586 ms  88.629 ms  88.413 ms
13  oak-hpr--svl-hpr-10ge.cenic.net (137.164.25.9)  89.830 ms  89.620 ms  89.701 ms
14  hpr-stan-ge--oak-hpr.cenic.net (137.164.27.158)  90.901 ms  90.898 ms  90.813 ms
15  bbra-rtr.Stanford.EDU (171.64.1.134)  91.346 ms  91.296 ms  91.340 ms


The first three hops are BC addresses.  We can guess, by looking at the host names, where some of the intermediate stops are located (Washington, Atlanta, Houston, Los Angeles, Los Angeles International Airport (LAX), Silicon Valley maybe, Oakland, California and then finally an address at Stanford).  You may not be able to do this for every host that you try, so you might want to try a few different ones.  Report on what you found. 

3.  How Big is the Internet?


This is something of a free-form problem.  Do some Web-based research aimed at answering the question:  "How many computers are connected to the Internet?" Note carefully the date of the information that you find!!  Let me know the site or sites where you located the information, and something about how the estimate of the Internet size was made.

4. Some Network Protocols

Both the Command Prompt in Windows and the Terminal Utility in Macs allow you to run a program called telnet.  If you type

telnet hostname port-number

you can contact the server at the named host running at the given port, and then send lines of text to the server and read lines of text from the server.

Time of Day Server:  This is a simple one.  Many computers run a program on port 13 that sends a single line of text over the network, giving the date and time.  To test this, type

telnet time-a.timefreq.bldrdoc.gov 13

and hit Enter.  The server will immediately send back a long string that contains the date, time (in Greenwich mean time), which telnet will display.

Web Server. Web servers usually run on port 80 and communicate with the client using a protocol called Hypertext Transfer Protocol (HTTP). To connect to the Computer Science Department's Web Server, type "cs.bc.edu " for the host and 80 for the port.  Hit Enter.

(If you're on Windows, you have to perform an additional step to be able to see what you type:  First type CTRL+] (i.e., type the ] character while holding down the CTRL key).  You will see a prompt for Microsoft Telnet appear.  Type set localecho and hit Enter.  Then, when the prompt returns, hit Enter again.)

Now, type the line

GET /~straubin/DigitalWorld09/syllabus.html

and hit Enter.  The Web server at the host will send the entire HTML source of the home page for the course.
 
 

Send Mail (SMTP server): There's something to hand in here.  You can send e-mail to me by connecting to the Computer Science Department's SMTP (Simple Mail Transfer Protocol) server on port 25.  After connecting, follow these instructions carefully!
 


What to hand in:  Copy the messages exchanged between you and the SMTP server and paste them into a text file.  (I will also receive your e-mail.)