Set-OPS-Public/roles/serveur_postfix/defaults/main.yml
Daniel Allaire 20329895f7 Zéro-confiance : flux Courriel chiffré (LMTP verify + client_smtp STARTTLS)
Deux sauts est-ouest en clair, corrigés :
- LMTP edge-mta -> infra-mail:24 : lmtp_tls_security_level=verify +
  lmtp_tls_CAfile=root_ca (le CONTENU des courriels). Dovecot LMTP offrait
  déjà STARTTLS (cert step-ca, SAN infra-mail-01) : aucun changement Dovecot.
- client_smtp -> edge-mta:25 : msmtp tls_starttls on + tls_trust_file root_ca.

Prouvé : livraison LMTP status=sent (verify ⇒ TLS obligatoire), msmtp tls=on
smtpstatus=250. Déjà chiffrés : submission :587, Postfix->LDAP ldaps, IMAP :993.

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
2026-07-04 21:47:29 -04:00

44 lines
2.1 KiB
YAML

---
# Postfix 3.x (Debian 13) — MTA du nœud edge-mta : réception :25, cartes LDAP (domaines,
# boîtes, alias), remise LMTP réseau vers le nœud mail-store (Dovecot). TLS via step_ca.
# NE STOCKE AUCUNE BOÎTE. Cf. docs/courriel-conception.md + docs/identite-sso.md.
serveur_postfix_paquets:
- postfix
- postfix-ldap
serveur_postfix_service: "postfix"
serveur_postfix_domaine: "{{ domaine_interne }}"
serveur_postfix_nom_hote: "{{ ansible_fqdn | default(ansible_hostname) }}"
# Réseaux internes de confiance (relais autorisé). À adapter au réseau de l'instance.
serveur_postfix_reseaux_confiance: "127.0.0.0/8 [::1]/128"
# --- Nœud mail-store (Dovecot) : remise LMTP réseau ---
# OBLIGATOIRE : le FQDN/nom du nœud qui héberge les boîtes (Dovecot LMTP).
serveur_postfix_mailstore_hote: ""
serveur_postfix_lmtp_port: 24
# --- Soumission :587 (clients authentifiés) ---
# SASL délégué à Dovecot (passdb LDAP prouvé) sur le nœud mail-store, via son auth réseau.
# Interne uniquement : STARTTLS requis, seuls les authentifiés relaient. Pas de sortie internet.
serveur_postfix_submission_actif: false
serveur_postfix_sasl_hote: "{{ serveur_postfix_mailstore_hote }}"
serveur_postfix_sasl_port: 12345
# --- Annuaire LDAP (validation domaines/boîtes/alias) ---
# Connexion à l'annuaire (serveur, base, bind_dn, bind_password) : fournie par le rôle partagé
# resoudre_annuaire (voir tasks/main.yml « Adopter la connexion annuaire »).
# --- Milter rspamd (antispam + DKIM) — si rspamd est co-localisé (nœud edge-mta) ---
serveur_postfix_rspamd_milter: false
serveur_postfix_rspamd_milter_port: 11332
# --- TLS via le certificat d'hôte step_ca (client_pki) ---
serveur_postfix_tls_actif: true
serveur_postfix_tls_source_cert: "/etc/step/certs/{{ ansible_fqdn | default(ansible_hostname) }}.crt"
serveur_postfix_tls_source_cle: "/etc/step/certs/{{ ansible_fqdn | default(ansible_hostname) }}.key"
serveur_postfix_tls_dir: "/etc/postfix/tls"
# Zero-confiance : verifier le TLS de la livraison LMTP vers Dovecot (cert step-ca).
serveur_postfix_lmtp_tls_verify: false
serveur_postfix_lmtp_tls_cafile: "/etc/step/certs/root_ca.crt"