Object Identifier Library for Rust
Object Identifiers are a standard of the ITU used to reference objects, things, and concepts in a globally unique way. This crate provides for data structures and methods to build, parse, and format OIDs.
Basic Utilization
Running Example
You can run the example code from examples/basic.rs using cargo:
Parsing OID String Representation
use *;
let oid = try_from?;
Parsing OID Binary Representation
use *;
let oid = try_from?;
Encoding OID as String Representation
use *;
let oid = try_from?;
let oid: String = oid.into;
assert_eq!;
Encoding OID as Binary Representation
use *;
let oid = try_from?;
let oid: = oid.into;
assert_eq!;
Adding as a dependency with cargo-edit
Adding as a dependency with cargo-edit for a !#[no_std]
crate
Adding as a dependency directly to Cargo.toml
[]
= "0.1.0"
Adding as a dependency directly to Cargo.toml
for a !#[no_std]
crate
[]
= { = false }
Building
The build routines have been automated with cargo-make. If you're not using cargo-make, you can check [Makefile.toml] for the relevant manual build procedures.
Building for a platform with Rust Standard Library
Building for an embedded platform or #![no_std]
Fuzzing Inputs
Profiles for cargo-fuzz are included for fuzzing the inputs on public method parameters.
Fuzz Binary OID Parsing
Fuzz String OID Parsing
Contributors ✨
Thanks goes to these wonderful people (emoji key):
This project follows the all-contributors specification. Contributions of any kind welcome!
License
Licensed under either of Apache License, Version 2.0 or MIT license at your option. Unless you explicitly state otherwise, any contribution intentionally submitted for inclusion in this library by you, as defined in the Apache-2.0 license, shall be dual licensed as above, without any additional terms or conditions.