Lecture 12: Putting Things Together

14 April, 2014.

Today, we are going to see how the five layers work together through the examples. We will end the lecture by distilling some of the most important tricks that engineers have used to build computer networks, and higlight how it is used in different parts of CS2105.

Reading: 5.7 A Day in the Life of a Web Page Request

Slides: PDF

Lecture 10: LAN

30 March, 2014.

This week we will take a look at another multiple access protocol, CSMA/CA for WiFi, and discuss the roles of hubs, switch, and routers in forming a LAN. ARP will be discussed as well.

Slides: PDF

Please read the following sections in the textbook.

  • 5.4 Switched Local Area Network (exclude 5.4.4)
  • 6.3.1 The 802.11 Architecture
  • 6.3.2 The 802.11 MAC Protocol

Lecture 9: Link Layer

24 March, 2014.

“These Protocols Transmit At Random Interval. It May Sound Ridiculous, But The Reason They Do It Is Simply Beautiful.”

This week we continue our venture down the protocol stack, and look at the link layer. We will review the services provided by the link layer, how error detection/correction is done, how shared medium are accessed, and finish up with a discussion on Ethernet frame format.

Slides: PDF

Please read the following sections in the textbook. Reading: Chapter 5

  • 5.1 Introduction to the Link Layer
  • 5.2 Error-Detection and -Correction Techniques
  • 5.3 Multiple Access Links and Protocols (skip efficiency analysis in 5.3.2)
  • 5.4.2 Ethernet – Ethernet Frame Structure (page 497 – 499)

Lecture 8: Network Security

17 March, 2014.

This week we will look at network security at the application, transport, and network layer. We will skip the mathematics involved (there are other modules for that) and focus on the concepts that enable secure communication via SSL and IPsec.

Slides: PDF

Please read the following sections in the textbook. Reading:

  • 1.6 Networks Under Attack
  • 8.1 What is Network Security?
  • 8.2 Principles of Cryptography (exclude 8.2.1)
  • 8.2.2 Public Key Encryption (exclude RSA and subsequent paragraphs)
  • 8.3 Message Integry and Digital Signatures
  • 8.4 End-Point Authentication
  • 8.6 Securing TPC Connections: SSL (exclude 8.6.2)
  • 8.7 Network-Layer Security: IPsec and VPN (exclude 8.7.5)
  • 8.9 Firewalls and Intrusion Detection Systems (FYI only)

Lecture 7: Routing

3 March, 2014.

Millions of Routers Work in Concert to Route Packets on the Internet, Based on This One Simple Equation. Amazing.

This week we will look at how routing is done on the Internet, focusing on distance vector routing protocol and RIP, used in intra-AS routing.

Slides: PDF

Please read the following sections in the textbook. Reading:
Chapter 4 of KR.

  • 4.5 Routing Algorithms
    • 4.6.1 Intra-AS Routing in the Internet: RIP

Lecture 6: IP

17 February, 2014.

“The Internet has Ran Out of IPv4 Addresses. These Hacks, Used to Keep the Internet Growing, Are Absolutely Brilliant.”

We now venture into the network layer and look at IP and the associated protocols (DHCP, ICMP, NAT) in more details.

Slides: PDF

Please read the following sections in the textbook. Reading:
Chapter 4 of KR.

  • 4.1 Introduction
  • 4.2.2 Datagram Networks
  • 4.4 The Internet Protocol (IP) (exclude 4.4.4, 4.4.5)

Lecture 5: UDP and TCP

10 February, 2014.

“You Won’t Believe How Simple the UDP Protocol is. But The Complexity of TCP Will Make You Cry.”

We will continue our discussion of generic reliable protocols, finishing it off with Selective Repeat protocol.

We will then look at the two major transport protocols on the Internet, namely, UDP and TCP in more details.

Please read the following sections in the textbook. Reading:
Chapter 3 of KR.

  • 3.3 Connectionless Transport: UDP
  • 3.5 Connection-oriented Transport: TCP

Slides: PDF

Lecture 3 (Leftover): UDP Socket Programming

I have shown you how to code a networked application that runs over TCP using Java socket programming API.

To complete the picture, please take a look at this video, from Semester 2 of last AY, that illustrates how to write a socket program over UDP. While you won’t need to code UDP program in CS2105, seeing how a UDP socket API is written and how a UDP program is used, would allow you to contrast the differences between TCP and UDP.

Lecture 4: Reliable Protocols

3 February, 2014.


“Sending Data Reliably over the Internet is Harder than You Think. The Intricacy Involved in Ensuring Reliability Will Make Your Head Explode.”

This is the first lecture on the transport layer. After briefly describing the role of transport layer, I will delve deep into the question of how to build a reliable protocol on top of an unreliable delivery service.

We will not discuss any actual protocol (TCP or UDP) this week.

Please read the following sections in the textbook.
Reading:
Chapter 3 of KR.

  • 3.1 Introduction
  • 3.4.1 Building a Reliable Data Transfer Protocol
  • 3.4.2 Pipelined Reliable Data Transfer Protocols

Slides:PDF

Lecture 3: Socket Programming

27 January, 2014.

You Won’t Believe How Many Lines of Code It Takes To Write a Minimum Workable Web Server. You Have to See It!

After finishing off our discussion on DNS, I will show how to write simple TCP applications, include a Web server, in Java. I will also show you how to program a UDP-based networked application.

Related sections from Java API documentation: Socket, ServerSocket, DatagramSocket, , InetAddress

There is no corresponding sections in the textbook (the book uses Python for socket programming).

Source code written during class will be posted after the class.

Lecture 2: The Application Layer

20 January, 2014.

“This Application Level Protocol is Used by Every Other Internet Application. If You Think I am Refering to the Web or HTTP, You Would Be Wrong.”

In this lecture, I will cover three topics on the application layer. First, I will explain networked applications and their interface to the transport layer. Second, I will describe an example protocol that lives in the application layer, HTTP. Third, I will talk about DNS, a directory service used by networked applications.

Reading: Chapter 2 of KR.

  • 2.1 Principles of Network Applications
  • 2.2 The Web and HTTP
  • 2.5 DNS — The Internet’s Directory Service

Slides: PDF

Lecture 1: Introduction

January 13, 2014.

“The Complexity Involved in Engineering the Internet Will Make Your Head Explode, but This One Incredibly Simple Trick Keeps the Complexity Manageable.”

In this first lecture, I will give a brief introduction to the module and introduce many basic concepts, including: host, protocol, packet, packet switching, circuit switching, store-and-forward, delay, throughput, bottleneck link, packet loss, traceroute, and the five layers of the Internet.

Please read the following for a high-level introduction to computer networks and the Internet. We will revisit many of the concepts again in future lectures. Reading:
Chapter 1 of KR.

  • 1.1 What is the Internet?
  • 1.2 The Network Edge
  • 1.3 The Network Core
  • 1.4 Delay, Loss, and Throughput (except 1.4.2)
  • 1.5 Protocol Layers and Their Service Models

Slides:PDF