truman-core 0.1.0

Core types, filters, and parallel scanner for Truman secret detection
Documentation
//! `truman-core`: core types, traits, filters, and scanner.
//!
//! This crate holds everything detector-agnostic: findings with exact
//! positions, the [`Detector`] trait + [`DetectorRegistry`], file-type
//! detection, the staged [`FilterSet`] pipeline, entropy helpers, and the
//! parallel [`Scanner`]

pub mod detector;
pub mod entropy;
pub mod error;
pub mod filetype;
pub mod filter;
pub mod finding;
mod prefilter;
pub mod scanner;

pub use detector::{Detector, DetectorContext, DetectorRegistry, RawFinding};
pub use entropy::{
    base64_shannon_entropy, hex_shannon_entropy, shannon_entropy, shannon_entropy_bytes,
};
pub use error::{Result, TrumanError};
pub use filetype::{determine_file_type, FileType};
pub use filter::{
    is_allowlisted, is_indirect_reference, is_invalid_file, is_likely_id_string,
    is_likely_id_string_at, is_lock_file, is_non_text_file, is_not_alphanumeric_string,
    is_potential_uuid, is_prefixed_with_dollar_sign, is_regex_based_detector, is_sequential_string,
    is_swagger_file, is_templated_secret, should_exclude_due_to_verification_policy,
    should_exclude_file, should_exclude_line, should_exclude_secret, FileFilter, FilterConfig,
    FilterSet, LineFilter, SecretFilter,
};
pub use finding::{Finding, Location, Span, VerifiedResult};
pub use scanner::{hash_secret, scan_paths_streaming, FileStats, ScanConfig, ScanEvent, Scanner};

/// Crate version (mirrors workspace version).
pub const VERSION: &str = env!("CARGO_PKG_VERSION");