Skip to content

Commit d66fe44

Browse files
committed
update first two scenarios
1 parent 521b86b commit d66fe44

File tree

6 files changed

+26
-26
lines changed

6 files changed

+26
-26
lines changed
290 KB
Loading
71.4 KB
Loading
335 KB
Loading
385 KB
Loading
257 KB
Loading

articles/network-watcher/network-watcher-deep-packet-inspection.md

Lines changed: 26 additions & 26 deletions
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@ author: halkazwini
66
ms.author: halkazwini
77
ms.service: network-watcher
88
ms.topic: how-to
9-
ms.date: 01/31/2024
9+
ms.date: 02/07/2024
1010
#CustomerIntent: As a network administrator, I want to inspect packets captured by Network Watcher to investigate network issues.
1111
---
1212

@@ -26,55 +26,55 @@ In this article, you learn how to open a packet capture file provided by Network
2626

2727
## Calculate network latency
2828

29-
In this scenario, we show how to view the initial Round Trip Time (RTT) of a Transmission Control Protocol (TCP) conversation occurring between two endpoints.
29+
In this example, you learn how to view the initial Round Trip Time (RTT) of a Transmission Control Protocol (TCP) conversation between two endpoints.
3030

31-
When a TCP connection is established, the first three packets sent in the connection follow a pattern commonly referred to as the three-way handshake. By examining the first two packets sent in this handshake, an initial request from the client and a response from the server, we can calculate the latency when this connection was established. This latency is referred to as the Round Trip Time (RTT). For more information on the TCP protocol and the three-way handshake, see the following resource. [https://support.microsoft.com/en-us/help/172983/explanation-of-the-three-way-handshake-via-tcp-ip](https://support.microsoft.com/en-us/help/172983/explanation-of-the-three-way-handshake-via-tcp-ip)
31+
When a TCP connection is established, the first three packets sent in the connection follow a pattern referred to as the three-way handshake. By examining the first two packets sent in this handshake, an initial request from the client and a response from the server, you can calculate the latency. This latency is referred to as the Round Trip Time (RTT). For more information on the TCP protocol and the three-way handshake, see [Explanation of the three-way handshake via TCP/IP](https://support.microsoft.com/en-us/help/172983/explanation-of-the-three-way-handshake-via-tcp-ip).
3232

33-
### Step 1
34-
35-
Launch WireShark
33+
1. Launch WireShark.
3634

37-
### Step 2
35+
1. Load the **.cap** file from your packet capture session.
3836

39-
Load the **.cap** file from your packet capture. This file can be found in the blob it was saved in our locally on the virtual machine, depending on how you configured it.
37+
1. Select a [SYN] packet in your capture. This packet is the first packet sent by the client to initiate a TCP connection.
4038

41-
### Step 3
39+
1. Right-click on the packet and select **Follow**, then select **TCP Stream**.
4240

43-
To view the initial Round Trip Time (RTT) in TCP conversations, we'll only be looking at the first two packets involved in the TCP handshake. We'll be using the first two packets in the three-way handshake, which are the [SYN], [SYN, ACK] packets. They're named for flags set in the TCP header. The last packet in the handshake, the [ACK] packet, won't be used in this scenario. The [SYN] packet is sent by the client. Once it's received, the server sends the [ACK] packet as an acknowledgment of receiving the SYN from the client. Leveraging the fact that the server’s response requires very little overhead, we calculate the RTT by subtracting the time the [SYN, ACK] packet was received by the client by the time [SYN] packet was sent by the client.
41+
:::image type="content" source="./media/network-watcher-deep-packet-inspection/follow-tcp-stream.png" alt-text="Screenshot shows how to filter TCP stream packets in Wireshark." lightbox="./media/network-watcher-deep-packet-inspection/follow-tcp-stream.png":::
4442

45-
Using WireShark this value is calculated for us.
43+
1. Expand the **Transmission Control Protocol** section of the [SYN] packet, and then the **Flags** section.
4644

47-
To more easily view the first two packets in the TCP three-way handshake, we'll utilize the filtering capability provided by WireShark.
45+
1. Confirm that the **Syn** bit is set to 1, then right-click on it.
4846

49-
To apply the filter in WireShark, expand the “Transmission Control Protocol” Segment of a [SYN] packet in your capture and examine the flags set in the TCP header.
47+
1. Select **Apply as Filter**, and then select **... and selected** to show the packets with **Syn** bit set to 1 within the TCP stream.
5048

51-
Since we're looking to filter on all [SYN] and [SYN, ACK] packets, under flags confirm that the Syn bit is set to 1, then right-select on the Syn bit -> Apply as Filter -> Selected.
49+
The first two packets involved in the TCP handshake are the [SYN], [SYN, ACK] packets. You don't need the last packet in the handshake, which is the [ACK] packet. The [SYN] packet is sent by the client. Once it's received, the server sends the [ACK] packet as an acknowledgment of receiving the [SYN] from the client.
5250

53-
![figure 7][7]
51+
:::image type="content" source="./media/network-watcher-deep-packet-inspection/syn-filter.png" alt-text="Screenshot shows how to apply a filter to see the [SYN] and and [SYN, ACK] packets in a TCP stream in Wireshark." lightbox="./media/network-watcher-deep-packet-inspection/syn-filter.png":::
5452

55-
### Step 4
53+
1. Select the [SCK] packet.
5654

57-
Now that you've filtered the window to only see packets with the [SYN] bit set, you can easily select conversations you're interested in to view the initial RTT. A simple way to view the RTT in WireShark is to select the dropdown marked “SEQ/ACK” analysis. You'll then see the RTT displayed. In this case, the RTT was 0.0022114 seconds, or 2.211 ms.
55+
1. Expand the **SEQ/ACK** section to see the iRTT in seconds.
5856

59-
![figure 8][8]
57+
:::image type="content" source="./media/network-watcher-deep-packet-inspection/view-latency.png" alt-text="Screenshot shows how to see the latency represented as iRTT in seconds in Wireshark." lightbox="./media/network-watcher-deep-packet-inspection/view-latency.png":::
6058

6159
## Find unwanted protocols
6260

63-
You can have many applications running on a virtual machine instance you've deployed in Azure. Many of these applications communicate over the network, perhaps without your explicit permission. Using packet capture to store network communication, we can investigate how applications are talking on the network and look for any issues.
61+
You can have many applications running on an Azure virtual machine. Many of these applications communicate over the network, sometimes without your explicit permission. Using packet capture to record network communication, you can investigate how applications communicate over the network, allowing you to identify and address any potential issues.
6462

65-
In this example, we review a previous ran packet capture for unwanted protocols that might indicate unauthorized communication from an application running on your machine.
63+
In this example, you learn how to analyze a packet capture to find unwanted protocols that might indicate unauthorized communication from an application running on your virtual machine.
6664

67-
### Step 1
65+
1. Launch WireShark.
66+
67+
1. Load the **.cap** file from your packet capture session.
6868

69-
Using the same capture in the previous scenario, select **Statistics** > **Protocol Hierarchy**.
69+
1. Select **Statistics**, then select **Protocol Hierarchy**.
7070

71-
![protocol hierarchy menu][2]
71+
:::image type="content" source="./media/network-watcher-deep-packet-inspection/protocol-hierarchy.png" alt-text="Screenshot shows how to get to Protocol Hierarchy from the Statistics menu in Wireshark." lightbox="./media/network-watcher-deep-packet-inspection/protocol-hierarchy.png":::
7272

73-
The protocol hierarchy window appears. This view provides a list of all the protocols that were in use during the capture session and the number of packets transmitted and received using the protocols. This view can be useful for finding unwanted network traffic on your virtual machines or network.
73+
1. In the **Protocol Hierarchy Statistics** window, you can see a list of all the protocols that were in use during the capture session and the number of packets transmitted and received using each protocol. This view is useful for finding unwanted network traffic on your virtual machines or network.
7474

75-
![protocol hierarchy opened][3]
75+
:::image type="content" source="./media/network-watcher-deep-packet-inspection/protocol-hierarchy-statistics.png" alt-text="Screenshot shows the Protocol Hierarchy Statistics window in Wireshark." lightbox="./media/network-watcher-deep-packet-inspection/protocol-hierarchy-statistics.png":::
7676

77-
As you can see in the following screen capture, there was traffic using the BitTorrent protocol, which is used for peer to peer file sharing. As an administrator you don't expect to see BitTorrent traffic on this particular virtual machine. Now you aware of this traffic, you can remove the peer to peer software that installed on this virtual machine, or block the traffic using Network Security Groups or a Firewall. Additionally, you can elect to run packet captures on a schedule, so you can review the protocol use on your virtual machines regularly. For an example on how to automate network tasks in Azure, visit [Monitor network resources with Azure Automation](network-watcher-monitor-with-azure-automation.md).
77+
In the example, you can see that there was traffic using the BitTorrent protocol, which is used for peer-to-peer file sharing. As an administrator, if you don't expect to see BitTorrent traffic on this particular virtual machine, then you can remove the peer-to-peer software that's installed on this virtual machine, or block the traffic using a network security group or a firewall.
7878

7979
## Finding top destinations and ports
8080

0 commit comments

Comments
 (0)