ble-pcap

1.0.0 • Public • Published

ble-pcap

Node library for working with BLE packet captures. Still WIP and things may change.

Requires node-pcap and attempts to follow the same design pattern.

Installation

npm install ble-pcap

usage

Due to a limitation of the current node-pcap design, there's no clean way to add DLTs to be parsed. To work around this, ble-pcap does some method swizzling to introduce its DLTs to the pcap library

Example Initialization

const pcap = require('pcap');
const ble_pcap = require('ble-pcap');

// let node-pcap know about our DLTs
ble_pcap.register_dlts();

// open pcap and begin parsing packets
let session =  pcap.createOfflineSession(PCAP_FILENAME);

session.on('packet', (raw_packet) => {
    let packet = pcap.decode.packet(raw_packet);
});

Readme

Keywords

Package Sidebar

Install

npm i ble-pcap

Weekly Downloads

0

Version

1.0.0

License

MIT

Unpacked Size

12.8 kB

Total Files

10

Last publish

Collaborators

  • doggkruse