CaptureSetup/Bluetooth

Bluetooth capture setup

On Linux

You can capture Bluetooth traffic to or from your machine on Linux using Wireshark with libpcap 0.9.6 and later, if the kernel includes the BlueZ Bluetooth stack; starting with the 2.4.6 kernel, the BlueZ stack was incorporated into the mainline kernel.

Note that Debian and Debian-derived derivatives call the libpcap package "libpcap-0.8"; this does ***NOT*** mean that all such systems use libpcap 0.8. Debian and its derivatives continue to use the name "libpcap-0.8", even though newer versions' libpcap packages use newer versions of libpcap; for example, Wheezy's libpcap-0.8 package uses libpcap 1.3.0.

If the kernel supports Bluetooth interfaces and you have sufficient privileges to capture, there will be interfaces named bluetoothN for various values of N starting with 0.

With External hardware

To passively capture Bluetooth traffic between other machines, you can use the Ubertooth USB device. To capture BLE with Ubertooth please check its wiki. Also there is a plugin for Kismet - look for "Kismet" on the "Getting Started" Ubertooth page - and it produces capture files that can be dissected with a Wireshark plugin (not needed for latest Wireshark).

On Windows

On Windows, you can capture Bluetooth traffic using etwdump. It uses ETW to access an internal Windows log that provides raw HCI traffic. You will however not be able to sniff traffic between other machines natively.

The setup process is as follows:

  1. You need Wireshark 4.7.3 or greater
  2. Open wireshark as Administrator
  3. Select etwdump in the interface list (if it doesn't appear, make sure you selected 'etwdump' during install)
  4. Click on 'Add' to add a provider and select "Bluetooth Host Radio", then start the capture

wireshark-etwdump-bluetooth-setup

  1. You should now see HCI traffic

wireshark-etwdump-bluetooth

There are some special registry keys that you can configure to tweak the capture parameters. The following keys are located in HKLM:\SYSTEM\CurrentControlSet\Services\BthPort\Parameters.

Value Type Meaning Notes
MaxEtwBytes DWORD The maximum size of a HCI packet. Microsoft debug tools sets this to 0x400
EtwLogSensitiveData DWORD Set to 1 to enable HCI logging of sensitive data (like keys). Defaults to 0.
EtwDropLargeEvents DWORD Set to 0 to not drop large HCI packets. Defaults to 1.
SimplePairingDebugEnabled DWORD Set to 1 to enable SSP debug mode. Defaults to 0.
SmpDebugEnabled DWORD Send and accept SMP debug keys. Defaults to 0.

See Also