A set of cheetsheets for Ethernet, IPv4, UDP, TCP and ICMP protocol headers.
64
bytes and a maximum size of 1,518
bytes.64
byte minimum is interpreted by receivers as a collision. The Ethernet frame payload may not exceed 1,500
bytes.42
bytes when an 802.1q tag is present, or 46
bytes if 802.1q tags are not used.1,500
.64
bytes in length, padding is added accordingly.2^12
). See here for more information.Description | Value | Explanation |
---|---|---|
Basic frame size | 64 bytes upto 1,518 bytes |
1,538 bytes on the wire |
Q-tagged (802.1q) frame size | 64 bytes upto 1,522 bytes |
1,542 bytes on the wire |
Envelope frame size | 64 bytes upto 2,000 bytes |
|
Maximum frame payload without fragmentation | 1,500 bytes |
|
Minimum frame payload | 46 bytes |
|
Minimum frame payload with 802.Q tag | 42 bytes |
0000
) to 15 (Binary 1111
). So the longest the IP header size can be is upto 480 bits, which is 60 bytes. The shortest header size is 5 dwords (20 bytes), where the IHL field has the value of 5 (Binary 0101
). This is because all of the required fields in the header require 20 bytes as a minimum.Description | Value | Explanation |
---|---|---|
Maximum IPv4 payload size without fragmentation | 1,480 bytes |
Maximum Ethernet frame size at 1,500 bytes minus IPv4 header at 20 bytes |
Maximum legal IPv4 payload size | 65,515 bytes |
Maximum IPv4 packet size at 65,535 bytes (x0FFFF) minus IPv4 header at 20 bytes |
Description | Value | Explanation |
---|---|---|
Maximim TCP payload size without fragmentation | 1,460 bytes |
Maximum Ethernet frame size at 1,500 bytes minus IPv4 header at 20 bytes minus TCP header at 20 bytes |
Maximum legal TCP payload size | 65,495 bytes |
Maximum IPv4 packet size at 65,535 bytes (x0FFFF) minus IPv4 header at 20 bytes minus TCP header at 20 bytes |
65,507
bytes for IPv4 and 65,527
bytes for IPv6Description | Value | Explanation |
---|---|---|
Maximim UDP payload size without fragmentation | 1,472 bytes |
Maximum Ethernet frame size at 1,500 bytes minus IPv4 header at 20 bytes minus UDP header at 8 bytes |
Maximum legal UDP payload size | 65,507 bytes |
Maximum IPv4 packet size at 65,535 bytes (x0FFFF) minus IPv4 header at 20 bytes minus UDP header at 8 bytes |
Description | Value | Explanation |
---|---|---|
Maximum ICMP payload size without fragmentation | 1,472 bytes |
Maximum single Ethernet frame at 1,500 bytes minus IPv4 header at 20 bytes minus ICMP header at 8 bytes |
Maximum legal ICMP payload size | 65,507 bytes |
Maximum IPv4 packet size at 65,535 bytes (x0FFFF) minus IPv4 header at 20 bytes minus ICMP header at 8 bytes |
Original drawings and source at https://github.com/pingfu/ethernet-cheatsheet. Content licensed under CC-BY 3.0, code licensed under MIT. Diagrams created using the excellent https://www.draw.io/
Knock knock
Race condition
Who's there?