markabrahams / node-net-snmp

JavaScript implementation of the Simple Network Management Protocol (SNMP)
209 stars 97 forks source link

RequestInvalidError: Unknown type '[object Object]' in request #244

Closed morrisrob closed 9 months ago

morrisrob commented 9 months ago

Hello, I am receiving a "RequestInvalidError: Unknown type '[object Object]' in request" error and I have confirmed that this issue was introduced in v3.9.6. I am not able to reproduce this same error in v3.9.5.

Here is an example of the varbinds getting passed into the writeVarbinds function; it seems that the issue is that there is an object in the type property and not the expected integer value associated with the ObjectType enum. image

I am only seeing this issue in tables and specifically with entries with the DisplayString Syntax. Here is the MIB entry associated with this: image

markabrahams commented 9 months ago

Hi @morrisrob - thanks for reporting this. I've pushed a fix for this and published it in version 3.10.1 of the npm.

morrisrob commented 9 months ago

@markabrahams, thank you for the very quick response and fix! I have confirmed that this issue is resolved in 3.10.1. Thanks!