node-net-snmp icon indicating copy to clipboard operation
node-net-snmp copied to clipboard

Support TEXTUAL CONVENTION v1

Open ddolcimascolo opened this issue 5 months ago • 1 comments

Hi,

Thanks for maintaining this library. Currently the MIB parser correctly parses TEXTUAL CONVENTION v1 but these are not returned by the store.getSyntaxTypes() method. This is because there's no TEXTUAL-CONVENTION macro, the definition directly follows the object name.

See: https://www.ibm.com/docs/en/netcoolomnibus/8.1?topic=snmp-valid-mib-object-formats#omn_ref_mib_formats__title__2

DellStateCapabilities           ::= INTEGER {
    -- If set to 0 (zero), object has no state capabilities
    unknownCapabilities(1),     -- object's state capabilities are unknown
    -- The object's state capabilities allow it to be set to:
    enableCapable(2),           -- be disabled (offline) or be enabled (online)
    notReadyCapable(4),         -- not ready
    enableAndNotReadyCapable(6)
}

Another (simpler) example

DellBoolean                     ::= INTEGER (0..1)    -- 0 = FALSE, 1 = TRUE

Is this something you'll want to support?

I can share a MIB holding such definitions, just ask.

Thanks, David

ddolcimascolo avatar Sep 06 '24 12:09 ddolcimascolo