Network latency and packet loss between routers often manifest as application failures before they appear in high-level metrics. When a web browser fails to load or an SSH session times out, the underlying cause is frequently a disruption in the TCP three-way handshake. This critical process establishes a connection between two hosts; if any segment of this exchange is lost or delayed, the connection never forms. By leveraging Wireshark for forensic analysis, IT professionals can pinpoint exactly where packets are dropping—whether due to congestion, misconfigured firewalls, or interface errors. This guide provides a practical approach to diagnosing these issues using a realistic lab scenario involving Packet Tracer and real-world Wireshark workflows.
Understanding the Three-Way Handshake Mechanics
Before diving into forensic analysis, it is essential to understand the baseline behavior of a successful TCP connection. The handshake involves three distinct packets:
1. SYN: The client sends a Synchronize (SYN) packet to initiate the connection.
2. SYN-ACK: The server responds with a Synchronize-Acknowledge (SYN-ACK) packet.
3. ACK: The client sends an Acknowledge (ACK) packet to confirm receipt and complete the handshake.
In a healthy network, these packets traverse routers and switches without issue. However, latency causes timeouts, while packet loss results in missing segments. If the SYN is lost, the server never replies. If the SYN-ACK is dropped by a router due to congestion or ACLs, the client times out waiting for a response that will never arrive. Wireshark allows you to visualize these gaps clearly.
Lab Setup: Simulating Inter-Routing Issues
To analyze drops effectively, you need a reproducible environment. While enterprise networks are complex, simulation tools like Cisco Packet Tracer or GNS3 provide safe spaces to induce faults. For this exercise, assume a topology with two subnets separated by a router:
* Client Subnet (192.168.10.0/24): Hosts a Linux machine acting as the client.
* Server Subnet (192.168.20.0/24): Hosts a target server (e.g., a Raspberry Pi or virtual machine).
* Router: A Cisco IOS device connecting the two VLANs via an inter-VLAN routing configuration.
Prerequisites and Safety
Ensure your test environment is isolated from production traffic to avoid disrupting live services. Use ping or traceroute initially to establish baseline connectivity. If pings succeed but HTTP requests fail, you have confirmed a TCP-layer issue rather than an IP-layer routing problem.
Capturing Traffic with Wireshark
The first step in forensics is capturing the raw data. On the Linux client machine, open a terminal and start a capture using the command:
sudo tcpdump -i eth0 -w handshake_capture.pcap host 192.168.20.5 and port 80
-i eth0: Specifies the network interface to monitor. Changeeth0to your actual interface name (e.g.,enp0s3).-w: Writes the output to a file for later analysis in Wireshark.- Filter: Limits capture to traffic involving the specific server IP and port 80 (HTTP).
Once you have triggered the connection issue (e.g., by generating high load on the router to simulate congestion), stop the capture with Ctrl+C. Open the .pcap file in Wireshark.
Analyzing Packet Drops via Filter Queries
Wireshark’s power lies in its display filters. To identify handshake drops, apply the following logic:
- Filter for TCP Handshakes: Use the filter
tcp.flags.syn == 1 && tcp.analysis.retransmissionto see retransmissions immediately. - Identify Missing SYN-ACKs: If you see a SYN packet but no subsequent SYN-ACK from the server side within the timeout window, the drop occurred between the client and server or was filtered by an intermediate router.
- Check for RST Flags: Sometimes, instead of dropping packets silently, a device sends a Reset (RST) flag. Filter with
tcp.flags.reset == 1to see if a firewall is actively blocking the connection.
Illustrative Output Interpretation
In Wireshark, look for the “TCP Stream Graph” or follow TCP streams (Right-click > Follow > TCP Stream). A healthy stream shows:
0.000000 192.168.10.5 -> 192.168.20.5 [SYN] Seq=0 Ack=0 Win=29200 Len=0 TCP (S=12345 D=80)
0.000050 192.168.20.5 -> 192.168.10.5 [SYN, ACK] Seq=0 Ack=1 Win=65535 Len=0 TCP (S=443 D=12345)
If the second line is missing for an extended period, you have a latency or loss issue. If you see multiple SYN packets from the client before any response, the server is overwhelmed, and the router is likely dropping excess traffic to manage load.
Calculating Latency and Loss Rates
To quantify the problem, use Wireshark’s statistics feature. Right-click the capture file name and select Statistics > Conversations. Click on a specific TCP conversation to see details. Look at the “Retransmission” column.
For a more forensic approach, calculate the loss rate manually if needed:
1. Count total SYN packets sent by the client ($N_{syn}$).
2. Count successful ACKs received ($N_{ack}$).
3. Estimate loss percentage based on retransmission counts visible in the “Retrans” column of the packet list.
High latency often manifests as increasing Time To Live (TTL) mismatches or delayed ACKs. If a SYN takes over 500ms to elicit a response, the path between routers is congested. Compare this against your router’s interface speed; if the link is shared with heavy broadcast traffic (like DHCP storms), packets will be queued and dropped.
Common Errors and Fixes in Troubleshooting
When analyzing handshake drops, practitioners often make specific mistakes:
* Ignoring Intermediate Routers: Assuming the drop happens at the destination server when it actually occurred on a congested router hop. Use traceroute before capturing to map the path.
* Filtering Too Aggressively: Applying filters like port 80 too early can hide the root cause if the issue is DNS resolution failure (UDP port 53) preceding the TCP handshake. Start with a broad capture (ip) and narrow down later.
* Misinterpreting RST Flags: A RST flag does not always mean “failure.” It can be a valid response to an invalid sequence number or a security measure by a stateful firewall. Check the firewall logs on the router (if accessible) to correlate with Wireshark data.
Student Practice Task: Inducing and Fixing Drops
For students learning network forensics, try this exercise:
1. Set up two VLANs in Packet Tracer with a router connecting them.
2. Configure an Access Control List (ACL) on the router to drop all SYN packets destined for port 80 from the client subnet.
3. Attempt to connect to a web server and capture the traffic.
4. Observe that the SYN packets reach the router but are dropped, while other ports might still work.
5. Modify the ACL to allow traffic and re-capture to verify the restoration of the three-way handshake.
This exercise reinforces the concept that packet drops can be intentional security measures rather than just network failures. It also teaches how to distinguish between natural loss (congestion) and policy-based dropping.
Conclusion
Diagnosing TCP three-way handshake drops requires a blend of theoretical understanding and practical forensic skills. By using Wireshark to visualize SYN, SYN-ACK, and ACK exchanges, IT professionals can isolate latency issues caused by router congestion or packet loss due to ACL misconfigurations. Remember that terms like “packet loss” depend heavily on the specific hardware queue depths and buffer management strategies of your network equipment. Always verify findings against router logs and firewall configurations to ensure a comprehensive diagnosis. Whether you are a student mastering Packet Tracer or an engineer troubleshooting a production outage, these steps provide a reliable framework for decoding complex network behaviors.
Educational-use notice: This tutorial is for learning and controlled lab use only. Test carefully, use backups, and obtain authorization before making changes. Do not run unfamiliar commands on production systems. We accept no responsibility for misuse, damage, data loss, or production issues.

