Remote Packet Capture with Wireshark

This guide shows how to set up Wireshark to remotely capture traffic via SSH using tcpdump.

Prerequisites

Setup Wireshark with Remote SSH Capture

In Wireshark:

  1. Go to: CaptureOptionsManage Interfaces

  2. Click on the options icon next SSH Remote Capture

  3. Set the interface details:

    • Remote SSH Server Address: ip-address of the server
    • Remote SSH Server port: 22
  4. In the Authentication tab fill in

    • Remote SSH Server Username
    • Remote SSH Server Password
  5. In the Capture tab specify the Remote Capture Command. For example:

    BASH
    1sudo /usr/sbin/tcpdump -U -i eth0 -w - not port 22
    Click to expand and view more

    This captures traffic from eth0 while excluding SSH (port 22).

    Tip To exclude more ports, simply add filters like not port 41641. Repeat this for each port you want to omit from the capture.

  6. Save and Start the capture.

Notes

You’re now ready to securely and cleanly capture packets from a remote system using Wireshark — even with Tailscale!

Copyright Notice

Author: Sven van Ginkel

Link: https://svenvg.com/posts/remote-packet-capture-with-wireshark/

License: CC BY-NC-SA 4.0

This work is licensed under a Creative Commons Attribution-NonCommercial-ShareAlike 4.0 International License. Please attribute the source, use non-commercially, and maintain the same license.

Start searching

Enter keywords to search articles

↑↓
ESC
⌘K Shortcut