net-snmp 3.9.0 → 3.9.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (3) hide show
  1. package/README.md +4 -0
  2. package/lib/mib.js +3 -3
  3. package/package.json +1 -1
package/README.md CHANGED
@@ -3243,6 +3243,10 @@ Example programs are included under the module's `example` directory.
3243
3243
 
3244
3244
  * Add ProcessingError to handle agent/receiver decode failures
3245
3245
 
3246
+ ## Version 3.9.1 - 16/03/2023
3247
+
3248
+ * Fix MIB parsing of unclosed brackets in comments
3249
+
3246
3250
  # License
3247
3251
 
3248
3252
  Copyright (c) 2020 Mark Abrahams <mark@abrahams.co.nz>
package/lib/mib.js CHANGED
@@ -159,10 +159,10 @@ var MIB = function (dir) {
159
159
  }
160
160
  break;
161
161
  case '{':
162
- if (this.CharBuffer.isEqual) { this.CharBuffer.isOID = true; }
162
+ if ( ! this.CharBuffer.isComment && this.CharBuffer.isEqual ) { this.CharBuffer.isOID = true; }
163
163
  case '[':
164
164
  case '(':
165
- if ( ! this.CharBuffer.isString ) {
165
+ if ( ! this.CharBuffer.isComment && ! this.CharBuffer.isString ) {
166
166
  this.CharBuffer.nested++;
167
167
  if ( char == '(') {
168
168
  this.CharBuffer.inGroup++;
@@ -182,7 +182,7 @@ var MIB = function (dir) {
182
182
  case '}':
183
183
  case ']':
184
184
  case ')':
185
- if ( ! this.CharBuffer.isString ) {
185
+ if ( ! this.CharBuffer.isComment && ! this.CharBuffer.isString ) {
186
186
  this.CharBuffer.nested--;
187
187
  if (this.CharBuffer.nested < 0) {
188
188
  this.CharBuffer.nested = 0;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "net-snmp",
3
- "version": "3.9.0",
3
+ "version": "3.9.1",
4
4
  "description": "JavaScript implementation of the Simple Network Management Protocol (SNMP)",
5
5
  "main": "index.js",
6
6
  "directories": {