diff --git a/package-lock.json b/package-lock.json index 7728a0cf..0e09c595 100644 --- a/package-lock.json +++ b/package-lock.json @@ -54,6 +54,7 @@ "mssql": "~8.1.4", "mysql2": "~3.6.2", "nanoid": "~3.3.4", + "net-snmp": "^3.11.2", "node-cloudflared-tunnel": "~1.0.9", "node-radius-client": "~1.0.0", "nodemailer": "~6.9.13", @@ -72,7 +73,6 @@ "redbean-node": "~0.3.0", "redis": "~4.5.1", "semver": "~7.5.4", - "snmp-native": "^1.2.0", "socket.io": "~4.6.1", "socket.io-client": "~4.6.1", "socks-proxy-agent": "6.1.1", @@ -10337,6 +10337,15 @@ "node": ">= 0.6" } }, + "node_modules/net-snmp": { + "version": "3.11.2", + "resolved": "https://registry.npmjs.org/net-snmp/-/net-snmp-3.11.2.tgz", + "integrity": "sha512-QKy2JQHIBsSK344dUxYRZv7tU0ANk8f8fzKD/Mmq/cCxm/cPbtiT7009QEgxdViW/gGjqGIOiLHxkCc+JhZltg==", + "dependencies": { + "asn1-ber": "^1.2.1", + "smart-buffer": "^4.1.0" + } + }, "node_modules/node-abort-controller": { "version": "3.1.1", "resolved": "https://registry.npmjs.org/node-abort-controller/-/node-abort-controller-3.1.1.tgz", @@ -12610,11 +12619,6 @@ "npm": ">= 3.0.0" } }, - "node_modules/snmp-native": { - "version": "1.2.0", - "resolved": "https://registry.npmjs.org/snmp-native/-/snmp-native-1.2.0.tgz", - "integrity": "sha512-JIyuLX3bQmuAI4gHztHSQd3M/M2hqgLhiHBZYEk8YnYRJ2ooxqwON4gUQfgp/WCZVDca4tIX3vFJgv6lz5iY+g==" - }, "node_modules/socket.io": { "version": "4.6.2", "resolved": "https://registry.npmjs.org/socket.io/-/socket.io-4.6.2.tgz", diff --git a/package.json b/package.json index 7ee8afb4..49cc56ff 100644 --- a/package.json +++ b/package.json @@ -119,6 +119,7 @@ "mssql": "~8.1.4", "mysql2": "~3.6.2", "nanoid": "~3.3.4", + "net-snmp": "^3.11.2", "node-cloudflared-tunnel": "~1.0.9", "node-radius-client": "~1.0.0", "nodemailer": "~6.9.13", @@ -137,7 +138,6 @@ "redbean-node": "~0.3.0", "redis": "~4.5.1", "semver": "~7.5.4", - "snmp-native": "^1.2.0", "socket.io": "~4.6.1", "socket.io-client": "~4.6.1", "socks-proxy-agent": "6.1.1", diff --git a/server/monitor-types/snmp.js b/server/monitor-types/snmp.js index 4ddc8823..433fc527 100644 --- a/server/monitor-types/snmp.js +++ b/server/monitor-types/snmp.js @@ -1,6 +1,6 @@ const { MonitorType } = require("./monitor-type"); const { UP, DOWN } = require("../../src/util"); -const snmp = require("snmp-native"); +const snmp = require("net-snmp"); class SNMPMonitorType extends MonitorType { name = "snmp";