ldap_routing.m4
上传用户:xu_441
上传日期:2007-01-04
资源大小:1640k
文件大小:1k
源码类别:

Email客户端

开发平台:

Unix_Linux

  1. divert(-1)
  2. #
  3. # Copyright (c) 1999 Sendmail, Inc. and its suppliers.
  4. # All rights reserved.
  5. #
  6. # By using this file, you agree to the terms and conditions set
  7. # forth in the LICENSE file which can be found at the top level of
  8. # the sendmail distribution.
  9. #
  10. #
  11. divert(0)
  12. VERSIONID(`$Id: ldap_routing.m4,v 8.3 1999/10/19 22:54:19 gshapiro Exp $')
  13. divert(-1)
  14. # Check first two arguments.  If they aren't set, may need to warn in proto.m4
  15. ifelse(len(X`'_ARG1_), `1', `define(`_LDAP_ROUTING_WARN_', `yes')')
  16. ifelse(len(X`'_ARG2_), `1', `define(`_LDAP_ROUTING_WARN_', `yes')')
  17. # Check for third argument to indicate how to deal with non-existant
  18. # LDAP records
  19. ifelse(len(X`'_ARG3_), `1', `define(`_LDAP_ROUTING_', `_PASS_THROUGH_')',
  20.     `define(`_LDAP_ROUTING_', `_MUST_EXIST_')')
  21. LOCAL_CONFIG
  22. # LDAP routing maps
  23. Kldap_mailhost ifelse(len(X`'_ARG1_), `1',
  24.       `ldap -1 -v mailHost -k (&(objectClass=inetLocalMailRecipient)(mailLocalAddress=%0))',
  25.       `_ARG1_')
  26. Kldap_mailroutingaddress ifelse(len(X`'_ARG2_), `1',
  27. `ldap -1 -v mailRoutingAddress -k (&(objectClass=inetLocalMailRecipient)(mailLocalAddress=%0))',
  28. `_ARG2_')