IPv4 vs IPv6: 32-bit vs 128-bit Addressing

Overview IPv4 and IPv6 are the two versions of the Internet Protocol responsible for addressing and routing packets across networks. IPv4 relies on 32-bit addresses that ran out of unique combinations, while IPv6 was designed around 128-bit addresses to give every device a globally unique, non-NAT’d address. The distinction matters because it affects address exhaustion, header processing overhead, and whether NAT traversal is required for peer-to-peer connectivity. Comparison Diagram IPv4IPv61921681132 bits · dotted-decimal20010db885a3000000008a2e03707334128 bits · hex colon-notation~4.3 billion addresses~340 undecillion addressesRelative address length32 bits (IPv4)128 bits (IPv6) — 4x longerNAT dependencyIPv4: needs NAT (scarce space)IPv6: end-to-end, no NAT needed Comparison Table Aspect IPv4 IPv6 Address length & notation 32-bit, dotted-decimal (e.g. 192.168.1.1) 128-bit, hexadecimal colon-separated (e.g. 2001:0db8::7334) Address space size ~4.3 billion addresses ~340 undecillion addresses Address assignment Manual configuration or DHCP Stateless Address Autoconfiguration (SLAAC) or DHCPv6 Header structure Variable-length header with options field and checksum Fixed 40-byte header, no checksum, optional extension headers NAT requirement Commonly required due to address scarcity Not needed; supports true end-to-end addressing Broadcast/discovery Uses broadcast (e.g. ARP) for local discovery Broadcast eliminated; uses multicast Neighbor Discovery Built-in security IPsec is an optional add-on IPsec support is part of the core protocol spec Adoption & compatibility Universally supported, legacy infrastructure Growing adoption, requires dual-stack or tunneling for legacy interop Key Differences IPv6 addresses are 128-bit, four times longer than IPv4’s 32-bit addresses, resolving address exhaustion IPv6 removes the need for NAT, restoring true end-to-end connectivity between hosts IPv6 uses a simplified, fixed-length header that speeds up router processing compared to IPv4’s variable header IPv6 replaces ARP broadcasts with Neighbor Discovery multicast for local address resolution When to Use Each IPv4 ...

August 1, 2026 · 2 min · 391 words · jeonck

HTTP/2 vs HTTP/3: Multiplexing Over TCP vs QUIC

Overview HTTP/2 and HTTP/3 both let a browser send many requests over one logical connection, but they diverge at the transport layer. HTTP/2 rides on TCP, inheriting its single ordered byte stream and its packet-loss stalls; HTTP/3 replaces that with QUIC over UDP, giving each stream independent loss recovery and letting connections survive network changes. Comparison Diagram HTTP/2 (TCP)HTTP/3 (QUIC/UDP)Stream AStream BStream CStream AStream BStream CSingle TCP connectionOne lost packet stalls every streamIndependent QUIC streamsLoss stalls only its own streamX = lost packet dashed = blocked/waiting Comparison Table Aspect HTTP/2 HTTP/3 Transport protocol Runs over TCP Runs over QUIC (built on UDP) Connection handshake Separate TCP handshake, then TLS handshake (1-2 RTT) TLS 1.3 is integrated into the QUIC handshake, often 1-RTT or 0-RTT on resumption Stream multiplexing Multiple streams share one ordered TCP byte stream Each stream is a distinct, independently-sequenced QUIC stream Head-of-line blocking A single lost TCP segment stalls delivery of every stream until it’s retransmitted Loss on one stream only stalls that stream; others keep flowing Header compression HPACK QPACK Connection identity and migration Bound to the source/destination IP and port 4-tuple; changing networks breaks it Bound to a connection ID; survives IP or network changes, e.g. Wi-Fi to cellular Congestion control and loss recovery Implemented in the OS kernel’s TCP stack Implemented in user-space by the QUIC library, easier to iterate on Network and middlebox support Ubiquitous; TCP port 443 is rarely blocked UDP is sometimes blocked or throttled by firewalls, requiring a TCP fallback Key Differences HTTP/2 multiplexes streams inside a single TCP connection, while HTTP/3 gives each stream its own loss-recovery in QUIC TCP’s in-order delivery means one dropped packet causes head-of-line blocking across all HTTP/2 streams; HTTP/3 avoids this by design HTTP/3 folds the transport and TLS handshakes together for faster 0-RTT setup on reconnection QUIC’s connection ID lets HTTP/3 sessions survive a client’s IP or network change without reconnecting HTTP/3 depends on UDP reaching the server, so restrictive middleboxes can force a fallback to HTTP/2 When to Use Each HTTP/2 ...

