#flow #networking #community #id #hashing #hash #identifier

community-id

This package provides a Rust implementation of the open Community ID flow hashing standard

6 releases

0.2.2 Oct 7, 2023
0.2.1 Aug 11, 2023
0.1.2 May 14, 2023

#485 in Network programming

Download history 3402/week @ 2024-01-05 2579/week @ 2024-01-12 3071/week @ 2024-01-19 3781/week @ 2024-01-26 3505/week @ 2024-02-02 4325/week @ 2024-02-09 3469/week @ 2024-02-16 2556/week @ 2024-02-23 3249/week @ 2024-03-01 3511/week @ 2024-03-08 3355/week @ 2024-03-15 3184/week @ 2024-03-22 2687/week @ 2024-03-29 3229/week @ 2024-04-05 2794/week @ 2024-04-12 1889/week @ 2024-04-19

11,196 downloads per month
Used in vrl

MIT/Apache

33KB
854 lines

rs-community-id

This package provides a Rust implementation of the open Community ID flow hashing standard.

Community ID

"Community ID" is a separate specification for generating a likely-unique identifier for a network connection proposed by Corelight (the company behind Bro/Zeek). See community-id-spec

Usage

# Cargo.toml
[dependencies]
community-id = "0.2"
use std::net::Ipv4Addr;
use community_id::calculate_community_id;

let id = calculate_community_id(
    0,
    Ipv4Addr::new(1, 2, 3, 4).into(),
    Ipv4Addr::new(5, 6, 7, 8).into(),
    Some(1122),
    Some(3344),
    6,
    Default::default(),
);
assert_eq!("1:wCb3OG7yAFWelaUydu0D+125CLM=", id.unwrap());

License

This project is licensed under either of

at your option.

Dependencies

~1–1.6MB
~36K SLoC