主题: 邮件列表的问题,求助张站长
现在有一个邮件列表,我在IRedadmin-PRO设置了只有管理员可以发邮件到这个邮件列表,但其他用户还是可以发进去。。求助张站长还需要如何设置。
支持 Red Hat Enterprise Linux, CentOS, Scientific Linux, Debian, Ubuntu, FreeBSD, OpenBSD
您尚未登陆。 请选择登陆或是注册一个新账号。
iRedMail 开源邮件服务解决方案 » iRedMail 技术支持 » 邮件列表的问题,求助张站长
现在有一个邮件列表,我在IRedadmin-PRO设置了只有管理员可以发邮件到这个邮件列表,但其他用户还是可以发进去。。求助张站长还需要如何设置。
这个功能需要 iRedAPD 配合。
在 iRedAdmin 里设置了谁可以发送之后,需要确保 iRedAPD 工作正常。请尝试将 /opt/iredapd/etc/iredapd.ini 的 log_level 设置为 debug,然后重新发送一封测试邮件给这个列表,看看 iRedAPD 的日志文件(/var/log/iredapd.log)里有什么提示信息可以帮助分析。
张站长,我设置为debug后 信息如下,我的账号 chenwenbin@infoservice.com.cn 发送到 test@infoservice.com.cn 这个邮件列表 在 iredadmin 里设置为只有管理员可以发送到这个邮件列表,我自己(chenwenbin@infoservice.com.cn)不是管理员。
iredapd.log 没有任何log信息。
/var/log/iredapd-rr.log
DEBUG信息如下:
2011-05-26 14:16:29 DEBUG Connect from 127.0.0.1
2011-05-26 14:16:29 DEBUG smtp session: request=smtpd_access_policy
2011-05-26 14:16:29 DEBUG smtp session: protocol_state=RCPT
2011-05-26 14:16:29 DEBUG smtp session: protocol_name=ESMTP
2011-05-26 14:16:29 DEBUG smtp session: client_address=210.13.111.28
2011-05-26 14:16:29 DEBUG smtp session: client_name=unknown
2011-05-26 14:16:29 DEBUG smtp session: reverse_client_name=unknown
2011-05-26 14:16:29 DEBUG smtp session: helo_name=INUI-PC
2011-05-26 14:16:29 DEBUG smtp session: sender=chenwenbin@infoservice.com.cn
2011-05-26 14:16:29 DEBUG smtp session: recipient=chenwenbin@infoservice.com.cn
2011-05-26 14:16:29 DEBUG smtp session: recipient_count=0
2011-05-26 14:16:29 DEBUG smtp session: queue_id=
2011-05-26 14:16:29 DEBUG smtp session: instance=234.4dddf03d.6b6bf.0
2011-05-26 14:16:29 DEBUG smtp session: size=565
2011-05-26 14:16:29 DEBUG smtp session: etrn_domain=
2011-05-26 14:16:29 DEBUG smtp session: stress=
2011-05-26 14:16:29 DEBUG smtp session: sasl_method=LOGIN
2011-05-26 14:16:29 DEBUG smtp session: sasl_username=chenwenbin@infoservice.com.cn
2011-05-26 14:16:29 DEBUG smtp session: sasl_sender=
2011-05-26 14:16:29 DEBUG smtp session: ccert_subject=
2011-05-26 14:16:29 DEBUG smtp session: ccert_issuer=
2011-05-26 14:16:29 DEBUG smtp session: ccert_fingerprint=
2011-05-26 14:16:29 DEBUG smtp session: encryption_protocol=TLSv1
2011-05-26 14:16:29 DEBUG smtp session: encryption_cipher=EDH-RSA-DES-CBC3-SHA
2011-05-26 14:16:29 DEBUG smtp session: encryption_keysize=168
2011-05-26 14:16:29 DEBUG LDAP connection initialied success.
2011-05-26 14:16:29 DEBUG LDAP bind success.
2011-05-26 14:16:29 DEBUG __get_sender_dn_ldif (sender): chenwenbin@infoservice.com.cn
2011-05-26 14:16:29 DEBUG __get_sender_dn_ldif: Quering LDAP
2011-05-26 14:16:29 DEBUG __get_sender_dn_ldif (result): [('mail=chenwenbin@infoservice.com.cn,ou=Users,domainName=infoservice.com.cn,o=domains,dc=infoservice,dc=com.cn', {'memberOfGroup': ['staff@infoservice.com.cn', 'yy1@infoservice.com.cn', 'test@infoservice.com.cn'], 'uid': ['chenwenbin'], 'mailQuota': ['209715200'], 'objectClass': ['inetOrgPerson', 'mailUser', 'shadowAccount', 'top'], 'userPassword': ['{MD5}lueSGJZetyySpUndWjMBEg=='], 'accountStatus': ['active'], 'mtaTransport': ['dovecot'], 'sn': ['chenwenbin'], 'homeDirectory': ['/var/vmail/vmail01/infoservice.com.cn/c/ch/che/chenwenbin-2010.12.07.12.07.51/'], 'mail': ['chenwenbin@infoservice.com.cn'], 'storageBaseDirectory': ['/var/vmail/vmail01'], 'mailMessageStore': ['infoservice.com.cn/c/ch/che/chenwenbin-2010.12.07.12.07.51/'], 'enabledService': ['mail', 'smtp', 'pop3', 'pop3secured', 'imap', 'imapsecured', 'deliver', 'forward', 'senderbcc', 'recipientbcc', 'managesieve', 'managesievesecured', 'shadowaddress', 'displayedInGlobalAddressBook'], 'cn': ['\xe9\x99\x88\xe6\x96\x87\xe6\x96\x8c']})]
2011-05-26 14:16:29 DEBUG Apply plugin (ldap_recipient_restrictions).
2011-05-26 14:16:29 DEBUG Response from plugin (ldap_recipient_restrictions): DUNNO
2011-05-26 14:16:29 DEBUG Final action: DUNNO.
2011-05-26 14:16:29 INFO chenwenbin@infoservice.com.cn -> chenwenbin@infoservice.com.cn, DUNNO
2011-05-26 14:16:29 DEBUG Connection closed
iRedAPD已经可以正常使用,黑白名单也起作用。就是邮件列表这里有些问题。请帮忙分析一下原因。谢谢
另 : 邮件列表是否有数量限制 ,我的邮件列表已经超出50个列表。是否会导致什么问题。非常感谢
2011-05-26 14:16:29 DEBUG smtp session: sender=chenwenbin@infoservice.com.cn
2011-05-26 14:16:29 DEBUG smtp session: recipient=chenwenbin@infoservice.com.cn
这里显示的是自己发给自己,而不是发到 test@ 邮件列表。应该是贴错了日志了,麻烦重新贴一下。
另 : 邮件列表是否有数量限制 ,我的邮件列表已经超出50个列表。是否会导致什么问题。非常感谢
所有帐号类型(域名、用户、邮件列表、邮件别名、管理员)都没有数量限制。50个不是问题。
我重新看了debug信息如下
2011-05-28 19:17:56 DEBUG Connect from 127.0.0.1
2011-05-28 19:17:56 DEBUG smtp session: request=smtpd_access_policy
2011-05-28 19:17:56 DEBUG smtp session: protocol_state=RCPT
2011-05-28 19:17:56 DEBUG smtp session: protocol_name=ESMTP
2011-05-28 19:17:56 DEBUG smtp session: client_address=114.92.219.97
2011-05-28 19:17:56 DEBUG smtp session: client_name=unknown
2011-05-28 19:17:56 DEBUG smtp session: reverse_client_name=unknown
2011-05-28 19:17:56 DEBUG smtp session: helo_name=INUI-PC
2011-05-28 19:17:56 DEBUG smtp session: sender=chenwenbin@infoservice.com.cn
2011-05-28 19:17:56 DEBUG smtp session: recipient=test@infoservice.com.cn
2011-05-28 19:17:56 DEBUG smtp session: recipient_count=0
2011-05-28 19:17:56 DEBUG smtp session: queue_id=
2011-05-28 19:17:56 DEBUG smtp session: instance=457f.4de0d9e4.5bc8f.0
2011-05-28 19:17:56 DEBUG smtp session: size=9612
2011-05-28 19:17:56 DEBUG smtp session: etrn_domain=
2011-05-28 19:17:56 DEBUG smtp session: stress=
2011-05-28 19:17:56 DEBUG smtp session: sasl_method=LOGIN
2011-05-28 19:17:56 DEBUG smtp session: sasl_username=chenwenbin@infoservice.com.cn
2011-05-28 19:17:56 DEBUG smtp session: sasl_sender=
2011-05-28 19:17:56 DEBUG smtp session: ccert_subject=
2011-05-28 19:17:56 DEBUG smtp session: ccert_issuer=
2011-05-28 19:17:56 DEBUG smtp session: ccert_fingerprint=
2011-05-28 19:17:56 DEBUG smtp session: encryption_protocol=TLSv1
2011-05-28 19:17:56 DEBUG smtp session: encryption_cipher=EDH-RSA-DES-CBC3-SHA
2011-05-28 19:17:56 DEBUG smtp session: encryption_keysize=168
2011-05-28 19:17:56 DEBUG LDAP connection initialied success.
2011-05-28 19:17:56 DEBUG LDAP bind success.
2011-05-28 19:17:56 DEBUG __get_sender_dn_ldif (sender): chenwenbin@infoservice.com.cn
2011-05-28 19:17:56 DEBUG __get_sender_dn_ldif: Quering LDAP
2011-05-28 19:17:56 DEBUG __get_sender_dn_ldif (result): [('mail=chenwenbin@infoservice.com.cn,ou=Users,domainName=infoservice.com.cn,o=domains,dc=infoservice,dc=com.cn', {'memberOfGroup': ['staff@infoservice.com.cn', 'yy1@infoservice.com.cn', 'test@infoservice.com.cn'], 'uid': ['chenwenbin'], 'mailQuota': ['209715200'], 'objectClass': ['inetOrgPerson', 'mailUser', 'shadowAccount', 'top'], 'userPassword': ['{MD5}lueSGJZetyySpUndWjMBEg=='], 'accountStatus': ['active'], 'mtaTransport': ['dovecot'], 'sn': ['chenwenbin'], 'homeDirectory': ['/var/vmail/vmail01/infoservice.com.cn/c/ch/che/chenwenbin-2010.12.07.12.07.51/'], 'mail': ['chenwenbin@infoservice.com.cn'], 'storageBaseDirectory': ['/var/vmail/vmail01'], 'mailMessageStore': ['infoservice.com.cn/c/ch/che/chenwenbin-2010.12.07.12.07.51/'], 'enabledService': ['mail', 'smtp', 'pop3', 'pop3secured', 'imap', 'imapsecured', 'deliver', 'forward', 'senderbcc', 'recipientbcc', 'managesieve', 'managesievesecured', 'shadowaddress', 'displayedInGlobalAddressBook'], 'cn': ['\xe9\x99\x88\xe6\x96\x87\xe6\x96\x8c']})]
2011-05-28 19:17:56 DEBUG Apply plugin (ldap_recipient_restrictions).
2011-05-28 19:17:56 DEBUG Response from plugin (ldap_recipient_restrictions): DUNNO
2011-05-28 19:17:56 DEBUG Final action: DUNNO.
2011-05-28 19:17:56 INFO chenwenbin@infoservice.com.cn -> test@infoservice.com.cn, DUNNO
test邮件组的ldap信息:
# LDIF Export for mail=test@infoservice.com.cn,ou=Groups,domainName=infoservice.com.cn,o=domains,dc=infoservice,dc=com.cn
# 服务器: My LDAP Server (127.0.0.1)
# 搜索范围: base
# 搜索过滤器: (objectClass=*)
# 条目总数: 1
#
# Generated by phpLDAPadmin (http://phpldapadmin.sourceforge.net) on May 28, 2011 11:25 am
# Version: 1.2.0.5
version: 1
# 条目 1: mail=test@infoservice.com.cn,ou=Groups,domainName=infoservice...
dn: mail=test@infoservice.com.cn,ou=Groups,domainName=infoservice.com.cn,o=d
omains,dc=infoservice,dc=com.cn
accesspolicy: allowedOnly
accountstatus: active
cn: test
enabledservice: mail
enabledservice: deliver
enabledservice: displayedInGlobalAddressBook
hasmember: yes
listalloweduser: heyan@infoservice.com.cn
mail: test@infoservice.com.cn
objectclass: mailList
张站长:请帮忙分析下,为什么可以收到非管理员发到这个邮件组。非常感谢
2011-05-28 19:17:56 DEBUG Apply plugin (ldap_recipient_restrictions).
2011-05-28 19:17:56 DEBUG Response from plugin (ldap_recipient_restrictions): DUNNO
您贴的是 /var/log/iredapd-rr.log 里的内容吧?邮件列表权限控制应该是插件 ldap_maillist_access_*.
麻烦您贴一下命令 "postconf -n" 的输出信息,以及 /opt/iredapd/etc/iredapd.ini 的内容(记得去掉密码再贴上来)。
[root@mail ~]# postconf -n
alias_database = hash:/etc/postfix/aliases
alias_maps = hash:/etc/postfix/aliases
allow_min_user = no
biff = no
bounce_queue_lifetime = 1d
broken_sasl_auth_clients = yes
command_directory = /usr/sbin
config_directory = /etc/postfix
content_filter = smtp-amavis:[127.0.0.1]:10024
daemon_directory = /usr/libexec/postfix
data_directory = /var/lib/postfix
debug_peer_level = 2
delay_warning_time = 0h
disable_vrfy_command = yes
enable_original_recipient = no
home_mailbox = Maildir/
html_directory = no
inet_interfaces = all
inet_protocols = ipv4
mail_owner = postfix
mailbox_command = /usr/libexec/dovecot/deliver
mailq_path = /usr/bin/mailq.postfix
manpage_directory = /usr/share/man
maximal_backoff_time = 4000s
maximal_queue_lifetime = 1d
message_size_limit = 15728640
minimal_backoff_time = 300s
mydestination = $myhostname, localhost, localhost.localdomain, localhost.$myhostname
mydomain = XXXX
myhostname =XXXX
mynetworks = 127.0.0.0/8
mynetworks_style = subnet
myorigin =XXXX
newaliases_path = /usr/bin/newaliases.postfix
proxy_read_maps = $canonical_maps $lmtp_generic_maps $local_recipient_maps $mydestination $mynetworks $recipient_bcc_maps $recipient_canonical_maps $relay_domains $relay_recipient_maps $relocated_maps $sender_bcc_maps $sender_canonical_maps $smtp_generic_maps $smtpd_sender_login_maps $transport_maps $virtual_alias_domains $virtual_alias_maps $virtual_mailbox_domains $virtual_mailbox_maps $smtpd_sender_restrictions
queue_directory = /var/spool/postfix
queue_run_delay = 300s
readme_directory = /usr/share/doc/postfix-2.5.9/README_FILES
recipient_bcc_maps = proxy:ldap:/etc/postfix/ldap/recipient_bcc_maps_domain.cf, proxy:ldap:/etc/postfix/ldap/recipient_bcc_maps_user.cf
recipient_delimiter = +
relay_domains = $mydestination, proxy:ldap:/etc/postfix/ldap/relay_domains.cf
sample_directory = /usr/share/doc/postfix-2.5.9/samples
sender_bcc_maps = proxy:ldap:/etc/postfix/ldap/sender_bcc_maps_domain.cf, proxy:ldap:/etc/postfix/ldap/sender_bcc_maps_user.cf
sendmail_path = /usr/sbin/sendmail.postfix
setgid_group = postdrop
smtpd_data_restrictions = reject_unauth_pipelining
smtpd_enforce_tls = no
smtpd_helo_required = yes
smtpd_helo_restrictions = permit_mynetworks,permit_sasl_authenticated, check_helo_access pcre:/etc/postfix/helo_access.pcre
smtpd_recipient_restrictions = reject_unknown_sender_domain, reject_unknown_recipient_domain, reject_non_fqdn_sender, reject_non_fqdn_recipient, reject_unlisted_recipient, check_policy_service inet:127.0.0.1:7778, permit_mynetworks, permit_sasl_authenticated, reject_unauth_destination, reject_non_fqdn_helo_hostname, reject_invalid_helo_hostname, check_policy_service inet:127.0.0.1:10031
smtpd_reject_unlisted_recipient = yes
smtpd_reject_unlisted_sender = yes
smtpd_sasl_auth_enable = yes
smtpd_sasl_authenticated_header = no
smtpd_sasl_local_domain =
smtpd_sasl_path = ./dovecot-auth
smtpd_sasl_security_options = noanonymous
smtpd_sasl_type = dovecot
smtpd_sender_login_maps = proxy:ldap:/etc/postfix/ldap/sender_login_maps.cf
smtpd_sender_restrictions = permit_mynetworks, reject_sender_login_mismatch, permit_sasl_authenticated
smtpd_tls_CAfile = /etc/pki/tls/certs/iRedMail_CA.pem
smtpd_tls_cert_file = /etc/pki/tls/certs/iRedMail_CA.pem
smtpd_tls_key_file = /etc/pki/tls/private/iRedMail.key
smtpd_tls_loglevel = 0
smtpd_tls_security_level = may
tls_random_source = dev:/dev/urandom
transport_maps = proxy:ldap:/etc/postfix/ldap/transport_maps_user.cf, proxy:ldap:/etc/postfix/ldap/transport_maps_domain.cf
unknown_local_recipient_reject_code = 550
virtual_alias_domains =
virtual_alias_maps = proxy:ldap:/etc/postfix/ldap/virtual_alias_maps.cf, proxy:ldap:/etc/postfix/ldap/virtual_group_maps.cf, proxy:ldap:/etc/postfix/ldap/sender_login_maps.cf, proxy:ldap:/etc/postfix/ldap/catchall_maps.cf
virtual_gid_maps = static:500
virtual_mailbox_base = /var/vmail
virtual_mailbox_domains = proxy:ldap:/etc/postfix/ldap/virtual_mailbox_domains.cf
virtual_mailbox_maps = proxy:ldap:/etc/postfix/ldap/virtual_mailbox_maps.cf
virtual_minimum_uid = 500
virtual_transport = dovecot
virtual_uid_maps = static:500
iredapd.ini
[root@mail ~]# cat /opt/iredapd/etc/iredapd.ini
[general]
# Listen address and port.
listen_addr = 127.0.0.1
listen_port = 7777
bypass_mynetworks = yes
# Run as a low privileged user.
# If you don't want to create one, you can try 'nobody'.
run_as_user = iredapd
# Background/daemon mode: yes, no.
# Run iRedAPD as daemon, detach iredapd from terminal.
run_as_daemon = yes
# Path to pid file.
pid_file = /var/run/iredapd.pid
# Log type: file.
# Set 'log_file = /dev/null' if you don't want to keep the log.
log_type = file
log_file = /var/log/iredapd.log
# Log level: info, warning, error, debug.
# 'info' is recommended for product use. sample log entry:
# INFO user@domain.ltd -> list@domain.ltd, DUNNO
log_level = info
# Backend: ldap, mysql.
backend = ldap
[ldap]
# For ldap backend only.
# LDAP server setting.
# Uri must starts with ldap:// or ldaps:// (TLS/SSL).
#
# Tip: You can get binddn, bindpw from /etc/postfix/ldap_*.cf.
#
uri = ldap://127.0.0.1:389
binddn = cn=vmail,dc=infoservice,dc=com.cn
bindpw =
basedn = o=domains,dc=infoservice,dc=com.cn
# Enabled plugins.
# - Plugin name is file name which placed under 'src/plugins/' directory.
# - Plugin names MUST be seperated by comma.
#
# Available plugins:
# * ldap_domain_wblist: per-domain white/blacklist support.
# Note: If you want to enable this plugin, it's better to make it the
# first one in enabled plugin list.
# * ldap_maillist_access_policy: mail list deliver restrictions.
# * block_amavisd_blacklisted_senders: per-user white/blacklist support.
plugins = ldap_maillist_access_policy,block_amavisd_blacklisted_senders
[mysql]
# For MySQL backend only.
server = 127.0.0.1
db = vmail
user = vmail
password =
# Enabled plugins.
# - Plugin name is file name which placed under 'src/plugins/' directory.
# - Plugin names MUST be seperated by comma.
plugins = sql_alias_access_policy
smtpd_recipient_restrictions = ..., check_policy_service inet:127.0.0.1:7778, ...
这里应该是端口 7777,而不是 7778。
已解决,非常感谢!
iRedMail 开源邮件服务解决方案 » iRedMail 技术支持 » 邮件列表的问题,求助张站长
Powered by PunBB, supported by Informer Technologies, Inc.
Currently installed 3 official extensions. Copyright © 2003–2010 PunBB.
页面生成时间 0.008 秒, 共执行查询 65 条