Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

mqtt-packet

Package Overview
Dependencies
Maintainers
2
Versions
73
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

mqtt-packet - npm Package Compare versions

Comparing version 7.0.0 to 7.1.0

2

package.json
{
"name": "mqtt-packet",
"version": "7.0.0",
"version": "7.1.0",
"description": "Parse and generate MQTT packets like a breeze",

@@ -5,0 +5,0 @@ "main": "mqtt.js",

@@ -350,2 +350,4 @@ const bl = require('bl')

if (packet.length <= 0) { return this._emitError(new Error('Malformed subscribe, no payload specified')) }
while (this._pos < packet.length) {

@@ -415,2 +417,4 @@ // Parse topic

if (packet.length <= 0) { return this._emitError(new Error('Malformed suback, no payload specified')) }
// Parse granted QoSes

@@ -449,2 +453,4 @@ while (this._pos < this.packet.length) {

if (packet.length <= 0) { return this._emitError(new Error('Malformed unsubscribe, no payload specified')) }
while (this._pos < packet.length) {

@@ -465,2 +471,9 @@ // Parse topic

if (!this._parseMessageId()) return this._emitError(new Error('Cannot parse messageId'))
if ((this.settings.protocolVersion === 3 ||
this.settings.protocolVersion === 4) && packet.length !== 2) {
return this._emitError(new Error('Malformed unsuback, payload length must be 2'))
}
if (packet.length <= 0) { return this._emitError(new Error('Malformed unsuback, no payload specified')) }
// Properties mqtt 5

@@ -474,2 +487,3 @@ if (this.settings.protocolVersion === 5) {

packet.granted = []
while (this._pos < this.packet.length) {

@@ -476,0 +490,0 @@ const code = this._list.readUInt8(this._pos++)

Sorry, the diff of this file is too big to display

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc