threatflux_string_analysis/
types.rs1use serde::{Deserialize, Serialize};
4use std::collections::HashMap;
5
6#[derive(Debug, Clone, Serialize, Deserialize)]
8pub struct AnalysisConfig {
9 pub min_suspicious_entropy: f64,
11 pub max_occurrences_per_string: usize,
13 pub enable_time_analysis: bool,
15 pub custom_metadata_fields: Vec<String>,
17}
18
19impl Default for AnalysisConfig {
20 fn default() -> Self {
21 Self {
22 min_suspicious_entropy: 4.5,
23 max_occurrences_per_string: 1000,
24 enable_time_analysis: true,
25 custom_metadata_fields: Vec::new(),
26 }
27 }
28}
29
30pub type AnalysisResult<T> = anyhow::Result<T>;
32
33pub type StringMetadata = HashMap<String, serde_json::Value>;