9 unstable releases (4 breaking)

✓ Uses Rust 2018 edition

0.5.2 Sep 1, 2019
0.5.1 Aug 31, 2019
0.4.1 Jul 25, 2019
0.3.0 Jan 28, 2019
0.1.0 May 8, 2018

#13 in #nom

Download history 745/week @ 2019-12-02 1774/week @ 2019-12-09 879/week @ 2019-12-16 148/week @ 2019-12-23 199/week @ 2019-12-30 360/week @ 2020-01-06 658/week @ 2020-01-13 549/week @ 2020-01-20 516/week @ 2020-01-27 420/week @ 2020-02-03 843/week @ 2020-02-10 1029/week @ 2020-02-17 914/week @ 2020-02-24 1719/week @ 2020-03-02 1614/week @ 2020-03-09 2245/week @ 2020-03-16

5,945 downloads per month

MIT/Apache

37KB
761 lines

snmp-parser

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.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

~1MB
~16K SLoC