mirror of
https://github.com/mailscope/kumomta.git
synced 2026-09-21 01:05:31 +00:00
refactor: move tls_helpers to server-common
This commit is contained in:
Generated
+3
-2
@@ -2269,6 +2269,9 @@ dependencies = [
|
||||
"mod-redis",
|
||||
"mod-sqlite",
|
||||
"once_cell",
|
||||
"rcgen",
|
||||
"rustls 0.20.8",
|
||||
"rustls-pemfile",
|
||||
"serde_json",
|
||||
"throttle",
|
||||
"tokio",
|
||||
@@ -2367,10 +2370,8 @@ dependencies = [
|
||||
"ppp",
|
||||
"prometheus",
|
||||
"rand 0.8.5",
|
||||
"rcgen",
|
||||
"rfc5321",
|
||||
"rustls 0.20.8",
|
||||
"rustls-pemfile",
|
||||
"self_cell",
|
||||
"serde",
|
||||
"serde_json",
|
||||
|
||||
@@ -24,6 +24,9 @@ mod-memoize = {path="../mod-memoize"}
|
||||
mod-redis = {path="../mod-redis"}
|
||||
mod-sqlite = {path="../mod-sqlite"}
|
||||
once_cell = "1.17"
|
||||
rcgen = "0.10"
|
||||
rustls = "0.20"
|
||||
rustls-pemfile = "1.0"
|
||||
serde_json = "1.0"
|
||||
throttle = {path="../throttle"}
|
||||
tokio = {version="1.25", features=["full", "tracing"]}
|
||||
|
||||
@@ -4,6 +4,7 @@ use mlua::{Function, Lua, LuaSerdeExt, Value};
|
||||
use mod_redis::RedisConnKey;
|
||||
|
||||
pub mod diagnostic_logging;
|
||||
pub mod tls_helpers;
|
||||
|
||||
pub fn register(lua: &Lua) -> anyhow::Result<()> {
|
||||
for func in [
|
||||
|
||||
@@ -49,10 +49,8 @@ once_cell = "1.17"
|
||||
ppp = "2.2"
|
||||
prometheus = "0.13"
|
||||
rand = "0.8"
|
||||
rcgen = "0.10"
|
||||
rfc5321 = {path="../rfc5321"}
|
||||
rustls = "0.20"
|
||||
rustls-pemfile = "1.0"
|
||||
serde = {version="1.0", features=["derive"]}
|
||||
humantime-serde = "1.1"
|
||||
self_cell = "1.0"
|
||||
|
||||
@@ -154,7 +154,7 @@ impl HttpListenerParams {
|
||||
}
|
||||
|
||||
async fn tls_config(&self) -> anyhow::Result<RustlsConfig> {
|
||||
let config = crate::tls_helpers::make_server_config(
|
||||
let config = kumo_server_common::tls_helpers::make_server_config(
|
||||
&self.hostname,
|
||||
&self.tls_private_key,
|
||||
&self.tls_certificate,
|
||||
|
||||
@@ -22,7 +22,6 @@ mod ready_queue;
|
||||
mod smtp_dispatcher;
|
||||
mod smtp_server;
|
||||
mod spool;
|
||||
mod tls_helpers;
|
||||
|
||||
/// KumoMTA Daemon.
|
||||
///
|
||||
|
||||
@@ -208,7 +208,7 @@ impl EsmtpListenerParams {
|
||||
return Ok(TlsAcceptor::from(config.clone()));
|
||||
}
|
||||
|
||||
let config = crate::tls_helpers::make_server_config(
|
||||
let config = kumo_server_common::tls_helpers::make_server_config(
|
||||
&self.hostname,
|
||||
&self.tls_private_key,
|
||||
&self.tls_certificate,
|
||||
|
||||
Reference in New Issue
Block a user