From b2c89091d81667c85c28d26ee15707ba8d8209ae Mon Sep 17 00:00:00 2001 From: Gonne Date: Sun, 2 Mar 2025 08:37:40 +0100 Subject: [PATCH] Accept mail from our badly configured VMs --- nixos/modules/mail.nix | 15 +++++++++++++++ 1 file changed, 15 insertions(+) diff --git a/nixos/modules/mail.nix b/nixos/modules/mail.nix index 94cfae6..62fe93a 100644 --- a/nixos/modules/mail.nix +++ b/nixos/modules/mail.nix @@ -159,6 +159,21 @@ in { ]; }; + session.ehlo.require = [ + { + "if" = "starts_with(remote_ip, '192.168.0.')"; #TODO setup vms properly + "then" = false; + } + {"else" = true;} + ]; + session.ehlo.reject-non-fqdn = [ + { + "if" = "starts_with(remote_ip, '192.168.0.')"; #TODO setup vms properly + "then" = false; + } + {"else" = true;} + ]; + # Stalwart gets its configuration from two places: A TOML configuration file that we control in this module # and from a database that can be configured from web management interface or via Rest API. # We here define what comes from the TOML-file and especially add "sieve.trusted.scripts.*" to the default ones