CSE 4344 Chapter 2
Examples of Top Level Domain servers
.com dns servers, .org dns servers, .edu dns servers
What is a Non-Persistent HTTP connection?
1st a TCP Connection is opened and at most one object is sent over the TCP connection, then the tcp connection is closed.
What is a Persistent HTTP connection?
1st a TCP connection is opened to a SERVER, then MULTUPLE objects are sent over a single TCP connection between the client, and that SERVER. So you can reuse the connection to grab multiple files. Then the TCP connection is closed
What is a process and what type of processes are there?
A program running within a host apart of the application layer. There are client and server processes. A client process initiates the communication. A server process waits to be contacted.
To uniquely identify a socket on the Internet, what are the two numbers needed?
An IP Address and a port number
What does the status code 400 mean?
Bad request, message not understood by server
Applications that have throughput requirements
Bandwidth-sensitive applications
Why do a lot of streaming services use TCP rather than UDP?
Because most streaming services use HTTP, which uses TCP
Cookies are database entries on the server. True or False?
False
List services that TCP can while UDP cannot provide.
HTTP (for web documents), FTP (for file transfer and downloading), SMTP (for emails), or HTTP or Dash(for streaming videos)
What does the status code 505 mean?
HTTP version not supported
What is the port number?
Identifies the process running on the host
What is ICANN?
Internet Corporation for Assigned Names and Numbers manages the root DNS domain. There's 13 in total
What is IMAP?
Internet Mail Access Protocol is a mail access protocol. IMAP is responsible for reading emails as opposed to sending emails POP is another Mail Access protocol similar to IMAP
what is Peer to Peer architecture?
It has self scalability, new peers bring new service capacity and new service demands. Files are also divided into chunks. There is also a tracker to track peers. Now a torent is just a group of peers. Bitorent is an example of P2P
What is Addressing? What does an identifier contain?
It specifies which socket these message is from and what socket the message's destination is. An identifier contains the process host's ip address and port number.
Define RTT
It stands for round trip time. it's the time for a small packet to travel from client to server and back
What is a socket?
It's like a door between one process on a machine to another process on another machine.
What does it mean to be stateless?
NO HISTORY is REQUIRED to be maintained , none of past clients requests are maintained. An example would be HTTP
Suppose you are a NASA engineer. You decided to have a webserver running on the rover on Mars to serve collected Mars images to the scientists on Earth. Is this a good design or not? Explain why.
No there would be a lot of data latency from trying to communicate from earth to mars
What are the two types of http connections?
Non-Persistent and Persistent http connections
What does the status code 404 mean?
Not found, requested document not on server
What does the status code 200 mean?
OK, request was successful
HTTP Request Messages
Post, Get, Head, Put
The DNS system of the Internet is a distributed, hierarchical database system. What is name of the servers at the top level in its hierarchy?
Root DNS Servers
What is the DNS hierarchy from top to bottom
Root, Top Level Domain, Authoritative
List services that can be provided by TCP or UDP
SIP(Internet Telephony), RTP(Internet Telephony), WOW( Online games)
What improvements did HTTP/3 have?
Security improvements
What type of IP addresses do server and clients have?
Servers have permeant ip addresses while clients have dynamic ip addresses
what is SMTP?
Stands for Simple Mail Transfer Protocol and it's responsible for delivery/ storage of email messages to receiver's server
Differences between UDP and TCP?
TCP is reliable and requires the source and destination to establish a 3-way handshake before the transmission may occur. TCP also allows connection-oriented. There is also no minimum throughput guarantee. However, UDP is unreliable and does not require this handshake process.
Below is a part of a HTTP response received by a browser. Please answer the question. HTTP/1.1 200 OKDate: Mon, 27 Jul 2009 12:28:53 GMTServer: Apache/2.2.14 (Win32)Last-Modified: Wed, 22 Jul 2009 19:15:56 GMTContent-Length: 88Content-Type: text/htmlConnection: Closed If the web browser needs to request another object referred by the same page, can the browser reuse this connection (i.e., is this connection persistent?) Why?
The http request is closed which means the connection will be closed after the response is sent which means there will be no reuse. Thus it is a non-persistent connection.
Assume that an HTML page has 2 images (and no other objects) and the network is working normally, without loss. If we use non-persistent HTTP protocol, how many RTTs do we need to fetch the HTML page in its entirety? (Assume we are not using parallel connections and can only fetch objects sequentially) Please give reasoning. What if we use persistent HTTP protocol?
There would be 6 RTTs for non-persistent since only ONE object can transferred at a time with a non-persistent connection. It should be noted for every object in a non-persistent connection it should take 2 RTTs. There are 2 images and 1 HTML file thus there are 3 objects in total thus, 3*2= 6, so 6 RTTS in total. However, it should only take 4 RTTs for persistent, since MULTIPLE objects can transferred at a time with a persistent connection. There would be 2 RTTs for the HTML file + 2 RTTs for the 2 image files, thus 4 RTTs in total.
What transport services does an app need?
Throughput(ex: streaming services may ask for at least 2mbps or for other services there is no requirement thus they are elastic apps), timing(some apps need less of a delay), data integrity, and security
UDP packets from different sources (IP addresses) but destined to the same port on a machine (IP address) will be delivered to the same socket.
True
How do we maintain history and state on stateless protocol?
We use Cookies which are saved on the web browser of the client's machine, not the server. There is also a backend database on the server to specify the cookie ids.
What is inter-process communication?
Within the same host, 2 processes communicate with each other.
Examples of Authoritative servers
amazon.com DNS servers , pbs.org DNS servers, uta.edu DNS Servers
How do we create a socket with TCP on python?
clientSocket = socket(AF_INET, SOCK_STREAM)
Applications in which throughput does not matter too much
elastic apps
Post HTTP Method
gets user input
What does DNS provide?
host-name to ip address translation, ex: google.com to 2001:4860:4860::8888. Host aliasing(have simpler urls for the users for longer urls), mail server aliasing
What improvements has HTTP/2 made from HTTP 1
more methods, status codes and provides transmission control
how is a dns record structured for type Cname?
name is alias for real name, like ibm.com is actually servereast.backup2.ibm.com and value is canonical name
how is a dns record structured for type NS?
name is domain (ex foo.com) and value is hostname of authoritative name server for this domain. This is basically a named server
What is the structure of a DNS record?
name, value, type, ttl(time to live)
HEAD HTTP Method
request headers only that would be returned if specified url were requested with a GET
What does the status code 301 mean?
request object Moved permanently
How do we create a socket with UDP on python?
serverSocket = socket(AF_INET, SOCK_DGRAM)
how is a dns record structured for type A?
the name is the hostname and the value is the ip address
What separates the header and data in an http response message
two carriage returns
What does an Application Layer protocol define
types of messages exchanged( requests and responses), message syntax, message semantic, rules, open protocols( like http and smtp), and proprietary protocols
PUT HTTP Method
uploads new file object to server
GET HTTP Method
used for sending data to server through urls
What are the components an email?
user agents(mail readers like outlook), mail servers, and SMTP
how is a dns record structured for type MX?
value is name of SMTP mail server associated with the name