CS138-lecture-20210413

Review #

image_2021-04-13-09-00-54

  1. Devices, links, packet switches
  2. Protocols define format and order of messages sent and received among network entities
  3. Routers
  4. Routing and forwarding
  5. Packet switching

image_2021-04-13-09-02-20

  1. Worms do not need user’s interaction, viruses do
  2. Distributed denial of service. TLD name servers are easier to attack
  3. Recording packets passing through network
  4. Sends a packet with a forced source address
  5. Sends bogus replies to the DNS servers

image_2021-04-13-09-04-36

  1. P2P is more scalable
  2. IP address and port number
  3. TCP, because it is reliable
  4. TCP
  5. SSL is implemented at the app layer

image_2021-04-13-09-06-25

  1. Persistent allows multiple objects to be sent over a single connection
  2. set-cookie
  3. cookie
  4. Database or back end
  5. Cookie file managed by browser

image_2021-04-13-09-08-05

  1. host to IP mapping, host nick name, mail server nick name, load distribution
  2. iterative and recursive
  3. (fruit.com, dns.fruit.com, NS), (dns.fruit.com, 192.168.112.0, A)

image_2021-04-13-09-10-08

  1. The rarest chunk first, B
  2. The top 4 peers that seed her the most

image_2021-04-13-09-12-06

  1. SOCK_DGRAM
  2. sendto
  3. The client needs to close, but the server’s socket is reused
  4. 1 global socket to hand shake, 1 per connected client
  5. The socket connected to the client can be closed. The hand shake socket stays open.

image_2021-04-13-09-14-25

  1. application, presentation, session, transport, network, link, physical
  2. presentation and session
  3. save time, save bandwidth, save traffic
  4. if-modified-since
  5. 304 not modified

image_2021-04-13-09-16-17 image_2021-04-13-09-16-43

  1. \( \frac{L}{R} = \frac{30}{3} + \frac{30}{5} + \frac{30}{10} = 19 \)
  2. \( \frac{D}{S} = \frac{100}{20} = 5 \)
  3. \( 19 +5 + 2(2) + 1(2) = 30 \)
  4. queuing
  5. 3 Gbps is the bottleneck

image_2021-04-13-09-22-28

  1. SMTP or HTTP
  2. SMTP
  3. POP3 or IMAP or HTTP
  4. port 25
  5. TCP

Network layer cont #

image_2021-04-13-09-24-58 image_2021-04-13-09-25-15 image_2021-04-13-09-25-20

TCP vs UDP

  • Transport layer connection vs connectionless
  • Programmers have the choice to use TCP or UDP, by giving different parameters to the socket function
  • Process to process
  • Done within network devices

Datagram vs Virtual circuit

  • Network layer connection vs connectionless
  • No choice for programmers, the network provides one or the other
  • Host to host
  • Done on network core (routers)

Our internet uses Datagrams, hence it is connectionless on the network layer. We use TCP to get a connection service at the transport layer.

Virtual circuits (VC) #

image_2021-04-13-09-33-01 image_2021-04-13-09-36-22 image_2021-04-13-09-38-38 image_2021-04-13-09-42-24 image_2021-04-13-09-43-01 image_2021-04-13-09-43-03 image_2021-04-13-09-43-23

Datagram networks #

image_2021-04-13-09-45-03 image_2021-04-13-09-45-24 image_2021-04-13-09-48-35 image_2021-04-13-09-49-12

Datagram vs VC overview #

image_2021-04-13-09-53-07

What’s inside a router #

image_2021-04-13-09-56-19 image_2021-04-13-09-57-09 image_2021-04-13-09-59-21 image_2021-04-13-09-59-32