Wireshark on Parrot Linux: Capture and Filter Basics

Everything in this Wireshark guide is meant for networks you own or are authorized to monitor: your home LAN, a lab VM network, or a range where the owner has given you written permission. Wireshark on Parrot Linux is the standard tool for looking at raw packets, and once it is installed and capture permissions are sorted out, most of the learning curve comes down to two skills: starting a clean capture on the right interface, and writing filters that cut thousands of packets down to the dozen you care about. This guide covers both, plus the command-line twin tshark for when you are working over SSH.

Installing Wireshark on Parrot Linux

The Security edition ships with Wireshark already in place; Home edition does not. Either way, the package comes from the Parrot repository and installs in one step:

sudo apt update
sudo apt install wireshark

Partway through, a text dialog asks whether non-superusers should be able to capture packets. Answer Yes. This configures the dumpcap helper so that members of the wireshark group can capture without running the whole GUI as root, which is both safer and avoids the usual “permission denied on /root/.config” mess.

If the dialog never appeared, or you answered No by accident, you can bring it back:

sudo dpkg-reconfigure wireshark-common

Then add your user to the group and log out and back in (a new terminal is not enough; group membership is read at login):

sudo usermod -aG wireshark "$USER"

Confirm after logging back in:

groups | grep -o wireshark
wireshark --version | head -n 1

If groups prints nothing, the login step was skipped. On KDE Plasma a full logout from the session menu is the reliable way; locking the screen does not count.

Which Interface to Capture On

Launch Wireshark from the terminal or the applications menu. The welcome screen lists every interface with a small sparkline showing live traffic. Interface names on Parrot follow the systemd predictable naming scheme, so you will see things like:

NameWhat it usually is
eth0 or enp3s0 / ens33Wired Ethernet (ens33 is typical inside VMware, enp0s3 inside VirtualBox)
wlan0 or wlp2s0Wi-Fi adapter
loLoopback; only traffic between programs on the same machine
anyAll interfaces at once (Linux only; loses some link-layer detail)
docker0, virbr0, vmnet8Bridges for Docker, libvirt and VMware guests

List them from the shell to match names to addresses:

ip -brief address

For a first capture pick the interface that carries your internet connection, double-click it, and open a web page in your browser. Packets will scroll immediately. Press the red square in the toolbar to stop.

If your Wi-Fi adapter is not listed at all, the problem is at the driver level rather than in Wireshark; the Wi-Fi troubleshooting guide covers the firmware and driver checks.

Capture Filters vs Display Filters

This distinction causes more confusion than anything else in Wireshark, so it is worth being precise.

  • Capture filters are applied by the kernel before packets reach Wireshark. They use the BPF syntax shared with tcpdump, and whatever they exclude is gone for good. Use them to keep a long capture small.
  • Display filters are applied after the fact, to packets already captured. They use Wireshark’s own richer syntax, and you can change them as often as you like without losing data.

Set a capture filter in the text box on the welcome screen before double-clicking the interface. Set a display filter in the green bar above the packet list at any time. The two syntaxes are not interchangeable: tcp port 80 is a capture filter, tcp.port == 80 is a display filter, and typing one into the other’s box will be rejected.

Useful capture filters

host 192.168.1.50          # only traffic to or from one machine
net 192.168.1.0/24         # one subnet
tcp port 443               # HTTPS only
not port 22                # drop your own SSH session noise
udp port 53                # DNS only

Combine with and, or, not and parentheses. Keep capture filters simple; if you are not sure a packet is irrelevant, let it through and sort it out with a display filter later.

Display Filter Basics You Will Use Every Day

Display filters compare protocol fields. The field names appear in the Packet Details pane: select any field there and the status bar at the bottom shows its exact filter name, which is the fastest way to learn the syntax.

FilterShows
ip.addr == 192.168.1.50Packets where that IP is source or destination
ip.src == 192.168.1.50Only packets sent by that host
tcp.port == 80 || tcp.port == 443Web traffic on either port
httpDecoded HTTP requests and responses
http.request.method == "POST"Form submissions and API writes
dnsDNS queries and answers
dns.qry.name contains "parrot"DNS lookups matching a substring
tcp.flags.syn == 1 && tcp.flags.ack == 0New connection attempts only
tcp.analysis.retransmissionRetransmitted segments, a sign of packet loss
!(arp || icmp || mdns)Hide common LAN chatter
frame.len > 1000Large packets only
tls.handshake.type == 1TLS Client Hello, useful for seeing SNI hostnames

The filter bar turns green when the expression is valid, red when it is not, and yellow when it is valid but probably not what you meant (for example ip.addr != x, which matches almost everything because one of the two addresses is always not x; use !(ip.addr == x) instead).

Operators: ==, !=, >, <, contains, matches (regex), and the logical && / || / !. Right-clicking a value in the details pane and choosing Apply as Filter builds the expression for you.