August 1, 2026 · 3 min · 445 words · jeonck

HTTP vs HTTPS: Plaintext vs Encrypted Web Traffic

Overview HTTP and HTTPS are the same application-layer protocol for transferring web resources, but HTTPS wraps every request and response in a TLS tunnel before it touches the network. That single layer determines whether credentials, cookies, and page content travel as plaintext visible to anyone on the path, or as ciphertext only the two endpoints can read. Comparison Diagram HTTPClientServerGET /login?pwd=hunter2visible to anyone on pathHTTPSClientServerx8f#9a2$qL0e...TLS-encrypted, tamper-evident Comparison Table Aspect HTTP HTTPS Default port 80 443 Connection establishment Single TCP three-way handshake TCP handshake plus a TLS handshake to negotiate cipher and exchange keys Certificate requirement None X.509 certificate issued by a trusted CA (or self-signed) required Data encryption Plaintext — headers, cookies, and body sent unencrypted Encrypted end-to-end using TLS/SSL symmetric ciphers Data integrity No built-in tamper detection MAC/AEAD in TLS detects in-transit tampering Browser indicator “Not secure” warning in modern browsers Padlock icon; no warning shown Performance overhead Lower — no crypto or extra round trip Slightly higher handshake/CPU cost, largely offset by TLS 1.3 and session resumption Typical use case Local development, internal tools on trusted networks, legacy static content Any production site, especially logins, payments, and APIs handling sensitive data Key Differences HTTPS is HTTP tunneled through TLS, not a separate application protocol HTTP traffic is readable in plaintext by anyone with network access; HTTPS traffic is encrypted HTTPS requires a valid certificate from a trusted CA to establish trust Modern browsers flag HTTP sites as not secure, pushing HTTPS as the default TLS 1.3 has shrunk the historical HTTPS handshake cost to near parity with plain TCP When to Use Each HTTP ...

August 1, 2026 · 2 min · 406 words · jeonck

TCP vs UDP: Reliable Streams vs Fast Datagrams

Overview TCP and UDP are the two core transport-layer protocols used to move data between hosts, but they trade reliability for speed in opposite directions. TCP prioritizes reliable delivery through handshakes, acknowledgments, and retransmission, while UDP prioritizes low-latency delivery by sending datagrams with no setup or delivery guarantees. Choosing between them shapes how an application handles packet loss, ordering, and throughput. Comparison Diagram TCPUDPClientServerSenderReceiverSYNSYN-ACKACKconnection establishedDataACKDataACKFIN / ACK teardownDatagramDatagramlost, no retryDatagramDatagramno ACKs, no ordering Comparison Table Aspect TCP UDP Connection setup Three-way handshake (SYN, SYN-ACK, ACK) establishes a stateful connection before any data moves No handshake — sender transmits datagrams immediately with no prior negotiation Delivery guarantee Guaranteed via sequence numbers and acknowledgments; lost segments are detected and resent Best-effort only; lost packets vanish silently with no notification to either side Ordering Segments are reassembled in the original order regardless of arrival sequence No ordering guarantee; packets are delivered to the application in whatever order they arrive Flow & congestion control Dynamic window sizing and congestion-avoidance algorithms throttle the sender to match network capacity None; the application sends at whatever rate it chooses, independent of network conditions Error handling Checksum plus automatic retransmission recovers corrupted or missing segments Checksum only; corrupted or missing packets are simply dropped, not recovered Overhead & latency Larger 20+ byte header and handshake/ACK round trips add processing and latency Minimal 8-byte header and no round trips keep per-packet overhead and latency low Connection teardown Explicit four-way FIN/ACK exchange formally closes the connection on both sides No connection state exists, so transmission simply stops with nothing to tear down Key Differences TCP is connection-oriented, requiring a handshake before data flows, while UDP is connectionless TCP guarantees reliable delivery through acknowledgments and retransmission; UDP offers none TCP performs congestion control to avoid overwhelming the network; UDP has no such mechanism UDP’s minimal header overhead gives it consistently lower latency than TCP TCP preserves packet ordering end-to-end; UDP delivers packets in whatever order they arrive When to Use Each TCP ...

August 1, 2026 · 3 min · 465 words · jeonck