Skip to main content
← Protocol Attack Lab
TCP / 01
Free · no login
Defensive simulation

TCP & the SYN flood

A handshake. A memory promise. A flood of ghosts.

TCP packet topologyLaptop198.51.100.2350432BotnetForged sourceaddressesInternetPacket routingFirewallService boundaryWeb server203.0.113.10443SYN — inspect packetSYN
1/5

Half-open connections (SYN queue)

0/32

Illustrative 32-slot queue; actual capacity depends on server configuration.

How it works / 01

Ask to connect — SYN.

The laptop asks to open a connection.

The laptop picks a random initial sequence number (ISN) and sends a SYN to 203.0.113.10 port 443. Its options say what it can handle: max segment 1460 bytes, SACK, timestamps, window scaling.

Flags
SYN
Seq
2976301512 (relative 0)
Window
64240
TTL
64
Packet
60 bytes

Packet Inspector / syn

Checksum ✓ valid

IPv4 + TCP · 60 bytes

0000
0010
0020
0030

Packets are shown as the sender built them. All addresses are reserved documentation ranges.

IPv4 header: 20 bytes. TCP follows, including any negotiated options.

Field / offsetValue
Version / IHL0–0

IPv4 version and the length of the IP header.

IPv4 / 5 words (20 bytes)
DSCP / ECN1–1

Traffic class and congestion indication.

0
Total length2–3

Entire IPv4 packet, including the TCP header and payload.

60 bytes
Identification4–5

Identifier used to reassemble IP fragments.

0x1c46
Flags / fragment offset6–7

Do not fragment (DF); this packet is not a fragment.

DF on / offset 0
TTL8–8

Hop limit; each router lowers it by one. Shown as the sender set it (Linux and macOS start at 64, Windows at 128).

64
Protocol9–9

IP protocol number for TCP.

6 (TCP)
IP header checksum10–11

One’s-complement checksum covers the IPv4 header.

b820
Source IP12–15

Address of the host that sent this packet.

198.51.100.23
Destination IP16–19

Address of the receiving host.

203.0.113.10
Source port20–21

Ephemeral port the client picked for this one connection.

50432
Destination port22–23

Service port: 443 is HTTPS.

443
Sequence number24–27

Initial sequence number (ISN), chosen at random. The SYN itself uses up one number.

2976301512 (relative 0)
Acknowledgment number28–31

Unused: the ACK flag is off, so the field is 0.

0
Data offset / reserved32–32

Length of the TCP header including options.

10 words
TCP flags33–33

Asks to open a connection.

SYN
Window size34–35

Receive window. Never scaled in SYN segments.

64240
TCP checksum36–37

Covers the TCP header, payload, and IPv4 pseudo-header (addresses, protocol and TCP length).

67be
Urgent pointer38–39

Only meaningful when the URG flag is set.

0
MSS40–43

Maximum TCP segment payload the sender can receive.

1460 bytes
SACK permitted44–45

Selective acknowledgments identify blocks already received.

Yes
Timestamps46–55

Sender's clock value; echo is 0 because nothing has been received yet.

3828441310 / echo 0
NOP56–56

One-byte alignment padding.

1
Window scale57–59

Negotiated shift multiplier for later advertised windows.

7 (× 128)

Exam & detection mappings

Security+ SY0-701 · 2.4 — Analyze indicators of malicious activity: DDoS
Security+ SY0-701 · 4.4 — Security alerting and monitoring
Security+ SY0-701 · 4.9 — Data sources to support an investigation

Knowledge check

1. A SYN flood mainly exhausts…
2. Why is blocking the top source IPs weak here?
3. 40,000 SYN/s, 0.3% handshakes completed, 39,000 sources: flood or flash crowd?
4. How do SYN cookies survive the flood?