#4/CSCI 355

Oct 3, 2024

Networking Models and Protocols

OSI and TCP/IP Models

  • OSI Model: Open Systems Interconnected Model
    • Conceptual model of internet design
    • Consists of 7 layers: Physical, Data Link, Network, Transport, Session, Presentation, Application
  • TCP/IP Model: Used in practice
    • Derived from OSI
    • Consists of 5 layers: Application (combines Application, Presentation, Session from OSI), Transport, Network, Data Link, Physical

Layering Concept

  • Purpose: Provides abstraction, ensuring higher layers function assuming lower layers perform their tasks
  • Layers:
    • Physical: Transmission of raw bits
    • Data Link: Delivery across a single hop
    • Network: Provides end-to-end communication
    • Transport: Ensures data delivery to the correct application on target machine
    • Application: High-level APIs, services

Protocols

  • Examples:
    • Ethernet, 802.11 (Wi-Fi): Data Link Layer
    • Internet Protocol (IP): Network Layer
    • TCP, UDP: Transport Layer
    • HTTP: Application Layer
  • Role: Set rules for data exchange (syntax, semantics, synchronization, error recovery)

Historical Communication Protocols

  • Homing Pigeons: Unidirectional communication
  • Hydraulic Semaphore: Early protocol with medium and rules
  • Optical Telegraph: Example of end-to-end encryption

Physical Layer

  • Transmission Media: Copper, Optical (Fiber)
  • Copper Cables:
    • Voltage Modulation: Electric signals
    • Twisted Pair: Minimizes interference (cross talk)
  • Optical Cables:
    • Light Modulation: Transmits data as light pulses
    • Challenges: Attenuation loss, no power transmission

Communication Types

  • Simplex: One-way communication (e.g., TVs)
  • Duplex:
    • Half Duplex: One party sends at a time (e.g., walkie-talkies)
    • Full Duplex: Both parties can send simultaneously

Networking Devices

  • Hub: Physical layer device, duplicates signals
    • Creates collision domain leading to half duplex communication
  • Switch: Improved device replacing hubs

Collision Detection and Avoidance

  • CSMA/CD: Carrier Sense Multiple Access with Collision Detection
    • Stops transmission on collision detection
  • CSMA/CA: Collision Avoidance
    • Uses randomized timers to prevent livelock