snmp-d 0.1.0
net-snmp bindings for D
To use this package, run the following command in your project's root directory:
Manual usage
Put the following dependency into your project's dependences section:
snmp.d
D bindings for net-snmp. Supports SNMPv1/v2c/v3, MIB loading, and subagents.
Requirements
- net-snmp ≥ 5.9 —
sudo apt install libsnmp-dev/brew install net-snmp - D frontend ≥ 2.111 (LDC or DMD)
macOS: net-snmp is keg-only. Add to your environment:
export LDFLAGS="-L$(brew --prefix net-snmp)/lib" export CPPFLAGS="-I$(brew --prefix net-snmp)/include"
Usage
Add in your dub.json|dub.sdl:
dub add snmp-d
Modules
| Module | Provides |
|---|---|
snmp.session | SNMPSession — get, getNext, getBulk |
snmp.pdu | SNMPResponse — foreach, length |
snmp.varbind | VarBind — cursor over response variables, value extractors |
snmp.oid | OID — parse, compare, format, prefix checks |
snmp.v3 | SNMPV3Session — SNMPv3 USM auth/priv |
snmp.mib | MIB — load MIB files, resolve named OIDs |
snmp.agent | SNMPAgent — embedded agent / AgentX subagent |
snmp.types | Enums: SNMPVersion, PDUType, SNMPError, ASNType |
c.net_snmp | Raw ImportC declarations |
Examples
cd examples
dub build :snmp_get # ./build/examples_snmp_get [host] [community]
dub build :snmp_walk # ./build/examples_snmp_walk [host] [community]
License
- 0.1.0 released a month ago
- kassane/snmp.d
- BSL-1.0
- Authors:
- Dependencies:
- none
- Versions:
-
Show all 1 versions0.1.0 2026-Mar-16 - Download Stats:
-
-
0 downloads today
-
0 downloads this week
-
1 downloads this month
-
2 downloads total
-
- Score:
- 0.0
- Short URL:
- snmp-d.dub.pm