Wiki DE Start in the browser

Wiki › Basics

Structure of frames and packets

How Ethernet frames, IPv4 and IPv6 packets, TCP segments and UDP datagrams nest inside each other, field by field according to the standards, with real bytes from leyoNET.

Layer
1 bis 7
Standard
IEEE 802.3, IEEE 802.1Q, IEEE 802.2 …
See an example
2 demos

Nesting

Every layer wraps the data of the layer above: it puts its header in front and treats everything else as payload. Only Ethernet also appends something at the end: the checksum FCS. On the wire, preamble and SFD come before it and a short gap after it. That is layer 1, no capture shows it.

Real frame from the demo “DNS, TCP and HTTP” (no. 36, 158 bytes), exactly as the packet list in leyoNET shows it.

With “Wrap the next layer” the frame is built step by step, just as in the sender: at the top the HTTP request, at the bottom the bits on the cable. The receiver unpacks in reverse order. A switch only opens the layer 2 envelope, a router also the layer 3 envelope (see OSI model and encapsulation).

LayerData unitHeader containsExample
7 Applicationdatadepends on the serviceHTTP request, DNS query
4 Transportsegment (TCP), datagram (UDP)portsTCP 20 bytes, UDP 8 bytes
3 NetworkpacketIP addresses, TTLIPv4 20 bytes, IPv6 40 bytes
2 Data linkframeMAC addresses, type; FCS at the endEthernet 14 + 4 bytes
1 Physicalbitspreamble, SFD8 bytes before every frame

A frame as leyoNET shows it

This frame comes from the simulation. The packet list shows every frame exactly like this: the application at the top, the physical layer at the bottom, every layer in its colour. Below are the bytes as they are on the wire.

7Application
HTTP · 100 B
GET /stundenplan.html HTTP/1.1
GET /stundenplan.html HTTP/1.1↵
Host: www.schule.example↵
User-Agent: leyoNET↵
Connection: close↵
↵
6Presentation
part of the application in TCP/IP
5Session
part of the application in TCP/IP
4Transport
TCP · 120 B
49152
80 (HTTP)
11001
51001
20 Bytes, [PSH, ACK]
64240
0xeed9
0

Sequence and acknowledgement numbers count bytes. Fixed window, no congestion control.

