-
-
Notifications
You must be signed in to change notification settings - Fork 53
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Nodejs and typescript #53
Comments
Do you mean MIBs transformed into JSON objects (which is already done) or the entire code base rewritten in some other language (which is unlikely)? |
Dear @etingof Thanks for your quick answer. Topic 1 : Node.js & typescript or javascriptYes I am looking for a Mib parser where all dependencies are included in a folder and with the parser to check if no dependency is missing , if not , need to be transformed into json object into a file in Node.js and typescript or javascript ? I read your documentation and it 's exactly what I am looking for but can't use because only supporting node.js and typescript. This tools for us is more to look for parameters to control a device are available. You know most of the time the sale guy sell more than the device can do or could do ;-) This is the example I have found in github but for example when it is a sequence, it is not clear and missing the all definition of the asn structure : Sample where some index in a parameter are incorrect or could not be parsedCould you try if you could parse and create the json file ? TT1260-MIBS.zip Thanks in advance if you could help me or share some links ? Best Regards, |
I am still confused, I am not sure I understand what you need. If you have MIB in JSON form, can't it be readily consumed by JS code? PySMI parser will fail on unresolved dependencies between MIB modules. So JSONs it produces are always valid in that regard. If you are looking for some other structure of JSON document, PySMI is entirely driven by Jinja2 templates - you can create your own and render some other JSON. |
Dear @etingof Sorry to confusing you. I have only Mib files with dependencies sometime missing and need to google to download it. Now I need to parse the Mib files with the dependencies and to transform them into json object and look like we have a mib browser. the picture is just to showing the structure expected but we don't want to create a mib browser. We have a gateway that needs to exchange data between snmp and proprietary protocol. Then If I could parse the mibs , generate with success the json object file, I am saved ;-) Again Best regards |
PySMI's If JSON structure referenced above does not suit your needs, you can probably reshape it with common JSON manipulation tools. |
Writing a MIB parser is nothing new than applying lex & yacc to the ASN.1 and SMI based grammar. So, if this project can do it for Python, you can also do the same for JavaScript/TypeScript. Writing parsers/compilers is not a trivial topic even for computer science students. Therefore, rarely you see an open source one if clearly there is value in it. |
Dear
any chance to have your mib parser in nodejs and typescript or javascript?
Best Regards
Youssef
The text was updated successfully, but these errors were encountered: