Steps towards encryption

- Added certstore and retrieval of the local trust root.
- Major work on keeping the context between calls to the milter.
- Added a context for an email in processing
- Added Husk specific errors
This commit is contained in:
Malte Meiboom
2025-12-09 12:11:07 +01:00
parent 0f3a05e811
commit 56647806b7
10 changed files with 197 additions and 40 deletions
+13 -1
View File
@@ -3,11 +3,13 @@
//
use std::fs;
use std::sync::{Arc, Mutex};
use serde_derive::Deserialize;
#[derive(Deserialize, Debug)]
#[derive(Deserialize, Debug, Clone)]
pub struct HuskConfig {
pub connection: String,
pub sequoia_home: String,
logfile_config: Option<String>,
}
@@ -41,3 +43,13 @@ impl HuskConfig {
}
}
}
pub type HuskConfigContainer = Arc<Mutex<HuskConfig>>;
impl From<HuskConfigContainer> for HuskConfig {
fn from(container: HuskConfigContainer) -> Self {
let config = container.lock().unwrap();
config.clone()
}
}