The original repository hleuwer/luasnmp implements a module with Lua bindings to Net-SNMP.
This repository is a fork of with additional features.
The main purpose of this fork is to be able to use SNMPv3 queries in Nmap NSE scripts.
- A new
configurescript.
The original repository use aconfigfile with hardcoded values to be used during installation.
Theconfigurescript is probably easier to use, as it auto-detects certain paths, and may override settings inconfigautomatically.
(Usingconfigureis still optional, if one prefers to editconfigmanually instead.) - Support for authentication protocols
MD5,SHA-224|256|384|512and privacy protocolsDES,AES-192|256, if the installed version of Net-SNMP supports the mentioned protocols. - Nmap NSE support:
- The installed library has been renamed from
snmptoluasnmpto not clash with the existing Nmap NSE librarysnmp. - Minor modifications to make
luasnmpwork instrict modewith Nmap NSE scripts.
- The installed library has been renamed from
- Parsing the
host:portargument (a.k.a. "peername") accepts custom SNMP port numbers, and only thehostpart is validated as an IP/hostname.
(Without this fix, using a custom SNMP port caused the IP validation to fail.) - The
timeoutargument may be a decimal value, to support low timeout values (fractions of a second). - The
secLevelargument is case-insensitive (accepts any ofAuthpriv,AUTHPRIVetc.), to be more aligned with Net-SNMP and other SNMP implementations.
See USAGE.md for details.