Closed glaslos closed 7 years ago
The script (along with the smidump
tool it relies on) is superseded by the pure-python pysmi MIB compiler.
If you upgrade to a reasonably resent pysnmp, it will pull in the pysmi as a dependency and call it behind the scenes to resolve MIB names. That should work fully automatically so you might not need manual MIB compilation anymore.
But you can still turn any MIB into pysnmp module by hand with the mibdump.py
tool which is shipped along with pysmi
. Just pip install pysmi
and run mibdump.py.
Thanks for the quick feedback. Here is what we used to do: https://github.com/mushorg/conpot/blob/master/conpot/protocols/snmp/build_pysnmp_mib_wrapper.py I will see how we can change that to use the new features.
So if your goal is to just compile MIBs (and dependencies) into pysnmp, take a look at this example. It should fully replace the libsmi-based approach plus it might work way more reliable and accurate plus it could pull ASN.1 MIBs from multiple locations, including HTTP/FTP servers.
There is also some documentation on the package.
What happened to that script and where can I find it? I use it to import mib files into pysnmp