zoukankan      html  css  js  c++  java
  • 让Sendmail和Dovecot使用AD进行用户认证

    如果AD认证不通过则使用linux系统认证。

    /etc/ldap.conf:

    host 192.168.1.1
    base dc=mycompany,dc=local
    binddn ldap@mycompany.local
    bindpw Thisisaveryhardpassword
    ldap_version 3
    port 389
    pam_filter objectclass=User
    pam_login_attribute sAMAccountName
    pam_password ad
    ssl no

    /etc/pam.d/dovecot:

    #%PAM-1.0
    auth       required     pam_nologin.so
    auth       sufficient   pam_ldap.so
    auth       required     pam_stack.so service=system-auth
    account    sufficient   pam_ldap.so
    account    required     pam_stack.so service=system-auth
    session    required     pam_stack.so service=system-auth

    /etc/pam.d/smtp:

    #%PAM-1.0
    auth       sufficient   pam_ldap.so
    auth       required     pam_stack.so service=system-auth
    account    sufficient   pam_ldap.so
    account    required     pam_stack.so service=system-auth

    /etc/sysconfig/saslauthd:

    # Directory in which to place saslauthd's listening socket, pid file, and so
    # on.  This directory must already exist.
    SOCKETDIR=/var/run/saslauthd

    # Mechanism to use when checking passwords.  Run "saslauthd -v" to get a list
    # of which mechanism your installation was compiled to use.
    #MECH=shadow
    MECH=pam

    # Additional flags to pass to saslauthd on the command line.  See saslauthd(8)
    # for the list of accepted flags.
    FLAGS=

    参考:

    http://www.redhat.com/docs/manuals/linux/RHL-8.0-Manual/ref-guide/s1-pam-modules.html

  • 相关阅读:
    揭开HTTPS神秘面纱
    HTTP常见状态码
    js常用小代码
    通俗讲解OSI七层模型
    WSCDL所在的协议栈位置
    Models and Verification of BPEL
    mysql root密码修改
    c++ Socket 学习笔记一
    mysql备份
    圣杯布局
  • 原文地址:https://www.cnblogs.com/amonw/p/1667688.html
Copyright © 2011-2022 走看看