Ir al contenido
← Networking and security architecture

Lección 1 de 4 · 9 min

Network basics: the OSI model, TCP/IP and common ports

How data travels between computers, the layer models used to describe it, and the ports and protocols you will see in every firewall and log.

Por ahora esta página está en inglés.

You cannot protect a network you cannot describe. Every firewall rule, alert and log line is written in the language of networking: addresses, protocols, ports and layers. This lesson gives you that vocabulary. The University’s TCP/IP and DNS courses go deeper; here the goal is a working map you can use in every lesson that follows.

Layers: splitting a hard problem into pieces

Sending a message across the world involves physical signals, local delivery, global routing, reliable delivery and the application’s own format. Network engineers split this into layers, each doing one job and relying on the layer below. The OSI reference model, standardised by the ITU as X.200 and by ISO, uses seven layers. The internet itself runs on the simpler TCP/IP model, usually drawn with four layers. The OSI numbers survive in everyday speech: a “layer 7 firewall” looks at applications, a “layer 3 device” routes IP packets.

OSI layerWhat it handlesEveryday examplesTCP/IP model
7 ApplicationWhat the program saysHTTP, DNS, SMTP, IMAPApplication
6 PresentationFormats, encoding, encryptionTLS (roughly), character setsApplication
5 SessionConversations between programsSession managementApplication
4 TransportDelivery between programs, portsTCP, UDPTransport
3 NetworkAddressing and routing across networksIP (IPv4, IPv6), ICMPInternet
2 Data linkDelivery on the local networkEthernet, Wi-Fi frames, MAC addressesLink
1 PhysicalSignals on a wire or radioCables, radio wavesLink

IP addresses: where

Every device on a network has an IP address. IPv4 addresses look like 203.0.113.7; IPv6 addresses look like 2001:db8::7. Some ranges are reserved for private networks and never appear directly on the internet: 10.0.0.0/8, 172.16.0.0/12 and 192.168.0.0/16 (defined in RFC 1918). Your home router gives your devices private addresses and translates them to its single public address when they go online. Recognising private addresses matters in security: a connection to 192.168.1.20 stays inside your home or office, a connection to a public address leaves it.

TCP and UDP: how

The transport layer offers two main services. TCP (Transmission Control Protocol) sets up a connection with a handshake, numbers every byte, resends what is lost and delivers everything in order: ideal for web pages, email and file transfers. UDP (User Datagram Protocol) just sends packets with no guarantees: ideal for voice, video, games and DNS lookups, where speed matters more than perfection. QUIC, the protocol behind HTTP/3, builds reliability on top of UDP.

Ports: which program

An IP address gets data to a computer; a port number (0 to 65535) gets it to the right program on that computer. Servers listen on well-known ports registered with IANA, so clients know where to knock. Your side of the connection uses a temporary high-numbered port chosen by the operating system.

PortProtocolSecurity note
22 TCPSSH (remote login)Encrypted; a favourite target for password guessing when exposed
25, 587 TCPSMTP (sending email)Server-to-server mail and submission
53 UDP/TCPDNSName lookups; can be abused to smuggle data out
80 TCPHTTPUnencrypted web; anyone on the path can read it
443 TCP/UDPHTTPS (and HTTP/3 over UDP)Encrypted web; most traffic today, including most attacker traffic
445 TCPSMB (file sharing)Should never be exposed to the internet
3389 TCPRDP (Windows remote desktop)Frequent ransomware entry point when exposed
5900 TCPVNC / screen sharingKeep on trusted networks only

Why ports alone are no longer enough

Traditional firewalls decided mostly by address and port: allow 443, block 3389. Today almost everything, good and bad, travels over port 443 inside encrypted HTTPS, so “port 443 is allowed” says very little. That is why modern host firewalls also look at which application is making the connection. FireAI, for example, identifies each app by its code signature and lets you allow or deny that specific app, rather than a whole port. It can also read what an encrypted connection announces at its start, such as the website name, without ever decrypting the content.

A connection, end to end

  1. An app wants to reach example.com. It asks DNS (port 53) for the address.
  2. The operating system opens a TCP connection from a temporary port to that address on port 443.
  3. Your router forwards it, translating your private address to its public one.
  4. Routers across the internet pass the IP packets towards the destination.
  5. TLS encrypts the conversation; HTTP carries the actual request inside it.

Each of these steps is a place where security can be applied, and where an attacker might try to interfere. The next lessons look at the defences built around them.

Lo esencial

  • Layer models (OSI with 7 layers, TCP/IP with 4) split networking into jobs; layer numbers are everyday jargon.
  • IP addresses say where, TCP/UDP say how, ports say which program.
  • Private ranges (10/8, 172.16/12, 192.168/16) stay inside local networks.
  • Most traffic now uses port 443, so modern firewalls also judge which application connects.

Ponte a prueba

  1. 1. Which transport protocol resends lost data and delivers everything in order?

    • UDP
    • TCP — Correcto.
    • ICMP
    • DNS

    TCP sets up a connection, tracks every byte and retransmits losses. UDP sends without guarantees.

  2. 2. Which address belongs to a private network range defined in RFC 1918?

    • 8.8.8.8
    • 192.168.1.20 — Correcto.
    • 203.0.113.7
    • 17.253.1.1

    192.168.0.0/16 is one of the three private IPv4 ranges, along with 10.0.0.0/8 and 172.16.0.0/12.

  3. 3. Why is “allow port 443” no longer a meaningful security rule on its own?

    • Port 443 is unused today
    • Almost all traffic, legitimate and malicious, now travels over HTTPS on port 443 — Correcto.
    • Port 443 is always blocked by routers
    • HTTPS cannot be encrypted

    Because nearly everything uses 443, the port says little; knowing which application connects is far more useful.

Ponlo en práctica con FireAI

Pon esta lección en práctica en tu propia computadora.

Fuentes

Ponlo en práctica en tu Mac

Prueba todas las funciones gratis durante 17 días, sin tarjeta.

Descargar para Mac Docs