Following a Stream

Individual packets are hard to read. Right-click any TCP packet and choose Follow → TCP Stream, and Wireshark reassembles the whole conversation into one window with client data in one colour and server data in another. For a plain HTTP request to a lab target you will see the full request headers and the HTML response as text. For HTTPS you will see only the TLS handshake and encrypted blobs, which is exactly the point of TLS. The same menu offers UDP and TLS stream following, and the stream number it generates (tcp.stream eq 3) is itself a handy display filter.

Saving and Reopening Captures

Stop the capture, then File → Save As. Use the default .pcapng format; it stores interface names and comments that the older .pcap format drops. Files save wherever you choose, and they can be reopened later, shared with a colleague, or fed to other tools. Before sharing a capture, remember that it may contain cookies, session tokens and plain-text passwords from any unencrypted protocol that was in use.

A long capture on a busy interface grows quickly. For captures that need to run for hours, use Capture → Options → Output to enable ring buffers: Wireshark writes a new file every N megabytes or minutes and keeps only the most recent few.

tshark: Wireshark Without the GUI

The same package installs tshark, which does everything the GUI does from a terminal. It is what you want on a headless lab VM, over SSH, or inside a script.

# list interfaces
tshark -D

# capture 200 packets on eth0 to a file, no output to screen
tshark -i eth0 -c 200 -w ~/lab-capture.pcapng

# read a file with a display filter and print one line per packet
tshark -r ~/lab-capture.pcapng -Y "dns" 

# print just two fields as a table
tshark -r ~/lab-capture.pcapng -Y "http.request" -T fields -e ip.src -e http.host -e http.request.uri

Capture filters use -f, display filters use -Y, so tshark -i eth0 -f "port 53" -Y "dns.flags.response == 0" captures only DNS and shows only the queries. The group permission you set up earlier applies to tshark too, so no sudo is needed.

If you have Docker running as described in how to install Docker on Parrot Linux, capturing on docker0 with tshark is a quick way to see what a container actually talks to.

Common Problems on Parrot Linux

  • “You don’t have permission to capture on that device.” Group membership has not taken effect. Run the groups check above; if wireshark is missing, log out fully. If it is present and capturing still fails, re-run sudo dpkg-reconfigure wireshark-common and answer Yes.
  • Wireshark runs but no interfaces are listed. Same cause, or dumpcap lost its capabilities after a package update. Check with getcap /usr/bin/dumpcap; it should show cap_net_admin,cap_net_raw.
  • Packets from other machines on the LAN are missing. A switched network only delivers frames addressed to your MAC. To see other hosts’ traffic you need a mirror port on the switch, a hub, or to be on the same VM-internal network as the target. Wireshark captures; it does not redirect traffic.
  • Wi-Fi capture shows only your own traffic. Normal in managed mode. Monitor mode captures of other stations’ 802.11 frames are a separate topic, require a supporting chipset, and should only ever be run on networks you control.
  • Interface is busy or slow in a VM. Promiscuous mode on a VMware or VirtualBox adapter needs to be allowed in the VM’s network settings on the host side, not just inside Parrot.

Running Wireshark from the terminal shows warnings that the GUI hides, so if something seems off, start it with wireshark & from a terminal and read the output. On a very slow system, the capture itself is rarely the bottleneck; the GUI redraw is, and the fixes in speeding up Parrot Linux help there.

A Short First Exercise

Pick one of the targets from the home pentesting lab guide. Start a capture on the interface facing it with the capture filter host <target-ip>. In another terminal, run a quick Nmap scan of that target. Stop the capture and apply the display filter tcp.flags.syn == 1 && tcp.flags.ack == 0. You will see the scan as a burst of SYN packets, one per port, and can compare which ports replied with SYN-ACK versus RST. Then try tcp.flags.reset == 1 on its own. Ten minutes with that exercise teaches more about how port scans look on the wire than any amount of reading.

FAQ

Should I run Wireshark as root on Parrot Linux?

No. Running the full GUI as root gives a large, complex program unnecessary privileges and tends to break your user’s Wireshark configuration directory. The wireshark group plus the dumpcap helper exist precisely so you never need to.

Can Wireshark decrypt HTTPS traffic?

Only when you supply the keys. For your own browser, set the SSLKEYLOGFILE environment variable before launching Firefox or Chromium, then point Wireshark at that file under Edit → Preferences → Protocols → TLS → (Pre)-Master-Secret log filename. It cannot decrypt traffic from other devices whose keys you do not have.

What is the difference between Wireshark and tcpdump?

They capture the same packets with the same BPF capture filters. tcpdump is a small command-line tool that prints one summary line per packet; Wireshark adds full protocol decoding, display filters, stream reassembly and a GUI. tshark sits in between, offering Wireshark’s decoding from the command line. Many people capture with tcpdump on a server and open the resulting file in Wireshark on their Parrot desktop.