🚀 Big News: Socket Acquires Coana to Bring Reachability Analysis to Every Appsec Team.Learn more
Socket
Book a DemoInstallSign in
Socket

@stoprocent/bleno

Package Overview
Dependencies
Maintainers
1
Versions
27
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@stoprocent/bleno - npm Package Compare versions

Comparing version

to
0.11.3

4

lib/hci-socket/acl-stream.js
const { EventEmitter } = require('events');
const Smp = require('./smp');
const Mgmt = require('./mgmt');

@@ -11,3 +12,4 @@ class AclStream extends EventEmitter {

this._smp = new Smp(this, localAddressType, localAddress, remoteAddressType, remoteAddress);
const mgmt = new Mgmt(hci.BluetoothHciSocket);
this._smp = new Smp(this, mgmt, localAddressType, localAddress, remoteAddressType, remoteAddress);
}

@@ -14,0 +16,0 @@

@@ -83,2 +83,4 @@ const debug = require('debug')('hci');

const BluetoothHciSocket = loadDriver(options.hciDriver || 'default');
this.BluetoothHciSocket = BluetoothHciSocket;
this._socket = new BluetoothHciSocket();

@@ -85,0 +87,0 @@

const debug = require('debug')('mgmt');
const BluetoothHciSocket = require('@stoprocent/bluetooth-hci-socket');
const LTK_INFO_SIZE = 36;

@@ -10,4 +8,4 @@

class Mgmt {
constructor () {
this._socket = new BluetoothHciSocket();
constructor (socketClass) {
this._socket = new socketClass();
this._ltkInfos = [];

@@ -14,0 +12,0 @@

const { EventEmitter } = require('events');
const crypto = require('./crypto');
const Mgmt = require('./mgmt');

@@ -18,7 +17,8 @@ const SMP_CID = 0x0006;

class Smp extends EventEmitter {
constructor (aclStream, localAddressType, localAddress, remoteAddressType, remoteAddress) {
constructor (aclStream, mgmt, localAddressType, localAddress, remoteAddressType, remoteAddress) {
super();
this._aclStream = aclStream;
this._mgmt = new Mgmt();
this._mgmt = mgmt;

@@ -25,0 +25,0 @@ this._iat = Buffer.from([(remoteAddressType === 'random') ? 0x01 : 0x00]);

{
"name": "@stoprocent/bleno",
"version": "0.11.2",
"version": "0.11.3",
"description": "A Node.js module for implementing BLE (Bluetooth Low Energy) peripherals",

@@ -5,0 +5,0 @@ "main": "./index.js",

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet