LAB EXPERIMENT-4
LAB EXPERIMENT-4
What is Wireshark?
Wireshark is a network packet analyzer. A network packet analyzer presents captured packet data in
as much detail as possible.
You could think of a network packet analyzer as a measuring device for examining what’s happening
inside a network cable, just like an electrician uses a voltmeter for examining what’s happening inside
an electric cable (but at a higher level, of course).
In the past, such tools were either very expensive, proprietary, or both. However, with the advent of
Wireshark, that has changed. Wireshark is available for free, is open source, and is one of the best
packet analyzers available today.
Features
Available for UNIX and Windows.
Capture live packet data from a network interface.
Open files containing packet data captured with tcpdump/WinDump, Wireshark, and many other packet
capture programs.
Import packets from text files containing hex dumps of packet data.
Display packets with very detailed protocol information.
Save packet data captured.
Export some or all packets in a number of capture file formats.
Filter packets on many criteria.
Search for packets on many criteria.
Colorize packet display based on filters.
Create various statistics.
Installing Wireshark
Step 1: Install Wireshark
We shall now start capturing the packets using the enp0s3 interface. (click on enp0s3 interface to see how the
packets are captured.)
It looks as follows:
The Menu
File
This menu contains items to open and merge capture files, save, print, or export capture files in
whole or in part, and to quit the Wireshark application.
Edit
This menu contains items to find a packet, time reference or mark one or more packets, handle
configuration profiles, and set your preferences.
View
This menu controls the display of the captured data, including colorization of packets, zooming the
font, showing a packet in a separate window, expanding and collapsing trees in packet details.
Go
This menu contains items to go to a specific packet.
Capture
This menu allows you to start and stop captures and to edit capture filters.
Analyze
This menu contains items to manipulate display filters, enable or disable the dissection of protocols,
configure user specified decodes and follow a TCP stream.
Statistics
This menu contains items to display various statistic windows, including a summary of the packets
that have been captured, display protocol hierarchy statistics and much more.
Telephony
This menu contains items to display various telephony related statistic windows, including a media
analysis, flow diagrams, display protocol hierarchy statistics and much more.
Wireless
This menu contains items to display Bluetooth and IEEE 802.11 wireless statistics.
Tools
This menu contains various tools available in Wireshark, such as creating Firewall ACL Rules.
https://www.wireshark.org/docs/wsug_html_chunked/ChapterUsing.html
No. The number of the packet in the capture file. This number won’t change, even if a display filter is used.
Time The timestamp of the packet. The presentation format of this timestamp can be changed.
Source The address where this packet is coming from.
Destination The address where this packet is going to.
Protocol The protocol name in a short (perhaps abbreviated) version.
Length The length of each packet.
Info Additional information about the packet content.
TO VIEW A PARTICULAR PANE, GO TO: EDIT-> PREFERENCES->APPEARANCE->LAYOUT
YOU CAN SELECT THE DIFFERENT VIEWS USING THE RADIO BUTTONS IN DIFFERENT PANES
PROFILE:
ADD NEW PROFILE:
PREFERENCES:
EDIT->PREFERENCES
You will now see the transport names in your packet list:
Source and destination names are resolved after checking the above options:
Now, go to statistics-> resolved addresses, you will find the ip addresses and resolved names.
We can add names to our private ip addresses also (right click on a record):
Now, go to statistics-> resolved addresses, you will find the ip addresses and resolved name of newly
added client.
WIRESHARK STATISTICS:
Using trace file:
uploaded in google class room with name: Wireshark_Mclass_Lesson8_Stats.pcapng
Open this file in wireshark.
Go to:
Adding filter from the conversation and viewing in the packet list:
It looks as follows: