AskOverflow.Dev

AskOverflow.Dev Logo AskOverflow.Dev Logo

AskOverflow.Dev Navigation

  • 主页
  • 系统&网络
  • Ubuntu
  • Unix
  • DBA
  • Computer
  • Coding
  • LangChain

Mobile menu

Close
  • 主页
  • 系统&网络
    • 最新
    • 热门
    • 标签
  • Ubuntu
    • 最新
    • 热门
    • 标签
  • Unix
    • 最新
    • 标签
  • DBA
    • 最新
    • 标签
  • Computer
    • 最新
    • 标签
  • Coding
    • 最新
    • 标签
主页 / server / 问题

问题[amavis](server)

Martin Hope
Mike M
Asked: 2021-10-03 01:14:22 +0800 CST

后缀不接受收件人地址:连接到私有/策略:连接被拒绝

  • 1

我以为我会很聪明,并将 amavis/spamassassin/clamav 添加到我工作的 Postfix 安装中。我让它工作,然后做出改变。走开,喝了杯啤酒,然后发现我搞砸了。这就是现在发生的事情

Oct  2 22:01:59 wilma postfix/smtpd[1048101]: Anonymous TLS connection established from mail-pf1-f172.google.com[209.85.210.172]: TLSv1.3 with cipher TLS_AES_128_GCM_SHA256 (128/128 bits) key-exchange X25519 server-signature RSA-PSS (2048 bits) server-digest SHA256
Oct  2 22:01:59 wilma postfix/smtpd[1048101]: warning: connect to private/policy: Connection refused
Oct  2 22:01:59 wilma postfix/smtpd[1048101]: warning: problem talking to server private/policy: Connection refused
Oct  2 22:02:00 wilma postfix/smtpd[1048101]: warning: connect to private/policy: Connection refused
Oct  2 22:02:00 wilma postfix/smtpd[1048101]: warning: problem talking to server private/policy: Connection refused
Oct  2 22:02:00 wilma postfix/smtpd[1048101]: NOQUEUE: reject: RCPT from mail-pf1-f172.google.com[209.85.210.172]: 451 4.3.5 <[email protected]>: Recipient address rejected: Server configuration problem; from=<[email protected]> to=<[email protected]> proto=ESMTP helo=<mail-pf1-f172.google.com>
Oct  2 22:02:02 wilma postfix/smtpd[1048101]: disconnect from mail-pf1-f172.google.com[209.85.210.172] ehlo=2 starttls=1 mail=1 rcpt=0/1 bdat=0/1 quit=1 commands=5/7

我在谷歌上下搜索寻找答案,似乎“451 4.3.5”是一个通用错误。

这是master.cf ...

smtp       inet  n       -       n       -       -       smtpd
submission inet  n       -       n       -       -       smtpd
pickup     fifo  n       -       n       60      1       pickup
cleanup    unix  n       -       n       -       0       cleanup
qmgr       fifo  n       -       n       300     1       qmgr
tlsmgr     unix  -       -       n       1000?   1       tlsmgr
rewrite    unix  -       -       n       -       -       trivial-rewrite
bounce     unix  -       -       n       -       0       bounce
defer      unix  -       -       n       -       0       bounce
trace      unix  -       -       n       -       0       bounce
verify     unix  -       -       n       -       1       verify
flush      unix  n       -       n       1000?   0       flush
proxymap   unix  -       -       n       -       -       proxymap
proxywrite unix  -       -       n       -       1       proxymap
smtp       unix  -       -       n       -       -       smtp
relay      unix  -       -       n       -       -       smtp -o smtp_fallback_relay=
showq      unix  n       -       n       -       -       showq
error      unix  -       -       n       -       -       error
retry      unix  -       -       n       -       -       error
discard    unix  -       -       n       -       -       discard
local      unix  -       n       n       -       -       local
virtual    unix  -       n       n       -       -       virtual
lmtp       unix  -       -       n       -       -       lmtp
anvil      unix  -       -       n       -       1       anvil
scache     unix  -       -       n       -       1       scache
smtp-amavis unix -       -       n       -       2       smtp -o syslog_name=postfix/amavis -o smtp_data_done_timeout=1200 -o smtp_send_xforward_command=yes -o disable_dns_lookups=yes -o max_use=20 -o smtp_tls_security_level=none
127.0.0.1:10025 inet n   -       n       -       -       smtpd -o syslog_name=postfix/10025 -o content_filter= -o mynetworks_style=host -o mynetworks=127.0.0.0/8 -o local_recipient_maps= -o relay_recipient_maps= -o strict_rfc821_envelopes=yes -o smtp_tls_security_level=none -o smtpd_tls_security_level=none -o smtpd_restriction_classes= -o smtpd_delay_reject=no -o smtpd_client_restrictions=permit_mynetworks,reject -o smtpd_helo_restrictions= -o smtpd_sender_restrictions= -o smtpd_recipient_restrictions=permit_mynetworks,reject -o smtpd_end_of_data_restrictions= -o smtpd_error_sleep_time=0 -o smtpd_soft_error_limit=1001 -o smtpd_hard_error_limit=1000 -o smtpd_client_connection_count_limit=0 -o smtpd_client_connection_rate_limit=0 -o receive_override_options=no_header_body_checks,no_unknown_recipient_checks,no_address_mappings

main.cf 是

alias_database = hash:/etc/postfix/aliases
alias_maps = hash:/etc/postfix/aliases
broken_sasl_auth_clients = yes
canonical_maps = hash:/etc/postfix/canonical
command_directory = /usr/sbin
content_filter = smtp-amavis:[127.0.0.1]:10024
data_directory = /var/lib/postfix
debug_peer_level = 1
debug_peer_list =
default_privs = mail
delay_warning_time = 4
header_checks = regexp:/etc/postfix/regexp_table
html_directory = no
in_flow_delay = 1s
inet_interfaces = all
inet_protocols = ipv4
local_recipient_maps = unix:passwd.byname $alias_maps
local_transport = local
mail_owner = postfix
mail_spool_directory = /var/virtual
mailbox_command = /usr/bin/procmail -a "$EXTENSION"
mailbox_size_limit = 3221225472
mailq_path = /usr/bin/mailq.postfix
manpage_directory = /usr/share/man
message_size_limit = 25971520
mydestination = $myhostname, localhost.$mydomain, $mydomain, lists.$mydomain
mydomain = mike-mac.gen.nz
myhostname = mail.mike-mac.gen.nz
mynetworks = 192.168.1.0/24 192.168.3.0/24 webmail.mike-mac.gen.nz localhost.localdomain localhost
myorigin = $mydomain
newaliases_path = /usr/bin/newaliases.postfix
queue_directory = /var/spool/postfix
readme_directory = /usr/share/doc/postfix-2.0.13/README_FILES
receive_override_options = no_address_mappings
recipient_delimiter = +
reject_code = 550
sample_directory = /usr/share/doc/postfix-2.0.13/samples
sendmail_path = /usr/sbin/sendmail.postfix
setgid_group = postdrop
smtp_tls_note_starttls_offer = yes
smtp_tls_security_level = may
smtpd_hard_error_limit = 4
smtpd_helo_required = no
smtpd_helo_restrictions = permit_mynetworks, check_helo_access hash:/etc/postfix/helo_access
smtpd_proxy_options = speed_adjust
smtpd_recipient_restrictions = permit_sasl_authenticated, permit_mynetworks, reject_unauth_destination, reject_unknown_sender_domain, check_policy_service unix:private/policy, reject_rbl_client zen.spamhaus.org, reject_rbl_client bl.spamcop.net, reject_rbl_client cbl.abuseat.org
smtpd_relay_restrictions = permit_sasl_authenticated, permit_mynetworks, reject_unauth_destination, reject_unknown_sender_domain, reject_rbl_client zen.spamhaus.org, reject_rbl_client bl.spamcop.net, reject_rbl_client cbl.abuseat.org
smtpd_sasl_auth_enable = yes
smtpd_sasl_local_domain =
smtpd_sasl_path = private/auth
smtpd_sasl_security_options = noanonymous
smtpd_sasl_type = dovecot
smtpd_soft_error_limit = 2
smtpd_tls_CAfile = /etc/ssl/certs/cacert.pem
smtpd_tls_auth_only = no
smtpd_tls_cert_file = /etc/letsencrypt/live/Email_cert/fullchain.pem
smtpd_tls_key_file = /etc/letsencrypt/live/Email_cert/privkey.pem
smtpd_tls_loglevel = 1
smtpd_tls_received_header = yes
smtpd_tls_security_level = may
smtpd_tls_session_cache_timeout = 3600s
strict_mailbox_ownership = no
tls_random_source = dev:/dev/urandom
undisclosed_recipients_header = To: NotSayingWhoGetsThis:;
unknown_local_recipient_reject_code = 550
virtual_alias_maps = hash:/etc/postfix/virtual
virtual_gid_maps = static:12
virtual_mailbox_base = /var/virtual
virtual_mailbox_domains = hash:/etc/postfix/vmaildomains
virtual_mailbox_limit = 2147483648
virtual_mailbox_maps = hash:/etc/postfix/vmailbox,hash:/etc/postfix/virtual-user-map-family.kiwi.nz,hash:/etc/postfix/virtual-user-map-coders.kiwi.nz,hash:/etc/postfix/virtual-user-map-mak.co.nz,hash:/etc/postfix/virtual-user-map-lessonplans.kiwi.nz
virtual_minimum_uid = 1
virtual_transport = virtual
virtual_uid_maps = static:8`

正在运行的守护进程是

systemctl status postfix postgrey amavis spamassassin clamav-freshclam
● postfix.service - Postfix Mail Transport Agent
     Loaded: loaded (/lib/systemd/system/postfix.service; enabled; vendor preset: enabled)
     Active: active (exited) since Sat 2021-10-02 21:58:34 NZDT; 29min ago
    Process: 1047688 ExecStart=/bin/true (code=exited, status=0/SUCCESS)
   Main PID: 1047688 (code=exited, status=0/SUCCESS)

Oct 02 21:58:34 wilma systemd[1]: Starting Postfix Mail Transport Agent...
Oct 02 21:58:34 wilma systemd[1]: Finished Postfix Mail Transport Agent.

● postgrey.service - LSB: Start/stop the postgrey daemon
     Loaded: loaded (/etc/init.d/postgrey; generated)
     Active: active (running) since Sat 2021-10-02 21:58:34 NZDT; 29min ago
       Docs: man:systemd-sysv-generator(8)
    Process: 1047510 ExecStart=/etc/init.d/postgrey start (code=exited, status=0/SUCCESS)
      Tasks: 1 (limit: 17839)
     Memory: 18.7M
     CGroup: /system.slice/postgrey.service
             └─1039871 postgrey --pidfile=/var/run/postgrey.pid --daemonize --inet=10023

Oct 02 21:58:34 wilma postgrey[1047518]: whitelisted: 194.7.234.142/32
Oct 02 21:58:34 wilma postgrey[1047518]: whitelisted: 194.7.234.143/32
Oct 02 21:58:34 wilma postgrey[1047518]: whitelisted: 213.143.66.210/32
Oct 02 21:58:34 wilma postgrey[1047518]: Pid_file "/var/run/postgrey.pid" already exists.  Overwriting!
Oct 02 21:58:34 wilma postgrey[1047583]: Process Backgrounded
Oct 02 21:58:34 wilma systemd[1]: Started LSB: Start/stop the postgrey daemon.
Oct 02 21:58:34 wilma postgrey[1047510]:    ...done.
Oct 02 21:58:34 wilma postgrey[1047583]: 2021/10/02-21:58:34 postgrey (type Net::Server::Multiplex) starting! pid(1047583)
Oct 02 21:58:34 wilma postgrey[1047583]: Resolved [localhost]:10023 to [127.0.0.1]:10023, IPv4
Oct 02 21:58:34 wilma postgrey[1047583]: Binding to TCP port 10023 on host 127.0.0.1 with IPv4

● amavis.service - LSB: Starts amavisd-new mailfilter
     Loaded: loaded (/etc/init.d/amavis; generated)
     Active: active (running) since Sat 2021-10-02 21:58:35 NZDT; 29min ago
       Docs: man:systemd-sysv-generator(8)
    Process: 1047562 ExecStart=/etc/init.d/amavis start (code=exited, status=0/SUCCESS)
      Tasks: 3 (limit: 17839)
     Memory: 160.8M
     CGroup: /system.slice/amavis.service
             ├─1047705 /usr/sbin/amavisd-new (master)
             ├─1047714 /usr/sbin/amavisd-new (virgin child)
             └─1047715 /usr/sbin/amavisd-new (virgin child)

Oct 02 21:58:35 wilma amavis[1047705]: No ext program for   .zoo, tried: zoo
Oct 02 21:58:35 wilma amavis[1047705]: No ext program for   .doc, tried: ripole
Oct 02 21:58:35 wilma amavis[1047705]: No decoder for       .F
Oct 02 21:58:35 wilma amavis[1047705]: No decoder for       .doc
Oct 02 21:58:35 wilma amavis[1047705]: No decoder for       .lrz
Oct 02 21:58:35 wilma amavis[1047705]: No decoder for       .zoo
Oct 02 21:58:35 wilma amavis[1047562]: Starting amavisd: amavisd-new.
Oct 02 21:58:35 wilma amavis[1047705]: Using primary internal av scanner code for ClamAV-clamd
Oct 02 21:58:35 wilma systemd[1]: Started LSB: Starts amavisd-new mailfilter.
Oct 02 21:58:35 wilma amavis[1047705]: Found secondary av scanner ClamAV-clamscan at /usr/bin/clamscan

● spamassassin.service - Perl-based spam filter using text analysis
     Loaded: loaded (/lib/systemd/system/spamassassin.service; enabled; vendor preset: enabled)
     Active: active (running) since Sat 2021-10-02 21:58:36 NZDT; 29min ago
    Process: 1047534 ExecStart=/usr/sbin/spamd -d --pidfile=/run/spamd.pid $OPTIONS (code=exited, status=0/SUCCESS)
   Main PID: 1047641 (spamd)
      Tasks: 3 (limit: 17839)
     Memory: 109.2M
     CGroup: /system.slice/spamassassin.service
             ├─1047641 /usr/bin/perl -T -w /usr/sbin/spamd -d --pidfile=/run/spamd.pid --create-prefs --max-children 5 --username >
             ├─1047711 spamd child
             └─1047712 spamd child

Oct 02 21:58:33 wilma systemd[1]: Starting Perl-based spam filter using text analysis...
Oct 02 21:58:36 wilma systemd[1]: Started Perl-based spam filter using text analysis.

● clamav-freshclam.service - ClamAV virus database updater
     Loaded: loaded (/lib/systemd/system/clamav-freshclam.service; enabled; vendor preset: enabled)
     Active: active (running) since Sat 2021-10-02 16:08:46 NZDT; 6h ago
       Docs: man:freshclam(1)
             man:freshclam.conf(5)
             https://www.clamav.net/documents
   Main PID: 990816 (freshclam)
      Tasks: 1 (limit: 17839)
     Memory: 227.4M
     CGroup: /system.slice/clamav-freshclam.service
             └─990816 /usr/bin/freshclam -d --foreground=true

Oct 02 21:09:46 wilma freshclam[990816]: Sat Oct  2 21:09:46 2021 -> main.cvd database is up-to-date (version: 62, sigs: 6647427, >
Oct 02 21:09:46 wilma freshclam[990816]: Sat Oct  2 21:09:46 2021 -> bytecode.cld database is up-to-date (version: 333, sigs: 92, >
Oct 02 22:09:46 wilma freshclam[990816]: Sat Oct  2 22:09:46 2021 -> Received signal: wake up
Oct 02 22:09:46 wilma freshclam[990816]: Sat Oct  2 22:09:46 2021 -> ClamAV update process started at Sat Oct  2 22:09:46 2021
Oct 02 22:09:46 wilma freshclam[990816]: Sat Oct  2 22:09:46 2021 -> ^Your ClamAV installation is OUTDATED!
Oct 02 22:09:46 wilma freshclam[990816]: Sat Oct  2 22:09:46 2021 -> ^Local version: 0.103.2 Recommended version: 0.103.3
Oct 02 22:09:46 wilma freshclam[990816]: Sat Oct  2 22:09:46 2021 -> DON'T PANIC! Read https://www.clamav.net/documents/upgrading->
Oct 02 22:09:46 wilma freshclam[990816]: Sat Oct  2 22:09:46 2021 -> daily.cvd database is up-to-date (version: 26309, sigs: 19380>
Oct 02 22:09:46 wilma freshclam[990816]: Sat Oct  2 22:09:46 2021 -> main.cvd database is up-to-date (version: 62, sigs: 6647427, >
Oct 02 22:09:46 wilma freshclam[990816]: Sat Oct  2 22:09:46 2021 -> bytecode.cld database is up-to-date (version: 333, sigs: 92, 

我意识到我最大的错误是愚蠢,我应该在开始之前备份 main 和 master.cf 文件。话虽如此,任何人都可以看到我看不到的东西吗?

postconf -n
access_map_reject_code = 550
alias_database = hash:/etc/postfix/aliases
alias_maps = hash:/etc/postfix/aliases
broken_sasl_auth_clients = yes
canonical_maps = hash:/etc/postfix/canonical
command_directory = /usr/sbin
content_filter = smtp-amavis:[127.0.0.1]:10024
data_directory = /var/lib/postfix
debug_peer_level = 1
debug_peer_list =
default_privs = mail
delay_warning_time = 4
header_checks = regexp:/etc/postfix/regexp_table
html_directory = no
in_flow_delay = 1s
inet_interfaces = all
inet_protocols = ipv4
local_recipient_maps = unix:passwd.byname $alias_maps
local_transport = local
mail_owner = postfix
mail_spool_directory = /var/virtual
mailbox_command = /usr/bin/procmail -a "$EXTENSION"
mailbox_size_limit = 3221225472
mailq_path = /usr/bin/mailq.postfix
manpage_directory = /usr/share/man
message_size_limit = 25971520
mydestination = $myhostname, localhost.$mydomain, $mydomain, lists.$mydomain
mydomain = mike-mac.gen.nz
myhostname = mail.mike-mac.gen.nz
mynetworks = 192.168.1.0/24 192.168.3.0/24 webmail.mike-mac.gen.nz localhost.localdomain localhost
myorigin = $mydomain
newaliases_path = /usr/bin/newaliases.postfix
queue_directory = /var/spool/postfix
readme_directory = /usr/share/doc/postfix-2.0.13/README_FILES
receive_override_options = no_address_mappings
recipient_delimiter = +
reject_code = 550
sample_directory = /usr/share/doc/postfix-2.0.13/samples
sendmail_path = /usr/sbin/sendmail.postfix
setgid_group = postdrop
smtp_tls_note_starttls_offer = yes
smtp_tls_security_level = may
smtpd_hard_error_limit = 4
smtpd_helo_required = no
smtpd_helo_restrictions = permit_mynetworks, check_helo_access hash:/etc/postfix/helo_access
smtpd_proxy_options = speed_adjust
smtpd_recipient_restrictions = permit_sasl_authenticated, permit_mynetworks, reject_unauth_destination, reject_unknown_sender_domain, check_policy_service unix:private/policy, reject_rbl_client zen.spamhaus.org, reject_rbl_client bl.spamcop.net, reject_rbl_client cbl.abuseat.org
smtpd_relay_restrictions = permit_sasl_authenticated, permit_mynetworks, reject_unauth_destination, reject_unknown_sender_domain, reject_rbl_client zen.spamhaus.org, reject_rbl_client bl.spamcop.net, reject_rbl_client cbl.abuseat.org
smtpd_sasl_auth_enable = yes
smtpd_sasl_local_domain =
smtpd_sasl_path = private/auth
smtpd_sasl_security_options = noanonymous
smtpd_sasl_type = dovecot
smtpd_soft_error_limit = 2
smtpd_tls_CAfile = /etc/ssl/certs/cacert.pem
smtpd_tls_auth_only = no
smtpd_tls_cert_file = /etc/letsencrypt/live/Email_cert/fullchain.pem
smtpd_tls_key_file = /etc/letsencrypt/live/Email_cert/privkey.pem
smtpd_tls_loglevel = 1
smtpd_tls_received_header = yes
smtpd_tls_security_level = may
smtpd_tls_session_cache_timeout = 3600s
strict_mailbox_ownership = no
tls_random_source = dev:/dev/urandom
undisclosed_recipients_header = To: NotSayingWhoGetsThis:;
unknown_local_recipient_reject_code = 550
virtual_alias_maps = hash:/etc/postfix/virtual
virtual_gid_maps = static:12
virtual_mailbox_base = /var/virtual
virtual_mailbox_domains = hash:/etc/postfix/vmaildomains
virtual_mailbox_limit = 2147483648
virtual_mailbox_maps = hash:/etc/postfix/vmailbox,hash:/etc/postfix/virtual-user-map-family.kiwi.nz,hash:/etc/postfix/virtual-user-map-coders.kiwi.nz,hash:/etc/postfix/virtual-user-map-mak.co.nz,hash:/etc/postfix/virtual-user-map-lessonplans.kiwi.nz
virtual_minimum_uid = 1
virtual_transport = virtual
virtual_uid_maps = static:8
postconf -M
smtp       inet  n       -       n       -       -       smtpd
submission inet  n       -       n       -       -       smtpd
pickup     fifo  n       -       n       60      1       pickup
cleanup    unix  n       -       n       -       0       cleanup
qmgr       fifo  n       -       n       300     1       qmgr
tlsmgr     unix  -       -       n       1000?   1       tlsmgr
rewrite    unix  -       -       n       -       -       trivial-rewrite
bounce     unix  -       -       n       -       0       bounce
defer      unix  -       -       n       -       0       bounce
trace      unix  -       -       n       -       0       bounce
verify     unix  -       -       n       -       1       verify
flush      unix  n       -       n       1000?   0       flush
proxymap   unix  -       -       n       -       -       proxymap
proxywrite unix  -       -       n       -       1       proxymap
smtp       unix  -       -       n       -       -       smtp
relay      unix  -       -       n       -       -       smtp -o smtp_fallback_relay=
showq      unix  n       -       n       -       -       showq
error      unix  -       -       n       -       -       error
retry      unix  -       -       n       -       -       error
discard    unix  -       -       n       -       -       discard
local      unix  -       n       n       -       -       local
virtual    unix  -       n       n       -       -       virtual
lmtp       unix  -       -       n       -       -       lmtp
anvil      unix  -       -       n       -       1       anvil
scache     unix  -       -       n       -       1       scache
smtp-amavis unix -       -       n       -       2       smtp -o syslog_name=postfix/amavis -o smtp_data_done_timeout=1200 -o smtp_send_xforward_command=yes -o disable_dns_lookups=yes -o max_use=20 -o smtp_tls_security_level=none
127.0.0.1:10025 inet n   -       n       -       -       smtpd -o syslog_name=postfix/10025 -o content_filter= -o mynetworks_style=host -o mynetworks=127.0.0.0/8 -o local_recipient_maps= -o relay_recipient_maps= -o strict_rfc821_envelopes=yes -o smtp_tls_security_level=none -o smtpd_tls_security_level=none -o smtpd_restriction_classes= -o smtpd_delay_reject=no -o smtpd_client_restrictions=permit_mynetworks,reject -o smtpd_helo_restrictions= -o smtpd_sender_restrictions= -o smtpd_recipient_restrictions=permit_mynetworks,reject -o smtpd_end_of_data_restrictions= -o smtpd_error_sleep_time=0 -o smtpd_soft_error_limit=1001 -o smtpd_hard_error_limit=1000 -o smtpd_client_connection_count_limit=0 -o smtpd_client_connection_rate_limit=0 -o receive_override_options=no_header_body_checks,no_unknown_recipient_checks,no_address_mappings
postfix spamassassin clamav amavis
  • 1 个回答
  • 266 Views
Martin Hope
philolegein
Asked: 2021-09-20 22:38:36 +0800 CST

amavisd-new-2.12 的最终归宿在哪里?

  • 0

我已经amavis从 安装epel,它报告

# systemctl status amavisd
● amavisd.service - Amavis mail content checker
   Loaded: loaded (/usr/lib/systemd/system/amavisd.service; enabled; vendor preset: disabled)
   Active: active (running) since Fri 2021-09-17 14:39:27 UTC; 2 days ago
     Docs: http://www.ijs.si/software/amavisd/#doc
# amavisd -V
amavisd-new-2.12.0 (20190725)

我正在尝试查找文档,但是,AFAICT(包括基于上述输出systemctl status)IJS 是 amavisd-new 的最终归宿,但 2.12 似乎并不存在。指向“最新”的软链接指向 2.8,并且绝对最新列出的是 amavisd-new-2.11.1。也许我的 google-foo 很弱,但是…… 2.12 版的最终归宿在哪里?

amavis
  • 1 个回答
  • 57 Views
Martin Hope
Mahsa
Asked: 2021-06-13 00:38:41 +0800 CST

“.pre”文件的 Amavis 和 Spamassassin 错误(使用 iRedMail)

  • 0

我安装了 iRedMail,它将安装 amavis 和 spamassassin。当我测试发送和接收电子邮件时,我有一个错误/var/log/mail.log,我看到这行错误:

postfix/amavis/smtp[14582]: 连接到 127.0.0.1[127.0.0.1]:10026: 连接被拒绝

当我运行这一行时: $sudo amavisd-new debug 我在输出的末尾看到:

文件位于 config 目录中。\nv320.pre 至少会加载所需的 Check 插件。6 月 12 日 11:58:25.764 mail.example.com /usr/sbin/amavisd-new[20040]: sd_notify (no socket): STOPPING=1\nSTATUS=TROUBLE in pre_loop_hook: Timeout::_run: check: no loaded plugin实现“check_main”:无法扫描!\n检查必要的“.pre”文件是否在配置目录中。\nv320.pre 至少会加载所需的检查插件。6 月 12 日 11:58:25.764 mail.example.com /usr/sbin/amavisd-new[20040]: (!)_DIE: Suicide () TROUBLE in pre_loop_hook: Timeout::_run: check: no loaded plugin implements 'check_main' : 无法扫描!\n检查必要的“.pre”文件是否在配置目录中。\nv320.pre 至少会加载所需的检查插件。pre_loop_hook 中的 Suicide () TROUBLE: Timeout::_run: 检查:没有加载的插件实现'check_main':无法扫描!检查必要的“.pre”文件是否在配置目录中。v320.pre 至少会加载所需的 Check 插件。

这也是 的输出$spamassassin --lint -D:

Timeout::_run: check: no loaded plugin implements 'check_main': 无法扫描!检查必要的“.pre”文件是否在配置目录中。v320.pre 至少会加载所需的 Check 插件

我在目录中查找,在其中/etc/mail/spamassassin看不到任何“.pre”文件。我还使用这个搜索v320.pre文件: $sudo find / -iname v320.pre没有结果。

如果我使用以下命令禁用 amavis: $sudo nano /etc/amavis/conf.d/50-user 并更改这两行:

@bypass_virus_checks_maps = (1); @bypass_spam_checks_maps = (1);

然后重新启动服务: $sudo systemctl restart amavis 然后处理邮件队列: $postqueue -f 邮件服务器可以正常工作!所以很明显我应该在/etc/mail/spamassassin目录中放一些'.pre'文件。我发现这个网址中有一些“.pre”文件: https ://apache.googlesource.com/spamassassin/+/trunk/rules 我的问题是:下载这些文件并将它们放在我的目录中是否安全? 或者一般我在哪里可以找到“.pre”文件或生成它们?

postfix spamassassin iredmail amavis
  • 1 个回答
  • 705 Views
Martin Hope
Sreehari Nair
Asked: 2021-06-11 22:21:46 +0800 CST

Posftwd 与 Posftix 和 amavis 一起使用时会重复计算电子邮件

  • 3

我们的 Postfix 邮件服务器使用带有垃圾邮件刺客的 Amavis 进行垃圾邮件和病毒扫描。我们以某种方式对其进行了设置,postfix 将邮件转发到 amavis 和 amavis,然后将电子邮件重新排队返回 postfix 以将其发送到目的地。我已经用一个简单的规则设置了 postfwd 以在发件人阈值之后拒绝电子邮件,但 Postfwd 重复计算了电子邮件。当我通过 Outlook 作为邮件客户端发送一封电子邮件时,Postfwd 将其计为两封。我是 SMTP 协议的新手,正在努力找出问题所在。如果有人可以请帮忙。我粘贴了一些我认为在下面有用的配置片段。

下面是 postconf -n 的输出

append_dot_mydomain = no
biff = no
broken_sasl_auth_clients = yes
content_filter = amavis:[127.0.0.1]:10024
disable_vrfy_command = yes
dovecot_destination_recipient_limit = 1
enable_original_recipient = no
header_checks = regexp:/etc/postfix/header_checks
inet_interfaces = all
mailbox_size_limit = 0
maximal_backoff_time = 8000s
maximal_queue_lifetime = 7d
minimal_backoff_time = 1000s
mydestination = $myhostname
myhostname = pXXX
mynetworks = 127.0.0.0/8 [::ffff:127.0.0.0]/104 [::1]/128,XXX
mynetworks_style = host
myorigin = /etc/hostname
readme_directory = no
recipient_delimiter = +
relay_domains = hash:/etc/postfix/relay_recipients
smtp_enforce_tls = no
smtp_helo_timeout = 60s
smtp_tls_note_starttls_offer = yes
smtp_tls_security_level = may
smtp_use_tls = yes
smtpd_banner = $myhostname ESMTP $mail_name
smtpd_client_connection_count_limit = 30
smtpd_client_recipient_rate_limit = 300
smtpd_client_restrictions = permit_mynetworks, permit_sasl_authenticated, check_client_access hash:/etc/postfix/whitelist, reject_rbl_client sbl.spamhaus.org
smtpd_data_restrictions = reject_unauth_pipelining
smtpd_delay_reject = yes
smtpd_enforce_tls = no
smtpd_hard_error_limit = 12
smtpd_helo_required = yes
smtpd_helo_restrictions = check_client_access hash:/etc/postfix/whitelist, permit_mynetworks, warn_if_reject reject_non_fqdn_hostname, reject_invalid_hostname
smtpd_recipient_limit = 30
smtpd_recipient_restrictions = reject_unauth_pipelining, check_policy_service inet:127.0.0.1:10040, permit_mynetworks, permit_sasl_authenticated, reject_non_fqdn_recipient, reject_unknown_recipient_domain, reject_unauth_destination, check_policy_service inet:127.0.0.1:10023
smtpd_relay_restrictions = permit_mynetworks, check_client_access hash:/etc/postfix/whitelist, check_sender_access hash:/etc/postfix/whitelist, permit_sasl_authenticated, reject_non_fqdn_recipient, reject_unknown_recipient_domain, reject_unauth_destination, check_policy_service inet:127.0.0.1:10023
smtpd_sasl_auth_enable = yes
smtpd_sasl_authenticated_header = yes
smtpd_sasl_local_domain =
smtpd_sasl_path = private/auth
smtpd_sasl_type = dovecot
smtpd_sender_restrictions = check_sender_access hash:/etc/postfix/sender_access, permit_sasl_authenticated, permit_mynetworks, reject_unknown_sender_domain, reject_unauth_pipelining, warn_if_reject reject_sender_login_mismatch, warn_if_reject reject_non_fqdn_sender, warn_if_reject reject_unlisted_sender, warn_if_reject reject_non_fqdn_sender
smtpd_soft_error_limit = 3
smtpd_tls_cert_file = XXX
smtpd_tls_key_file = XXX
smtpd_tls_loglevel = 1
smtpd_tls_received_header = yes
smtpd_tls_security_level = may
smtpd_tls_session_cache_timeout = 3600s
smtpd_use_tls = yes
tls_random_source = dev:/dev/urandom
transport_maps = hash:/etc/postfix/transport
unknown_local_recipient_reject_code = 450
virtual_alias_maps = proxy:mysql:/etc/postfix/mysql_virtual_alias_maps.cf, proxy:mysql:/etc/postfix/mysql_virtual_alias_domainaliases_maps.cf
virtual_gid_maps = static:125
virtual_mailbox_base = /home/vmail
virtual_mailbox_domains = proxy:mysql:/etc/postfix/mysql_virtual_domains_maps.cf
virtual_mailbox_maps = proxy:mysql:/etc/postfix/mysql_virtual_mailbox_maps.cf, proxy:mysql:/etc/postfix/mysql_virtual_mailbox_domainaliases_maps.cf
virtual_transport = dovecot
virtual_uid_maps = static:150

后发规则:

id=20perminute; sender=~/[email protected]/; action=rate(sender/20/60/REJECT only 20 messages per minute for $$sender)

任何人都可以帮助解决这个问题吗?

postfix amavis postfwd
  • 1 个回答
  • 163 Views
Martin Hope
JVOD
Asked: 2021-02-19 10:29:55 +0800 CST

AMAVIS 丢弃电子邮件而不是标记它们或将它们移动到隔离区

  • 0

我看到许多电子邮件从我的系统中被丢弃。我是每个用户的策略,并设置了以下选项: spam_tag_level = -9999 spam_tag2_level = 7(大致 - 它根据每个用户而变化) spam_tag3_level = 25 spam_kill_level = 40 spam_dsn_cutoff_level = 999 spam_quarantine_cutoff_level = 999

我想要的是在主题中以这种方式标记所有垃圾邮件,或者最多被隔离,但我不希望任何被拒绝/丢弃。

请您提供有关如何按照我的意愿进行这项工作的想法吗?

谢谢!

编辑:我看到我的 amavisd sql 返回 0 代替我的 spam_tag_level 等 - 以前有人经历过吗?当我查看数据库时,对于 spam_tag_level 等,它已正确设置为 -9999,并且它确实在日志中说它找到了一行。

amavis
  • 1 个回答
  • 192 Views
Martin Hope
TommyPeanuts
Asked: 2021-01-05 05:04:25 +0800 CST

Postfix:如何恶意软件和垃圾邮件扫描传出的 SMTP SASL 身份验证用户?

  • 0

尽管我已经找到了两个 答案,但我无法弄清楚如何实际实施它们,并且至少其中一个并没有真正回答这个问题。因此,如果有人有任何经验可以分享,我将非常感激。

我有一台运行 Postfix 的服务器(Ubuntu 18.04)。我已经使用 postfwd 对 SASL 发件人进行速率限制,并使用 Amavis 和其他东西来扫描来自本地机器/网络(例如来自 Web 服务器)的传出邮件。没关系,在 main.cf 中看起来像这样:

smtpd_sender_restrictions =
    check_client_access cidr:/etc/postfix/internal_clients_filter,
    permit_mynetworks, 
    reject_unknown_sender_domain

在 master.cf 中

senderCheck  unix  -       n       n       -       15       spawn
  user=nobody argv=/opt/policyd/src/policyd.pl  max_idle=30 max_use=50 daemon_timeout=50

127.0.0.1:10025 inet    n    -    n    -    -    smtpd
    -o smtpd_recipient_restrictions=permit_mynetworks,reject
    -o smtpd_restriction_classes=
    -o smtpd_delay_reject=no
    -o smtpd_client_restrictions=
    -o smtpd_helo_restrictions=
    -o smtpd_sender_restrictions=
    -o mynetworks=127.0.0.0/8
    -o smtpd_data_restrictions=
    -o smtpd_end_of_data_restrictions=
    -o local_header_rewrite_clients=
    -o smtpd_error_sleep_time=0
    -o smtpd_soft_error_limit=1001
    -o smtpd_hard_error_limit=1000
    -o smtpd_client_connection_count_limit=0
    -o smtpd_client_connection_rate_limit=0
    -o smtpd_milters=
    -o local_recipient_maps=
    -o relay_recipient_maps=
    -o receive_override_options=no_header_body_checks,no_unknown_recipient_checks,no_address_mappings

如何以与本地发件人相同的方式将 SASL 发件人(根据定义不在我的网络上)通过垃圾邮件和恶意软件扫描?

spam postfix spamassassin sasl amavis
  • 1 个回答
  • 307 Views
Martin Hope
chmike
Asked: 2020-11-11 11:32:38 +0800 CST

Amavis 在主题中添加垃圾邮件标记,但邮件不是垃圾邮件

  • 2

我有一个带有 posfix、amavis 和 spamassassin 的 Debian 10 服务器。

我管理的另一台服务器每天都会发送一封邮件,其中不包含任何内容,只有一个 gif 作为附件。我已将 spamassassin 的 local.cf 中的发件人地址列入白名单。

收到的邮件的标头包含以下内容:

X-Spam-Checker-Version: SpamAssassin 3.4.2 (2018-09-13) on ~~~.~~~.net
X-Spam-Level: 
X-Spam-Status: No, score=-93.2 required=5.0 tests=ALL_TRUSTED,BAYES_50,
    DC_GIF_UNO_LARGO,DC_IMAGE_SPAM_TEXT,MISSING_HEADERS,PYZOR_CHECK,
    SB_GIF_AND_NO_URIS,TVD_SPACE_RATIO,USER_IN_WHITELIST autolearn=no
    autolearn_force=no version=3.4.2

这表示邮件不被视为垃圾邮件,因为发件人地址在白名单中。

问题是主题字段包含[SPAM]哪个是垃圾邮件标记。这个垃圾邮件标记在我的 spamassassin local.cf 和 amavis 中定义。我还不知道两者中的哪一个正在添加此垃圾邮件标记。

根据amavis的配置,不应该放垃圾标签,因为我在配置里有这个

$sa_tag2_level_deflt = 5.0; #add spam tag to subject for score greater than this value
$sa_spam_subject_tag = '[SPAM]';

如我们所见,分数较低。amavis 不应添加此垃圾邮件标签。

那么如何在主题行中获取垃圾邮件标签?

我确定问题出在我的邮件服务器上,因为当我将该邮件发送到另一个地址时,我没有收到垃圾邮件标签。

另一个奇怪的事情是,当我从桌面发送具有相同发件人地址的完全相同的邮件时,它没有收到垃圾邮件标签。

编辑:我有另外两封邮件的 amavis 行为不一致。

通过一封邮件,我有这个: 

Received: from localhost by xxx.xxx.net
    with SpamAssassin (version 3.4.2);
    Wed, 11 Nov 2020 17:08:01 +0100
From: huixin0010 <[email protected]>
Subject: [*SPAM*] [~SPAM~]Re: Leather bags manufacturer with 14 years experience
X-Spam-Checker-Version: SpamAssassin 3.4.2 (2018-09-13) on xxx.xxx.net
X-Spam-Flag: YES
X-Spam-Level: ******
X-Spam-Status: Yes, score=6.3 required=5.0 tests=BAYES_50,DEAR_SOMETHING,
    FREEMAIL_FORGED_FROMDOMAIN,FREEMAIL_FROM,HEADER_FROM_DIFFERENT_DOMAINS,
    HTML_MESSAGE,HTML_MIME_NO_HTML_TAG,MIME_HTML_ONLY,PYZOR_CHECK,
    RCVD_IN_MSPIKE_BL,RCVD_IN_MSPIKE_L5,RDNS_NONE,T_SPF_HELO_PERMERROR
    autolearn=no autolearn_force=no version=3.4.2

[*SPAM*]spamassassin 添加[~SPAM~]的垃圾邮件标签和 amavis 添加的垃圾邮件标签在哪里。

规则设置为 amavis 在分数高于 5 时添加垃圾邮件标签。

出乎意料的是下面这封邮件,即使分数高于 5,amavis 也没有在主题中添加垃圾邮件标签。

Received: from localhost by xxx.xxx.net
    with SpamAssassin (version 3.4.2);
    Wed, 11 Nov 2020 18:08:24 +0100
From: liyulan029 <[email protected]>
To: xxx <[email protected]>
Subject: [*SPAM*] Re: new design eyeglasses frame and sunglasses
Date: Thu, 12 Nov 2020 01:10:33 +0800 (CST)
X-Spam-Checker-Version: SpamAssassin 3.4.2 (2018-09-13) on xxx.xxx.net
X-Spam-Flag: YES
X-Spam-Level: ******
X-Spam-Status: Yes, score=6.2 required=5.0 tests=BAYES_50,DEAR_SOMETHING,
    FREEMAIL_FORGED_FROMDOMAIN,FREEMAIL_FROM,HEADER_FROM_DIFFERENT_DOMAINS,
    HTML_MESSAGE,HTML_MIME_NO_HTML_TAG,MIME_HTML_ONLY,RCVD_IN_RP_RNBL,
    RDNS_NONE autolearn=no autolearn_force=no version=3.4.2

这两个邮件之间的服务器上没有任何变化。

postfix spamassassin amavis
  • 1 个回答
  • 1017 Views
Martin Hope
UnlegitApple
Asked: 2020-07-22 14:09:08 +0800 CST

OpenDKIM 无法启动:“opendkim:必须指定 milter 套接字”

  • 3

我正在尝试使用 postfix、dovecot、amavis 和 opendkim 来设置服务器进行签名。

OpenDKIM 不会启动,这是journalctl -xe停止并启动 opendkim 后的输出:

Jul 21 21:54:17 mail systemd[1]: Starting OpenDKIM DomainKeys Identified Mail (DKIM) Milter...
-- Subject: A start job for unit opendkim.service has begun execution
-- Defined-By: systemd
-- Support: http://www.ubuntu.com/support
--
-- A start job for unit opendkim.service has begun execution.
--
-- The job identifier is 54385.
Jul 21 21:54:17 mail opendkim[108677]: opendkim: milter socket must be specified
Jul 21 21:54:17 mail systemd[1]: opendkim.service: Control process exited, code=exited, status=78/CONFIG
-- Subject: Unit process exited
-- Defined-By: systemd
-- Support: http://www.ubuntu.com/support
--
-- An ExecStart= process belonging to unit opendkim.service has exited.
--
-- The process' exit code is 'exited' and its exit status is 78.
Jul 21 21:54:17 mail systemd[1]: opendkim.service: Failed with result 'exit-code'.
-- Subject: Unit failed
-- Defined-By: systemd
-- Support: http://www.ubuntu.com/support
--
-- The unit opendkim.service has entered the 'failed' state with result 'exit-code'.

我的 OpenDKIM (/etc/opendkim.conf) 配置如下所示:

Syslog              yes
LogResults          yes
LogWhy              yes
SyslogSuccess       yes
UMask               002
Canonicalization    relaxed/relaxed

# Only sign, don't verify (Amavis takes care of the verification)
Mode                s

KeyTable            /etc/opendkim/keytable
SigningTable        refile:/etc/opendkim/signingtable

正如您在配置中看到的,我只希望 OpenDKIM 签名,而不是验证。

debian postfix email-server opendkim amavis
  • 1 个回答
  • 3499 Views
Martin Hope
Wes Cossick
Asked: 2017-02-23 09:44:27 +0800 CST

Amavis 因未知原因崩溃

  • 1

Amavis 因未知原因而崩溃。幸运的是,我们安装了 Monit,它会在一分钟内重新启动服务,但这只是问题上的创可贴。我们需要解决真正的问题。

在崩溃之前,以下日志条目存在于/var/log/syslog:

Feb 22 17:02:20 hoa systemd[1]: Stopping LSB: Starts amavisd-new mailfilter...
Feb 22 17:02:20 hoa amavis[23039]: (23039-01) (!)TempDir removal: tempdir is to be PRESERVED: /var/lib/amavis/tmp/amavis-20170222T170218-23039-CLjT8mUN
Feb 22 17:02:20 hoa amavis[22755]: (22755-08) (!)TempDir removal: tempdir is to be PRESERVED: /var/lib/amavis/tmp/amavis-20170222T170035-22755-v7F3P0kr
Feb 22 17:02:20 hoa amavis[21924]: (21924-20) (!)TempDir removal: tempdir is to be PRESERVED: /var/lib/amavis/tmp/amavis-20170222T165050-21924-Vi1AOnu5
Feb 22 17:02:20 hoa amavis[22053]: (22053-14) (!)TempDir removal: tempdir is to be PRESERVED: /var/lib/amavis/tmp/amavis-20170222T165124-22053-V_dDmOmV
Feb 22 17:02:20 hoa postfix/10025/smtpd[22719]: disconnect from localhost[127.0.0.1]
Feb 22 17:02:20 hoa postfix/10025/smtpd[22759]: disconnect from localhost[127.0.0.1]
Feb 22 17:02:20 hoa postfix/10025/smtpd[22718]: disconnect from localhost[127.0.0.1]
Feb 22 17:02:20 hoa postfix/smtp-amavis/smtp[22710]: B07E111FD54: to=<[email protected]>, relay=127.0.0.1[127.0.0.1]:10024, delay=17, delays=0.23/14/0.31/2.3, dsn=4.3.2, status=deferred (host 127.0.0.1[127.0.0.1] said: 421 4.3.2 Service shutting down, closing channel (in reply to end of DATA command))
Feb 22 17:02:20 hoa postfix/smtp-amavis/smtp[22710]: connect to 127.0.0.1[127.0.0.1]:10024: Connection refused
Feb 22 17:02:20 hoa postfix/smtp-amavis/smtp[22709]: B07E111FD54: to=<[email protected]>, relay=127.0.0.1[127.0.0.1]:10024, delay=17, delays=0.23/14/0.08/2.6, dsn=4.3.2, status=deferred (host 127.0.0.1[127.0.0.1] said: 421 4.3.2 Service shutting down, closing channel (in reply to end of DATA command))
Feb 22 17:02:20 hoa postfix/smtp-amavis/smtp[22709]: connect to 127.0.0.1[127.0.0.1]:10024: Connection refused
Feb 22 17:02:20 hoa postfix/smtp-amavis/smtp[22708]: BFF1D11FD58: to=<[email protected]>, relay=127.0.0.1[127.0.0.1]:10024, delay=17, delays=0.23/15/0.03/2.2, dsn=4.3.2, status=deferred (host 127.0.0.1[127.0.0.1] said: 421 4.3.2 Service shutting down, closing channel (in reply to end of DATA command))
Feb 22 17:02:20 hoa postfix/smtp-amavis/smtp[22708]: connect to 127.0.0.1[127.0.0.1]:10024: Connection refused
Feb 22 17:02:20 hoa postfix/smtp-amavis/smtp[22707]: 8CDCC11FCF4: to=<[email protected]>, relay=127.0.0.1[127.0.0.1]:10024, delay=17, delays=0.38/14/0.11/2.6, dsn=4.3.2, status=deferred (host 127.0.0.1[127.0.0.1] said: 421 4.3.2 Service shutting down, closing channel (in reply to end of DATA command))
Feb 22 17:02:20 hoa postfix/smtp-amavis/smtp[22707]: connect to 127.0.0.1[127.0.0.1]:10024: Connection refused
Feb 22 17:02:20 hoa postfix/smtp-amavis/smtp[22710]: BFF1D11FD58: to=<[email protected]>, relay=none, delay=17, delays=0.23/17/0/0, dsn=4.4.1, status=deferred (connect to 127.0.0.1[127.0.0.1]:10024: Connection refused)
Feb 22 17:02:20 hoa postfix/smtp-amavis/smtp[22707]: 16B531207A6: to=<[email protected]>, relay=none, delay=17, delays=0.42/17/0/0, dsn=4.4.1, status=deferred (connect to 127.0.0.1[127.0.0.1]:10024: Connection refused)
Feb 22 17:02:20 hoa postfix/smtp-amavis/smtp[22710]: 16B531207A6: to=<[email protected]>, relay=none, delay=17, delays=0.42/17/0/0, dsn=4.4.1, status=deferred (connect to 127.0.0.1[127.0.0.1]:10024: Connection refused)
Feb 22 17:02:20 hoa postfix/smtp-amavis/smtp[22709]: E9CA411F8BA: to=<[email protected]>, relay=none, delay=4.9, delays=0.53/4.4/0/0, dsn=4.4.1, status=deferred (connect to 127.0.0.1[127.0.0.1]:10024: Connection refused)
Feb 22 17:02:20 hoa postfix/smtp-amavis/smtp[22708]: E9CA411F8BA: to=<[email protected]>, relay=none, delay=4.9, delays=0.53/4.4/0/0, dsn=4.4.1, status=deferred (connect to 127.0.0.1[127.0.0.1]:10024: Connection refused)
Feb 22 17:02:20 hoa amavis[23084]: Stopping amavisd: amavisd-new.
Feb 22 17:02:20 hoa systemd[1]: Stopped LSB: Starts amavisd-new mailfilter.
Feb 22 17:02:21 hoa systemd[1]: Starting LSB: Starts amavisd-new mailfilter...

此时,Monit 启动,Amavis 重新启动。

我已经做了很多搜索,但似乎无法找到问题所在。服务器可能内存不足,但似乎没有记录任何有关无法分配内存的错误。因此,我不确定这是否真的是问题所在。

任何帮助,将不胜感激。

debian amavis
  • 1 个回答
  • 1009 Views
Martin Hope
Захар Joe
Asked: 2016-10-26 02:09:58 +0800 CST

Postfix 队列前垃圾邮件拒绝与 amavis 没有在 OS X 服务器上发送反弹

  • 2

这是一个库存的 OS X 5.2 服务器邮件配置,我正在尝试更改它以使其拒绝带有“554 5.7.0 Reject”的垃圾邮件,然后再接受它而不向发件人发送任何额外的未送达通知。它被配置为接受带有“250 2.7.0 Ok”的垃圾邮件,然后将其丢弃或隔离开箱。这通常是用

$final_spam_destiny       = D_REJECT;
$warnspamsender = 0; (probably not necessary)

并且可以使用微调

$sa_dsn_cutoff_level = X;
$sa_crediblefrom_dsn_cutoff_level = X;

我遇到的问题是,尽管这些截止级别远低于特定邮件的实际垃圾邮件分数,但 DSN/退回仍然可以通过。它看起来像这样:

Oct 25 11:52:18 mailbox postfix/smtpd[52962]: 1CD504D13C96: client=mail.informark.co.ua[85.25.13.92]
Oct 25 11:52:18 mailbox postfix/cleanup[53010]: 1CD504D13C96: message-id=<11a201d22e97$126f7740$2adb3d4f@ynmyfnj>
Oct 25 11:52:19 mailbox postfix/qmgr[52740]: 1CD504D13C96: from=<[email protected]>, size=145530, nrcpt=1 (queue active)
Oct 25 11:52:20 mailbox postfix/smtp[53011]: 1CD504D13C96: to=<[email protected]>, relay=127.0.0.1[127.0.0.1]:10024, delay=2.2, delays=1.1/0/0.02/1, dsn=5.7.0, status=bounced (host 127.0.0.1[127.0.0.1] said: 554 5.7.0 Reject, id=52765-01 - spam (in reply to end of DATA command))
Oct 25 11:52:20 mailbox postfix/bounce[53022]: 1CD504D13C96: sender non-delivery notification: 4B9804D13CB0
Oct 25 11:52:20 mailbox postfix/qmgr[52740]: 1CD504D13C96: removed

Oct 25 11:52:20 mailbox postfix/cleanup[53010]: 4B9804D13CB0: message-id=<[email protected]>
Oct 25 11:52:20 mailbox postfix/qmgr[52740]: 4B9804D13CB0: from=<>, size=3019, nrcpt=1 (queue active)
Oct 25 11:52:20 mailbox postfix/bounce[53022]: 1CD504D13C96: sender non-delivery notification: 4B9804D13CB0
Oct 25 11:52:20 mailbox postfix/smtp[53015]: 4B9804D13CB0: to=<[email protected]>, relay=mail.informark.co.ua[85.25.13.92]:25, delay=0.58, delays=0/0/0.26/0.32, dsn=2.0.0, status=sent (250 2.0.0 Ok: queued as 9145D8C8CCC)
Oct 25 11:52:20 mailbox postfix/qmgr[52740]: 4B9804D13CB0: removed

amavis.log(调试级别 5)中的相关部分如下所示:

lookup [forward_method] => true,  "[email protected]" matches, result="smtp:[127.0.0.1]:10025", matching_key="(opaque:smtp:[127.0.0.1]:10025)"
delivery method is 1, recips: [email protected]
get_deadline quar+notif - deadline in 479.0 s, set to 288.000 s
prolong_timer quar+notif: timer 288, was 288, deadline in 479.0 s
DSN: sender NOT credible, SA: 15.417, <[email protected]>
lookup: (scalar) matches, result="-100"
lookup [spam_dsn_cutoff_level_bysender] => true,  "[email protected]" matches, result="-100", matching_key="(constant:-100)"
dsn: . 554 Spam <[email protected]> -> <[email protected]>: on_succ=0, on_dly=1, on_fail=1, never=0, warn_sender=, DSN_passed_on=, destiny=-3, mta_resp: "554 5.7.0 Reject, id=52765-01 - spam"
DSN: FAIL . 554 Spam, status propagated back: <[email protected]> -> <[email protected]>
delivery_status_notification: notif 0 bytes, suppressed: no
one_response_for_all, per_recip_capable: N, suppressed: N
one_response_for_all <[email protected]>: REJECTs, '554 5.7.0 Reject, id=52765-01 - spam'
notif=N, suppressed=0, ndn_needed=, exit=69, 554 5.7.0 Reject, id=52765-01 - spam
get_deadline delivery-notification - deadline in 479.0 s, set to 288.000 s
prolong_timer delivery-notification: timer 288, was 288, deadline in 479.0 s
status counters: InMsgsStatus{Rejected,RejectedInbound}
get_deadline snmp-counters - deadline in 479.0 s, set to 288.000 s
prolong_timer snmp-counters: timer 288, was 288, deadline in 479.0 s
orcpt_encode rfc822, [email protected], smtputf8
oldest_public_ip_addr_from_received: 178.17.170.60
Blocked SPAM {RejectedInbound}, [85.25.13.92]:44462 [178.17.170.60] <[email protected]> -> <[email protected]>, Queue-ID: 1CD504D13C96, Message-ID: <11a201d22e97$126f7740$2adb3d4f@ynmyfnj>, mail_id: N0710n9hpdxw, Hits: 15.417, size: 145530, 1021 ms
get_deadline main_log_entry - deadline in 479.0 s, set to 288.000 s
prolong_timer main_log_entry: timer 288, was 288, deadline in 479.0 s
TIMING-SA total 817 ms - parse: 8 (1.0%), extract_message_metadata: 55 (6.7%), get_uri_detail_list: 1.42 (0.2%), tests_pri_-1000: 32 (3.9%), tests_pri_-950: 1.05 (0.1%), tests_pri_-900: 1.13 (0.1%), tests_pri_-400: 26 (3.1%), check_bayes: 24 (2.9%), b_tokenize: 11 (1.3%), b_tok_get_all: 3.5 (0.4%), b_comp_prob: 4.4 (0.5%), b_tok_touch_all: 0.80 (0.1%), b_finish: 1.12 (0.1%), tests_pri_0: 665 (81.4%), check_dkim_adsp: 479 (58.6%), check_spf: 43 (5.3%), poll_dns_idle: 0.28 (0.0%), check_pyzor: 0.25 (0.0%), tests_pri_500: 5 (0.7%), get_report: 0.77 (0.1%)
updating snmp variables in BDB
get_deadline check done - deadline in 479.0 s, set to 288.000 s
prolong_timer check done: timer 288, was 288, deadline in 479.0 s
sending SMTP response: "554 5.7.0 Reject, id=52765-01 - spam"
ESMTP> 554 5.7.0 Reject, id=52765-01 - spam
...
ESMTP< QUIT\r\n
...
ESMTP> 221 2.0.0 [127.0.0.1] amavisd-new closing transmission channel

结果,尽管明确告诉 amavis/postfix 不要向伪造的电子邮件地址发送退回邮件,甚至 amavis 在那里承认了我的愿望,但退回邮件仍然会被发送出去。我认为日志中的关键是单词“suppressed”,即“no”和“0”而不是“yes”和“1”,正如我在互联网上其他地方的 amavis 日志中看到的那样。

所以问题是我做错了什么以及是否可能有其他东西干扰设置,我也想知道调试它的最佳方法。显然,amavis 日志中的陈述是矛盾的。

mac-osx-server postfix dsn email-bounces amavis
  • 2 个回答
  • 3361 Views

Sidebar

Stats

  • 问题 205573
  • 回答 270741
  • 最佳答案 135370
  • 用户 68524
  • 热门
  • 回答
  • Marko Smith

    新安装后 postgres 的默认超级用户用户名/密码是什么?

    • 5 个回答
  • Marko Smith

    SFTP 使用什么端口?

    • 6 个回答
  • Marko Smith

    命令行列出 Windows Active Directory 组中的用户?

    • 9 个回答
  • Marko Smith

    什么是 Pem 文件,它与其他 OpenSSL 生成的密钥文件格式有何不同?

    • 3 个回答
  • Marko Smith

    如何确定bash变量是否为空?

    • 15 个回答
  • Martin Hope
    Tom Feiner 如何按大小对 du -h 输出进行排序 2009-02-26 05:42:42 +0800 CST
  • Martin Hope
    Noah Goodrich 什么是 Pem 文件,它与其他 OpenSSL 生成的密钥文件格式有何不同? 2009-05-19 18:24:42 +0800 CST
  • Martin Hope
    Brent 如何确定bash变量是否为空? 2009-05-13 09:54:48 +0800 CST
  • Martin Hope
    cletus 您如何找到在 Windows 中打开文件的进程? 2009-05-01 16:47:16 +0800 CST

热门标签

linux nginx windows networking ubuntu domain-name-system amazon-web-services active-directory apache-2.4 ssh

Explore

  • 主页
  • 问题
    • 最新
    • 热门
  • 标签
  • 帮助

Footer

AskOverflow.Dev

关于我们

  • 关于我们
  • 联系我们

Legal Stuff

  • Privacy Policy

Language

  • Pt
  • Server
  • Unix

© 2023 AskOverflow.DEV All Rights Reserve