Gathering detailed insights and metrics for aedes-protocol-decoder
Gathering detailed insights and metrics for aedes-protocol-decoder
Gathering detailed insights and metrics for aedes-protocol-decoder
Gathering detailed insights and metrics for aedes-protocol-decoder
npm install aedes-protocol-decoder
Typescript
Module System
Min. Node Version
Node Version
NPM Version
JavaScript (100%)
Total Downloads
0
Last Day
0
Last Week
0
Last Month
0
Last Year
0
MIT License
3 Stars
20 Commits
3 Forks
8 Watchers
2 Branches
3 Contributors
Updated on Sep 20, 2023
Latest Version
2.2.0
Package Id
aedes-protocol-decoder@2.2.0
Unpacked Size
36.39 kB
Size
9.30 kB
File Count
14
NPM Version
8.19.3
Node Version
18.13.0
Published on
Sep 20, 2023
Cumulative downloads
Total Downloads
Last Day
0%
NaN
Compared to previous day
Last Week
0%
NaN
Compared to previous week
Last Month
0%
NaN
Compared to previous month
Last Year
0%
NaN
Compared to previous year
Protocol decoder for Aedes MQTT Broker
The purpose of this module is to be used inside aedes-server-factory bindConnection
function, which is called when the server receives a connection from client (before CONNECT packet). The client object state is in default and its connected state is false.
The function extract socket details and if aedes-server-factory
trustProxy
option is set to true, it will first parse http headers (x-real-ip | x-forwarded-for) and/or proxy protocol (v1 and v2), then passing the informations to aedes
that will assign them to client.connDetails
.
Additionally, if the current socket is a TLS socket, the module will extract the authorization status and the full certificate chain.
The function protocolDecoder
and extractSocketDetails
returns ConnectionDetails, if the object contains data
property, it will be parsed as an mqtt-packet.
1npm install aedes-protocol-decoder --save
1var aedes = require('aedes') 2var { protocolDecoder } = require('aedes-protocol-decoder') 3var { createServer } = require('aedes-server-factory') 4var port = 1883 5 6var broker = aedes({ 7 preConnect: function (client, packet, done) { 8 if (client.connDetails && client.connDetails.ipAddress) { 9 client.ip = client.connDetails.ipAddress 10 } 11 return done(null, true) 12 }, 13}) 14 15var server = createServer(broker, { trustProxy: true, protocolDecoder }) 16server.listen(port, function () { 17 console.log('server listening on port', port) 18})
MIT
No vulnerabilities found.
Reason
no dangerous workflow patterns detected
Reason
no binaries found in the repo
Reason
0 existing vulnerabilities detected
Reason
license file detected
Details
Reason
Found 7/13 approved changesets -- score normalized to 5
Reason
0 commit(s) and 0 issue activity found in the last 90 days -- score normalized to 0
Reason
dependency not pinned by hash detected -- score normalized to 0
Details
Reason
detected GitHub workflow tokens with excessive permissions
Details
Reason
no effort to earn an OpenSSF best practices badge detected
Reason
project is not fuzzed
Details
Reason
branch protection not enabled on development/release branches
Details
Reason
security policy file not detected
Details
Reason
SAST tool is not run on all commits -- score normalized to 0
Details
Score
Last Scanned on 2025-07-07
The Open Source Security Foundation is a cross-industry collaboration to improve the security of open source software (OSS). The Scorecard provides security health metrics for open source projects.
Learn More