Internet 101

Joseph Reagle

Internet

How the Internet works

I’m using clips from Jessica McKellar’s How the Internet works

Summary

  • DNS (who: name to address mapping)
  • Internet Protocol/IP (where: addressing and routing)
  • Transmission Control Protocol/TCP (how: reliably deliver data)
  • Application: HTTP (what: is requested )
    • Cookies
  • Markup: HTML
  • Locators: URLs
  • Security
    • shared secret for confidentiality
    • public key to exchange secret
    • certificate to authenticate public key

Protocol

DNS

IP

TCP

HTTP

Conclude

Protocol recap

Web

URL Syntax

  http://example.com:8042/over/there?name=ferret#nose
  \_/   \__________/\___/\_________/ \_________/ \__/
   |       |          |       |          |        |
scheme  authority    port    path      query   fragment
  • queries are used for dynamic/database websites
  • fragments takes you a view of a page (e.g., syllabus)

HTTP Client request

You type:

http://www.example.com/Index.Html

Your browser sends:

GET /Index.Html HTTP/1.1
Host: www.example.com

HTTP Server response

HTTP/1.1 200 OK
Date: Mon, 23 May 2005 22:38:34 GMT
Server: Apache/1.3.3.7 (Unix) (Red-Hat/Linux)
Last-Modified: Wed, 08 Jan 2003 23:11:55 GMT
ETag: "3f80f-1b6-3e1cb03b"
Content-Type: text/html; charset=UTF-8
Content-Length: 131
Accept-Ranges: bytes
Connection: close

<html>
<head>
  <title>An Example Page</title>
</head>
<body>
  Hello World, this is a very simple HTML document.
</body>
</html>

HTML

<html>
<head>
  <title>An Example Page</title>
</head>
<body>
  Hello World, this is a very simple HTML document.
</body>
</html>

Internet Metaphor

  • You want to send a request for a magazine article to Sally, and the envelopes (packets) are small: one sentence per envelope.
  • You look up Sally and find her address and zipcode (DNS to find IP number)
  • You drop your five packets addressed to Sally in the mailbox; they flow through the postal network (IP)
  • Sally gets all but one of your packets, sends a post card asking you to resend it (TCP)
  • Once done, she breaks up the article into packets and sends them to you

Cookies

Request

GET /index.html HTTP/1.1
Host: www.example.org
...

The server won’t know who you are.

Next request

GET /spec.html HTTP/1.1
Host: www.example.org
Cookie: theme=light; sessionToken=abc123
...

The server will know your previously set preferences.

Security

The Greeks

The Greeks preserve the bridge of Darius.jpg

Histiaeus is said to have tattooed a message on a slave’s head and let the hair grow in.

Caesar cipher

What message is this??

the ciphertext “fuxppb” has been shifted forward 3 letters?

  1. fuxppb
  2. etwooa
  3. dsvnnz
  4. crummy

Symmetric key encryption

Public key encryption

Private key signature

Crypto recap

Certificates

How do you it’s really Bob’s (public) key?

TLS (Transport Layer Security)

(used by HTTPS and replaces SSL)

Security recap

  • symmetric ciphers use shared secrets to encrypt message
  • asymmetric public keys allow you to share a secret securely
  • certificates assure that a public key really belongs to who it says it does

Threats

Malware

worm (autonomous); virus (dependent); Trojan (non-self-replicating); bots (remote controlled)

Protect yourself

Conclusion

Summary

  • DNS (who: name to address mapping)
  • Internet Protocol/IP (where: addressing and routing)
  • Transmission Control Protocol/TCP (how: reliably deliver data)
  • Application: HTTP (what: is requested )
    • Cookies
  • Markup: HTML
  • Locators: URLs
  • Security
    • confidentiality: cipher + secret/key
    • exchanging secret: public key
    • authenticate public key: certificate

Ask Dr. Reagle!

FAQ

Review

Protocol match

a. DNS 1. location of Web resource
b. IP 2. reliably deliver data
c. TCP 3. addressing and routing
d. HTTP 4. marked up Webpage content
e. HTML 5. requesting Web resource
f. URL 6. name to IP mapping

Security

What are the three important components of web security?

  • confidentiality: cipher + symmetric secret/key
  • exchanging secret: asymmetric public/private keys
  • authenticate public key: certificate

What message is this?

The ciphertext “gljlwdo” has been shifted forward 4 letters.

  1. gljlwdo
  2. fkikvcn
  3. ejhjubm
  4. digital