3Network
IPv4 · 140 B
4, 20 Bytes
0x00 (Best Effort)
140
0x0006
0x4000 (Don't Fragment)
64
6 (TCP)
0x9aa7
192.168.10.100
192.168.20.10
2Data link
Ethernet II · 158 B
02:00:00:00:04:00
02:00:00:00:01:00
0x0800 (IPv4)
0x9facebdb (CRC-32)

Ethernet frame per IEEE 802.3: header (14 bytes, 18 with an 802.1Q tag), payload (at least 46 bytes, padded otherwise) and at the end the frame check sequence FCS (CRC-32, 4 bytes). Preamble and SFD belong to layer 1. Many captures omit the FCS because the network card strips it first.

1Physical
1000BASE-T (IEEE 802.3ab)
1000BASE-T (IEEE 802.3ab)
1 Gbit/s
PAM-5, 4 pairs, RJ45
158
178 (+ preamble, SFD, IFG)

On the wire: preamble (7 bytes) and SFD (1 byte), then the frame including FCS, followed by a 12-byte interframe gap.

Point at a field: its bytes light up in the hex view below.

000002000000040002000000010008004500··············E·
0010008c0006400040069aa7c0a80a64c0a8····@·@······d··
0020140ac000005000002af90000c7395018·····P··*····9P·
0030faf0eed90000474554202f7374756e64······GET /stund
0040656e706c616e2e68746d6c2048545450enplan.html HTTP
00502f312e310d0a486f73743a207777772e/1.1··Host: www.
0060736368756c652e6578616d706c650d0aschule.example··
0070557365722d4167656e743a206c65796fUser-Agent: leyo
00804e45540d0a436f6e6e656374696f6e3aNET··Connection:
009020636c6f73650d0a0d0adbebac9f close········
Real frame from the demo “DNS, TCP and HTTP” (no. 36, 158 bytes), exactly as the packet list in leyoNET shows it.

The Ethernet frame

Ethernet frames according to IEEE 802.3 are at least 64 bytes and at most 1518 bytes long (1522 with a VLAN tag), counted from the destination MAC up to and including the FCS. If the packet is shorter than 46 bytes, the sender pads it with zeros, as with every ARP request. The FCS (frame check sequence) is a CRC-32 over the whole frame. The receiver recomputes it; if it does not match, it drops the frame silently. Ethernet leaves error handling to the upper layers.

Ethernet IIFrame · IEEE 802.3
Preamble7 bytes
SFD1 bytes
Destination MAC6 bytes02:00:00:00:04:00
Source MAC6 bytes02:00:00:00:01:00
EtherType2 bytes0x0800
Payload46–1500 bytes140 Byte
FCS4 bytes0x9facebdb
Gap (IFG)12 bytes
Left to right, in the order the bytes are sent. Grey dashed: never part of a capture (layer 1 or line framing). Point at a field for an explanation.
FieldLengthExample valueMeaning
Preamble (layer 1)7 bytes10101010 × 7Seven bytes 10101010: the receiver synchronises its clock. Part of the physical layer.
SFD (layer 1)1 bytes10101011Start frame delimiter 10101011: the frame starts now.
Destination MAC6 bytes02:00:00:00:04:00To whom? FF:FF:FF:FF:FF:FF is broadcast, a first byte with the lowest bit set is multicast.
Source MAC6 bytes02:00:00:00:01:00From whom? The MAC address of the sending interface; the switch learns it.
EtherType2 bytes0x0800What is inside: 0x0800 IPv4, 0x86DD IPv6, 0x0806 ARP, 0x8100 VLAN tag, 0x8864 PPPoE. Values from 0x0600 are types, smaller ones a length (IEEE 802.3).
Payload46–1500 bytes140 ByteThe layer-3 packet, 46 to 1500 bytes (MTU). If it is shorter, the sender pads with zeros so the frame including FCS is 64 bytes long.
FCS4 bytes0x9facebdbFrame check sequence: CRC-32 over the whole frame from the destination MAC. If it does not match, the receiver drops the frame.
Gap (IFG) (layer 1)12 bytesAt least 12 bytes of silence before the next frame (interframe gap). Part of the physical layer.
Values: Real frame from the demo “DNS, TCP and HTTP” (no. 36, 158 bytes), exactly as the packet list in leyoNET shows it.

Many captures do not show the FCS because the network card checks and strips it first. leyoNET shows it and also writes it into the pcapng file (with the note “4 bytes FCS” for Wireshark).

With a VLAN tag

On a trunk a 4-byte tag according to IEEE 802.1Q sits between source MAC and EtherType. It starts with 0x8100, followed by priority and VLAN number (see VLANs and trunks).

802.1QTag in the frame · IEEE 802.1Q
0481216202428
TPID16 bits0x8100
PCP3 bits0
DEI1 bit0
VLAN ID12 bits10
Each row has 32 bits (4 bytes), bit 0 on the left, as the RFCs draw their headers. Dashed: variable or optional. Point at a field for an explanation.
FieldLengthExample valueMeaning
TPID16 bits (2 bytes)0x8100Tag protocol identifier 0x8100: a VLAN tag follows instead of the EtherType.
PCP3 bits0Priority code point: priority 0 to 7 for quality of service (e.g. voice higher).
DEI1 bit0Drop eligible indicator: this frame may be dropped first when congested.
VLAN ID12 bits10VLAN number 1 to 4094 (0 and 4095 are reserved).
Values: Real frame from the demo “Router on a stick” (no. 7, 82 bytes), exactly as the packet list in leyoNET shows it.
Ethernet II + 802.1QFrame · IEEE 802.3, IEEE 802.1Q
Preamble7 bytes
SFD1 bytes
Destination MAC6 bytes02:00:00:00:01:00
Source MAC6 bytes02:00:00:00:03:00
TPID2 bytes0x8100
TCI2 bytes0x000a
EtherType2 bytes0x0800
Payload42–1500 bytes60 Byte
FCS4 bytes0xc04af1d0
Gap (IFG)12 bytes
Left to right, in the order the bytes are sent. Grey dashed: never part of a capture (layer 1 or line framing). Point at a field for an explanation.
FieldLengthExample valueMeaning
Preamble (layer 1)7 bytes10101010 × 7Seven bytes 10101010: the receiver synchronises its clock. Part of the physical layer.
SFD (layer 1)1 bytes10101011Start frame delimiter 10101011: the frame starts now.
Destination MAC6 bytes02:00:00:00:01:00To whom? FF:FF:FF:FF:FF:FF is broadcast, a first byte with the lowest bit set is multicast.
Source MAC6 bytes02:00:00:00:03:00From whom? The MAC address of the sending interface; the switch learns it.
TPID2 bytes0x8100Tag protocol identifier 0x8100: a VLAN tag follows instead of the EtherType.
TCI2 bytes0x000aTag control information: priority (PCP), DEI and VLAN ID, 16 bits together.
EtherType2 bytes0x0800What is inside: 0x0800 IPv4, 0x86DD IPv6, 0x0806 ARP, 0x8100 VLAN tag, 0x8864 PPPoE. Values from 0x0600 are types, smaller ones a length (IEEE 802.3).
Payload42–1500 bytes60 ByteThe layer-3 packet. Because of the 4-byte tag, 42 bytes are enough for the minimum length of 64 bytes.
FCS4 bytes0xc04af1d0Frame check sequence: CRC-32 over the whole frame from the destination MAC. If it does not match, the receiver drops the frame.
Gap (IFG) (layer 1)12 bytesAt least 12 bytes of silence before the next frame (interframe gap). Part of the physical layer.
Values: Real frame from the demo “Router on a stick” (no. 7, 82 bytes), exactly as the packet list in leyoNET shows it.

IEEE 802.3 with LLC and SNAP

If the position of the EtherType holds a number up to 1500, it is a length. Then an LLC header according to IEEE 802.2 follows, which says which service the data is for. Spanning tree (STP) uses this form with DSAP and SSAP 0x42. With DSAP 0xAA a SNAP header with the EtherType follows (RFC 1042); this is how Wi-Fi and other IEEE 802 networks carry IP packets.

IEEE 802.3Frame · IEEE 802.3, IEEE 802.2, RFC 1042
Preamble7 bytes
SFD1 bytes
Destination MAC6 bytes01:80:c2:00:00:00
Source MAC6 bytes02:00:00:00:01:06
Length2 bytes38
DSAP1 bytes0x42
SSAP1 bytes0x42
Control1 bytes0x03
OUI3 bytes
Type (SNAP)2 bytes
Payload38–1497 bytes43 Byte
FCS4 bytes0x182ad55e
Gap (IFG)12 bytes
Left to right, in the order the bytes are sent. Grey dashed: never part of a capture (layer 1 or line framing). Point at a field for an explanation.
FieldLengthExample valueMeaning
Preamble (layer 1)7 bytes10101010 × 7Seven bytes 10101010: the receiver synchronises its clock. Part of the physical layer.
SFD (layer 1)1 bytes10101011Start frame delimiter 10101011: the frame starts now.
Destination MAC6 bytes01:80:c2:00:00:00To whom? FF:FF:FF:FF:FF:FF is broadcast, a first byte with the lowest bit set is multicast.
Source MAC6 bytes02:00:00:00:01:06From whom? The MAC address of the sending interface; the switch learns it.
Length2 bytes38Length of the payload in bytes (at most 1500). This tells the receiver it is an IEEE 802.3 frame with LLC instead of Ethernet II.
DSAP1 bytes0x42Destination service access point (IEEE 802.2 LLC): for whom at the other end. 0x42 = spanning tree, 0xAA = SNAP follows.
SSAP1 bytes0x42Source service access point: from which service, usually the same as DSAP.
Control1 bytes0x03LLC control, 0x03 = unnumbered information (without acknowledgement).
OUI (optional)3 bytesOnly with SNAP (DSAP 0xAA): organisation identifier, 00-00-00 for EtherType values (RFC 1042).
Type (SNAP) (optional)2 bytesOnly with SNAP: the EtherType of the payload, e.g. 0x0800 for IPv4. This is how Wi-Fi and other LLC networks carry IP.
Payload38–1497 bytes43 ByteThe payload, e.g. a spanning tree BPDU. Shorter frames are padded to 64 bytes.
FCS4 bytes0x182ad55eFrame check sequence: CRC-32 over the whole frame from the destination MAC. If it does not match, the receiver drops the frame.
Gap (IFG) (layer 1)12 bytesAt least 12 bytes of silence before the next frame (interframe gap). Part of the physical layer.
Values: Real frame from the demo “VLAN and spanning tree” (no. 1, 64 bytes), exactly as the packet list in leyoNET shows it.

Wi-Fi frames

A Wi-Fi frame according to IEEE 802.11 has up to four addresses, because sender and receiver on the radio link are not always source and destination (the access point is in between). It also ends with a CRC-32 FCS. Data travels with LLC/SNAP and encrypted with WPA2.

IEEE 802.11Frame · IEEE 802.11
Frame Control2 bytes0x4000
Duration/ID2 bytes314
Address 16 bytes02:00:00:00:03:02
Address 26 bytes02:00:00:00:05:00
Address 36 bytes02:00:00:00:03:02
Sequence Control2 bytes0x0010
Address 46 bytes
QoS Control2 bytes
Frame Body0–2304 bytes21 Byte
FCS4 bytes0x2b56a31f
Left to right, in the order the bytes are sent. Grey dashed: never part of a capture (layer 1 or line framing). Point at a field for an explanation.
FieldLengthExample valueMeaning
Frame Control2 bytes0x4000Frame type (management, control, data), subtype and bits such as To DS/From DS, retry and protected (encrypted).
Duration/ID2 bytes314How long the medium remains busy (in microseconds); other stations wait that long.
Address 16 bytes02:00:00:00:03:02Receiver on the radio link (receiver address).
Address 26 bytes02:00:00:00:05:00Transmitter on the radio link (transmitter address).
Address 36 bytes02:00:00:00:03:02Depending on To DS/From DS the BSSID of the access point or the actual source or destination in the LAN.
Sequence Control2 bytes0x0010Fragment and sequence number: detects duplicates after a retransmission.
Address 4 (optional)6 bytesOnly between two access points (To DS and From DS set, e.g. wireless bridge or mesh).
QoS Control (optional)2 bytesOnly for QoS data: priority (traffic class) of the frame, basis of WMM.
Frame Body0–2304 bytes21 ByteManagement data (SSID, rates, security) or, for data, LLC/SNAP and the packet; encrypted with WPA2.
FCS4 bytes0x2b56a31fCRC-32 over header and body, as with Ethernet. Radio is error-prone: faulty frames are retransmitted.
Values: Real frame from the demo “Wi-Fi with mesh” (no. 1, 49 bytes), exactly as the packet list in leyoNET shows it.

PPP on serial lines

A point-to-point line needs no MAC addresses. PPP in HDLC-like framing (RFC 1662) puts flags 0x7E at the start and end, a fixed address and control field, the protocol and at the end a 16-bit FCS (see Serial lines: HDLC, PPP and PPPoE).

PPP (RFC 1662)Frame · RFC 1662, RFC 1661
Flag1 bytes0x7E
Address1 bytes0xff
Control1 bytes0x03
Protocol2 bytes0x0021
Information≤ 1500 bytes60 Byte
FCS2 bytes0xef53
Flag1 bytes0x7E
Left to right, in the order the bytes are sent. Grey dashed: never part of a capture (layer 1 or line framing). Point at a field for an explanation.
FieldLengthExample valueMeaning
Flag (framing, not in captures)1 bytes0x7E0x7E marks the start and end of every frame on the line.
Address1 bytes0xffAlways 0xFF (all stations): a point-to-point line has only one other end.
Control1 bytes0x03Always 0x03 (unnumbered information).
Protocol2 bytes0x0021What is inside: 0x0021 IPv4, 0x0057 IPv6, 0xC021 LCP, 0x8021 IPCP (RFC 1661).
Information≤ 1500 bytes60 ByteThe packet or control message, at most 1500 bytes without negotiation (MRU).
FCS2 bytes0xef53Checksum FCS-16 over address to information (FCS-32 on request).
Flag (framing, not in captures)1 bytes0x7EClosing flag 0x7E (can also open the next frame).
Values: Real frame from the demo “Serial WAN link with PPP” (no. 12, 66 bytes), exactly as the packet list in leyoNET shows it.

The IPv4 packet

Without options the IPv4 header according to RFC 791 is 20 bytes long. Routers mainly read the destination IP (for the path) and the TTL (against loops). The checksum only covers the header; because every router lowers the TTL, it recomputes it. DSCP and ECN (formerly “type of service”) are defined in RFC 2474 and RFC 3168.

IPv4Packet · RFC 791, RFC 2474, RFC 3168
0481216202428
Version4 bits4
IHL4 bits5
DSCP6 bits0
ECN2 bits0
Total length16 bits140
Identification16 bits0x0006
Flags3 bitsDF
Fragment offset13 bits0
TTL8 bits64
Protocol8 bits6
Header checksum16 bits0x9aa7
Source IP32 bits192.168.10.100
Destination IP32 bits192.168.20.10
Options0–40 bytes
Payload≤ 65515 bytes120 Byte
Each row has 32 bits (4 bytes), bit 0 on the left, as the RFCs draw their headers. Dashed: variable or optional. Point at a field for an explanation.
FieldLengthExample valueMeaning
Version4 bits44 for IPv4.
IHL4 bits5Internet header length in 32-bit words: 5 = 20 bytes without options.
DSCP6 bits0Differentiated services: traffic class for quality of service (RFC 2474), 0 = best effort.
ECN2 bits0Explicit congestion notification: routers signal congestion without dropping packets (RFC 3168).
Total length16 bits (2 bytes)140Length of header and payload in bytes, at most 65,535.
Identification16 bits (2 bytes)0x0006Packet number; all fragments of a packet carry the same one.
Flags3 bitsDFBit 0 reserved, DF = don't fragment, MF = more fragments follow.
Fragment offset13 bits0Position of the fragment in the original packet, in steps of 8 bytes.
TTL8 bits64Time to live: each router subtracts 1; at 0 the packet is dropped (ICMP time exceeded).
Protocol8 bits6What is inside: 1 ICMP, 6 TCP, 17 UDP, 50 ESP, 89 OSPF.
Header checksum16 bits (2 bytes)0x9aa7Checksum over the header only (RFC 1071); each router recalculates it because of the TTL.
Source IP32 bits (4 bytes)192.168.10.100Sender, unchanged along the whole path (except with NAT).
Destination IP32 bits (4 bytes)192.168.20.10Destination, routers decide the path by it.
Options (optional)0–40 bytesRarely used (e.g. record route); IHL is then greater than 5.
Payload≤ 65515 bytes120 ByteThe segment or message of the next layer (TCP, UDP, ICMP …).
Values: Real frame from the demo “DNS, TCP and HTTP” (no. 36, 158 bytes), exactly as the packet list in leyoNET shows it.

The IPv6 packet

The IPv6 header according to RFC 8200 is always 40 bytes long; the addresses alone take 32 of them. It is simpler than IPv4: no checksum (Ethernet and TCP/UDP take care of that), no fragmentation by routers, options only as extension headers behind the header (next header).

IPv6Packet · RFC 8200, RFC 2474, RFC 3168
0481216202428
Version4 bits6
Traffic class8 bits0x00
Flow label20 bits0x00000
Payload length16 bits32
Next header8 bits17
Hop limit8 bits255
Source IPv6128 bitsfe80::ff:fe00:301
Destination IPv6128 bitsff02::9
Payload≤ 65535 bytes32 Byte
Each row has 32 bits (4 bytes), bit 0 on the left, as the RFCs draw their headers. Dashed: variable or optional. Point at a field for an explanation.
FieldLengthExample valueMeaning
Version4 bits66 for IPv6.
Traffic class8 bits0x00Like DSCP and ECN in IPv4: traffic class and congestion notification.
Flow label20 bits0x00000Marks packets of one flow so routers treat them alike; 0 = none.
Payload length16 bits (2 bytes)32Length after the 40-byte header (extension headers and data).
Next header8 bits17What follows: 6 TCP, 17 UDP, 58 ICMPv6, or an extension header (e.g. 44 fragment).
Hop limit8 bits255Like TTL in IPv4: each router subtracts 1.
Source IPv6128 bits (16 bytes)fe80::ff:fe00:301Sender, 128 bits.
Destination IPv6128 bits (16 bytes)ff02::9Destination, 128 bits; multicast instead of broadcast (e.g. ff02::1).
Payload≤ 65535 bytes32 ByteExtension headers and the next-layer segment. No header checksum, no fragmentation by routers.
Values: Real frame from the demo “RIPng for IPv6” (no. 1, 90 bytes), exactly as the packet list in leyoNET shows it.
IPv4IPv6
Header length20 to 60 bytesfixed 40 bytes
Addresses32 bits128 bits
LifetimeTTLhop limit
What followsprotocolnext header
Checksum in the headeryesno
Fragmentationsender and routerssender only

The TCP segment

Without options the TCP header according to RFC 9293 is 20 bytes long. Sequence and acknowledgement numbers count bytes; the flags control setup (SYN), acknowledgement (ACK) and teardown (FIN) of the connection (see TCP).

TCPSegment · RFC 9293
0481216202428
Source port16 bits49152
Destination port16 bits80
Sequence number32 bits11001
Acknowledgment number32 bits51001
Data offset4 bits5
Reserved4 bits0
Flags8 bitsACK, PSH
Window16 bits64240
Checksum16 bits0xeed9
Urgent pointer16 bits0
Options0–40 bytes
Datavariable100 Byte
Each row has 32 bits (4 bytes), bit 0 on the left, as the RFCs draw their headers. Dashed: variable or optional. Point at a field for an explanation.
FieldLengthExample valueMeaning
Source port16 bits (2 bytes)49152Port of the sending program, usually random from 49152 on the client.
Destination port16 bits (2 bytes)80Port of the service: 80 HTTP, 443 HTTPS, 22 SSH, 25 SMTP.
Sequence number32 bits (4 bytes)11001Number of the first data byte in this segment; with SYN the random initial number.
Acknowledgment number32 bits (4 bytes)51001The next byte expected (valid when ACK is set).
Data offset4 bits5Header length in 32-bit words: 5 = 20 bytes without options.
Reserved4 bits0Reserved, always 0.
Flags8 bitsACK, PSHSYN open, ACK acknowledgement valid, FIN close, RST abort, PSH push immediately, URG, ECE and CWR for congestion.
Window16 bits (2 bytes)64240How many bytes the other side may still send without acknowledgement (flow control).
Checksum16 bits (2 bytes)0xeed9Checksum over header, data and a pseudo header with the IP addresses.
Urgent pointer16 bits (2 bytes)0Only with URG: end of urgent data; hardly used today.
Options (optional)0–40 bytesE.g. MSS (maximum segment size), window scale, SACK, timestamps; mostly in the SYN.
Datavariable100 ByteThe application data, e.g. the HTTP request.
Values: Real frame from the demo “DNS, TCP and HTTP” (no. 36, 158 bytes), exactly as the packet list in leyoNET shows it.

The UDP datagram

UDP according to RFC 768 has only 8 bytes of header: two ports, length, checksum. No connection, no acknowledgement (see UDP).

UDPDatagram · RFC 768
0481216202428
Source port16 bits521
Destination port16 bits521
Length16 bits32
Checksum16 bits0xfafd
Datavariable24 Byte
Each row has 32 bits (4 bytes), bit 0 on the left, as the RFCs draw their headers. Dashed: variable or optional. Point at a field for an explanation.
FieldLengthExample valueMeaning
Source port16 bits (2 bytes)521Port of the sending program (may be 0 if no reply is expected).
Destination port16 bits (2 bytes)521Port of the service: 53 DNS, 67/68 DHCP, 520 RIP, 521 RIPng, 4789 VXLAN.
Length16 bits (2 bytes)32Header and data in bytes, at least 8.
Checksum16 bits (2 bytes)0xfafdChecksum with pseudo header; may be 0 (none) with IPv4, mandatory with IPv6.
Datavariable24 ByteThe application message, e.g. a DNS query.
Values: Real frame from the demo “RIPng for IPv6” (no. 1, 90 bytes), exactly as the packet list in leyoNET shows it.

Sizes and checksums at a glance

WhatSizeWhy
Ethernet MTU1500 byteslargest packet in one frame
Ethernet frame64 to 1518 bytesheader 14 + payload 46–1500 + FCS 4
additionally on the wire20 bytespreamble 7, SFD 1, gap 12
MSS for TCP over IPv41460 bytes1500 − 20 (IPv4) − 20 (TCP)
MSS for TCP over IPv61440 bytes1500 − 40 (IPv6) − 20 (TCP)
ChecksumLayercoverswho checks
FCS (CRC-32)2the whole frameevery network card, every switch
IPv4 header checksum3only the IPv4 headerevery router
TCP and UDP checksum4header, data and the IP addresses (pseudo header)only the destination

See an example

  • Demo “DNS, TCP and HTTP” in leyoNETDemo “DNS, TCP and HTTP” in leyoNET
    Slow motion This is how it looks in the simulation: every dot is a frame on the cable.
    DNS, TCP and HTTP

    A notebook fetches a web page through a router.

    DNS query for www.schule.example, TCP handshake (SYN, SYN-ACK, ACK) and the HTTP request in the browser.

    Watch live Project file

  • Demo “Router on a stick” in leyoNETDemo “Router on a stick” in leyoNET
    Router on a stick

    Two VLANs, one router with subinterfaces on the trunk.

    The packet goes tagged to the router (eth0.10) and comes out in the other VLAN (eth0.20).

    Watch live Project file

“Watch live” opens the network in leyoNET, the simulation runs in a loop. In the app you find it under File → Demo networks, with a step-by-step tour.

What leyoNET simplifies

ProtocolLayerSimplification in the simulation
Ethernet II, 802.1Q2With FCS (CRC-32) and padding to 64 bytes; preamble, SFD and gap only as information on layer 1; no jumbo frames
IPv43No fragmentation (MSS 1460 prevents it), no options
IPv63No extension headers, no fragmentation, no flow labels; link-local via EUI-64 (RFC 4291), over Ethernet with multicast MAC 33:33:… (RFC 2464)
TCP4Three-way handshake, sequence numbers in bytes, MSS 1460, retransmission after 1 s (at most three times), FIN/RST; fixed window size, no congestion control
UDP4none

Standards

  • IEEE 802.3 – IEEE Standard for Ethernet (current edition: IEEE 802.3-2022)
  • IEEE 802.1Q – Bridges and Bridged Networks (current edition: IEEE 802.1Q-2022)
  • IEEE 802.2 – Logical Link Control (ISO/IEC 8802-2) (current edition: ISO/IEC 8802-2:1998 (IEEE 802.2-1998))
  • IEEE 802.11 – Wireless LAN Medium Access Control (MAC) and Physical Layer (PHY) Specifications (current edition: IEEE 802.11-2024)
  • RFC 791 – Internet Protocol
  • RFC 8200 – Internet Protocol, Version 6 (IPv6) Specification
  • RFC 9293 – Transmission Control Protocol (TCP)
  • RFC 768 – User Datagram Protocol
  • RFC 826 – An Ethernet Address Resolution Protocol
  • RFC 1042 – A Standard for the Transmission of IP Datagrams over IEEE 802 Networks
  • RFC 1662 – PPP in HDLC-like Framing
  • RFC 2474 – Definition of the Differentiated Services Field (DS Field) in the IPv4 and IPv6 Headers
  • RFC 3168 – The Addition of Explicit Congestion Notification (ECN) to IP

Read on

Found a mistake or have an idea? Source of this page on GitHub.