10#ifndef __PACKET_BLUETOOTH_H__
11#define __PACKET_BLUETOOTH_H__
14#include "packet-usb.h"
15#include "packet-ubertooth.h"
21#define PROTO_DATA_BLUETOOTH_SERVICE_UUID 0
23#define BLUETOOTH_DATA_SRC 0
24#define BLUETOOTH_DATA_DST 1
26#define HCI_H4_TYPE_CMD 0x01
27#define HCI_H4_TYPE_ACL 0x02
28#define HCI_H4_TYPE_SCO 0x03
29#define HCI_H4_TYPE_EVT 0x04
30#define HCI_H4_TYPE_ISO 0x05
32#define HCI_OGF_LINK_CONTROL 0x01
33#define HCI_OGF_LINK_POLICY 0x02
34#define HCI_OGF_HOST_CONTROLLER 0x03
35#define HCI_OGF_INFORMATIONAL 0x04
36#define HCI_OGF_STATUS 0x05
37#define HCI_OGF_TESTING 0x06
38#define HCI_OGF_LOW_ENERGY 0x08
39#define HCI_OGF_LOGO_TESTING 0x3e
40#define HCI_OGF_VENDOR_SPECIFIC 0x3f
42#define HCI_VENDOR_DEFAULT 0
44#define DID_VENDOR_ID_SOURCE_BLUETOOTH_SIG 1
45#define DID_VENDOR_ID_SOURCE_USB_FORUM 2
47#define ACCESS_ADDRESS_ADVERTISING 0x8e89bed6
49extern int proto_bluetooth;
53#define STATUS_SUCCESS 0x00
55#define UUID_GATT_PRIMARY_SERVICE_DECLARATION 0x2800
56#define UUID_GATT_SECONDARY_SERVICE_DECLARATION 0x2801
57#define UUID_GATT_INCLUDE_DECLARATION 0x2802
58#define UUID_GATT_CHARACTERISTIC_DECLARATION 0x2803
76#define HCI_INTERFACE_DEFAULT 0
77#define HCI_ADAPTER_DEFAULT 0
85} bt_protocol_data_type;
96 uint32_t interface_id;
98 uint32_t *adapter_disconnect_in_frame;
109 bt_protocol_data_type previous_protocol_data_type;
116 } previous_protocol_data;
120#define BT_LINK_TYPE_UNKNOWN 0
121#define BT_LINK_TYPE_ACL 1
122#define BT_LINK_TYPE_SCO 2
123#define BT_LINK_TYPE_LL 3
124#define BT_LINK_TYPE_ISO 4
127 uint32_t connect_in_frame;
128 uint32_t disconnect_in_frame;
133 uint32_t interface_id;
140 uint32_t bd_addr_oui;
147 uint32_t change_in_frame;
152 uint32_t change_in_frame;
157 uint32_t change_in_frame;
160#define ROLE_UNKNOWN 0
161#define ROLE_CENTRAL 1
162#define ROLE_PERIPHERAL 2
165 uint32_t interface_id;
171 uint32_t interface_id;
177 uint32_t interface_id;
182 uint16_t manufacturer;
183 uint16_t hci_revision;
184 uint16_t lmp_subversion;
185 uint32_t change_in_frame;
195enum bluetooth_device_type {
196 BLUETOOTH_DEVICE_BD_ADDR,
197 BLUETOOTH_DEVICE_NAME,
198 BLUETOOTH_DEVICE_LOCAL_ADAPTER,
199 BLUETOOTH_DEVICE_LOCAL_VERSION,
200 BLUETOOTH_DEVICE_REMOTE_VERSION,
201 BLUETOOTH_DEVICE_RESET,
202 BLUETOOTH_DEVICE_SCAN,
203 BLUETOOTH_DEVICE_VOICE_SETTING,
204 BLUETOOTH_DEVICE_AUTHENTICATION,
205 BLUETOOTH_DEVICE_ENCRYPTION,
206 BLUETOOTH_DEVICE_CLASS_OF_DEVICE,
207 BLUETOOTH_DEVICE_SIMPLE_PAIRING_MODE,
208 BLUETOOTH_DEVICE_PAGE_TIMEOUT,
209 BLUETOOTH_DEVICE_INQUIRY_MODE,
210 BLUETOOTH_DEVICE_MTUS,
211 BLUETOOTH_DEVICE_LE_MTU
215 uint32_t interface_id;
221 enum bluetooth_device_type type;
226 uint16_t hci_revision;
228 uint16_t lmp_subversion;
229 uint16_t manufacturer;
233 uint16_t lmp_subversion;
234 uint16_t manufacturer;
237 uint16_t page_timeout;
238 uint8_t authentication;
240 uint32_t class_of_device;
241 uint16_t voice_setting;
242 uint8_t simple_pairing_mode;
243 uint8_t inquiry_mode;
247 uint16_t acl_packets;
248 uint16_t sco_packets;
253 uint16_t acl_packets;
254 uint16_t iso_packets;
259enum bluetooth_hci_summary_type {
260 BLUETOOTH_HCI_SUMMARY_OPCODE,
261 BLUETOOTH_HCI_SUMMARY_EVENT_OPCODE,
262 BLUETOOTH_HCI_SUMMARY_EVENT,
263 BLUETOOTH_HCI_SUMMARY_SUBEVENT,
264 BLUETOOTH_HCI_SUMMARY_VENDOR_OPCODE,
265 BLUETOOTH_HCI_SUMMARY_VENDOR_EVENT_OPCODE,
266 BLUETOOTH_HCI_SUMMARY_VENDOR_EVENT,
267 BLUETOOTH_HCI_SUMMARY_STATUS,
268 BLUETOOTH_HCI_SUMMARY_STATUS_PENDING,
269 BLUETOOTH_HCI_SUMMARY_REASON,
270 BLUETOOTH_HCI_SUMMARY_HARDWARE_ERROR
274 uint32_t interface_id;
283 uint8_t hardware_error;
286 enum bluetooth_hci_summary_type type;
290 uint32_t interface_id;
297extern int bluetooth_device_tap;
298extern int bluetooth_hci_summary_tap;
308extern uint32_t bluetooth_max_disconnect_in_frame;
311 tvbuff_t *tvb,
int offset,
bool is_local_bd_addr,
312 uint32_t interface_id, uint32_t adapter_id, uint8_t *bdaddr);
314extern void bluetooth_unit_1p25_ms(
char *buf, uint32_t value);
315extern void bluetooth_unit_0p125_ms(
char *buf, uint32_t value);
321extern void save_local_device_name_from_eir_ad(
tvbuff_t *tvb,
int offset,
Definition packet-bluetooth.h:95
Definition packet-bluetooth.h:214
Definition packet-bluetooth.h:289
Definition packet-bluetooth.h:273
Definition packet-bluetooth.h:176
Definition packet-bluetooth.h:126
Definition packet-bluetooth.h:150
Definition packet-bluetooth.h:139
Definition packet-bluetooth.h:145
Definition packet-bluetooth.h:181
Definition packet-bluetooth.h:164
Definition packet-bluetooth.h:170
Definition packet_info.h:43
Definition packet-bluetooth.h:132
Definition packet-bluetooth.h:155
Definition packet-ubertooth.h:17
Definition packet-usb.h:141
Definition packet-bluetooth.h:189
Definition value_string.h:169
Definition value_string.h:25
Definition wmem_allocator.h:27
Definition wmem_tree-int.h:48
Definition tvbuff-int.h:35