Security News
GitHub Removes Malicious Pull Requests Targeting Open Source Repositories
GitHub removed 27 malicious pull requests attempting to inject harmful code across multiple open source repositories, in another round of low-effort attacks.
ble-ad-parser
Advanced tools
This package will parse BLE slave advertisement packets into human readable/manipulatable objects. Based off of the BLE specification data types.
npm install ble-ad-parser
var parser = require('ble-ad-parser');
// Payload from your BLE device (make it into a buffer, if not already)
var payload = new Buffer([27, 2, 1, 6, 17, 6, 186, 86, 137, 166, 250, 191, 162, 189, 1, 70, 125, 110, 56, 88, 171, 173, 5, 22, 10, 24, 7, 4]);
// Parse (little-endian by default)
var packets = parser.parse(payload);
//
console.log(packets.length); // 3
console.log(packets[0].type); // Flags
console.log(packets[0].data); // [ 'LE Limited Discoverable Mode' ]
console.log(packets[1].type); // 'Incomplete List of 128-bit Service Class UUIDs'
console.log(packets[1].data); // [ '0xba5689a6fabfa2bd01467d6e3858abad' ]
The returned packets in the packet array have the following structure:
packet.type -> A string describing type of data (eg. "Flags", "Complete List of 16-bit UUIDs", etc.)
packet.data -> The data parsed into appropriate data type (eg. String, Array of Octet Strings, unsigned int, etc.)
packet.typeFlag -> the type flag parsed from packet
packet.raw -> The raw buffer that was parsed
You can specify the endianess that you want the buffers parsed with by using these functions:
parser.parseLE(buffer);
parse.parseBE(buffer);
MIT
FAQs
Parse Bluetooth Low Energy peripheral advertising packets
We found that ble-ad-parser demonstrated a not healthy version release cadence and project activity because the last version was released a year ago. It has 1 open source maintainer collaborating on the project.
Did you know?
Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.
Security News
GitHub removed 27 malicious pull requests attempting to inject harmful code across multiple open source repositories, in another round of low-effort attacks.
Security News
RubyGems.org has added a new "maintainer" role that allows for publishing new versions of gems. This new permission type is aimed at improving security for gem owners and the service overall.
Security News
Node.js will be enforcing stricter semver-major PR policies a month before major releases to enhance stability and ensure reliable release candidates.