• # Sasl Cyrus & Kerberos

    Posté par (site web personnel) . En réponse au message postfix + SASL/kerberos. Évalué à 1.

    Salut,

    J'ai un postfix qui inclu un smtpd submission avec auth via GSSAPI, par contre il n'est pas possible de le faire avec support de l'auth plain ET gssapi en meme temps, ou du moins pas de la façon mise en oeuvre (via saslauthd):

    http://www.postfix.org/SASL_README.html

    saslauthd - Cyrus SASL password verification service

    Important

    Do not specify any other mechanisms in mech_list than PLAIN or LOGIN when using saslauthd! It can only handle these two mechanisms, and authentication will fail if clients are allowed to choose other mechanisms.

    Ma configuration est assez ancienne et il est peut-être possible de faire autrement maintenant mais la voici. L'auth n'est active que sur le service submission (tcp/587) avec le SSL d'actif:

    main.cf

    smtpd_use_tls = yes
    smtpd_tls_CAfile = /etc/ssl/certs/...
    smtpd_tls_cert_file = /etc/ssl/local/...
    smtpd_tls_key_file = /etc/ssl/private/...
    smtpd_tls_received_header = yes
    # /!\ dans le chroot => /var/spool/postfix/etc/smtp.keytab
    import_environment = KRB5_KTNAME=/etc/smtp.keytab
    smtpd_sasl_security_options = noanonymous noplaintext noactive
    smtpd_sasl_local_domain = "REALM.NET"

    master.cf:

    submission inet n - - - - smtpd
     -o smtpd_enforce_tls=yes
     -o smtpd_sasl_auth_enable=yes
     -o smtpd_helo_restrictions=permit_sasl_authenticated,reject
     -o smtpd_client_restrictions=permit_sasl_authenticated,reject
     -o smtpd_sender_restrictions=reject_non_fqdn_sender,reject_unknown_sender_domain,reject_unlisted_sender,permit_sasl_authenticated,reject
     -o smtpd_recipient_restrictions=reject_non_fqdn_recipient,reject_unknown_recipient_domain,reject_unlisted_recipient,permit_sasl_authenticated,reject
     -o smtpd_etrn_restrictions=reject
     -o smtpd_sasl_authenticated_header=yes