12 releases (7 breaking)

0.8.0 Sep 13, 2021
0.7.0 Nov 29, 2020
0.6.0 Jun 5, 2020
0.5.2 Sep 1, 2019
0.1.0 May 8, 2018

#1 in #snmp

Download history 1606/week @ 2021-06-06 1199/week @ 2021-06-13 2399/week @ 2021-06-20 1301/week @ 2021-06-27 1482/week @ 2021-07-04 872/week @ 2021-07-11 1415/week @ 2021-07-18 1229/week @ 2021-07-25 985/week @ 2021-08-01 1331/week @ 2021-08-08 986/week @ 2021-08-15 1576/week @ 2021-08-22 1860/week @ 2021-08-29 2633/week @ 2021-09-05 1456/week @ 2021-09-12 1817/week @ 2021-09-19

6,293 downloads per month
Used in suricata

MIT/Apache

39KB
757 lines

License: MIT Apache License 2.0 Build Status Crates.io Version

SNMP Parser

A SNMP parser, implemented with the nom parser combinator framework.

The goal of this parser is to implement SNMP messages analysis, for example to use rules from a network IDS.

To read a message, different functions must be used depending on the expected message version. The main functions for parsing are parse_snmp_v1, parse_snmp_v2c and parse_snmp_v3. If you don't know the version of the message and want to parse a generic SNMP message, use the parse_snmp_generic_message function.

The code is available on Github and is part of the Rusticata project.

Changes

0.8.0

  • Upgrade to nom 7 / der-parser 6

0.7.0

  • Upgrade to nom 6 / der-parser 5

0.6.0

  • Upgrade to der-parser 4

0.5.2

  • Use parse_ber_u32 from der-parser crate

0.5.1

  • Fix parsing: use BER parsing so DER constraints are not applied

0.5.0

  • Upgrade to nom 5 and der-parser 3

License

Licensed under either of

at your option.

Contribution

Unless you explicitly state otherwise, any contribution intentionally submitted for inclusion in the work by you, as defined in the Apache-2.0 license, shall be dual licensed as above, without any additional terms or conditions.

Dependencies

~2.5MB
~51K SLoC