sisimai 5.4.0 → 5.5.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +4 -4
- data/.github/workflows/codecovio.yml +1 -1
- data/.github/workflows/rake-test.yml +1 -1
- data/ChangeLog.md +45 -0
- data/Makefile +2 -4
- data/README-JA.md +23 -20
- data/README.md +23 -20
- data/lib/sisimai/address.rb +92 -44
- data/lib/sisimai/arf.rb +7 -8
- data/lib/sisimai/datetime.rb +2 -2
- data/lib/sisimai/fact/json.rb +1 -2
- data/lib/sisimai/fact/yaml.rb +1 -2
- data/lib/sisimai/fact.rb +60 -35
- data/lib/sisimai/lda.rb +2 -2
- data/lib/sisimai/lhost/activehunter.rb +4 -5
- data/lib/sisimai/lhost/amazonses.rb +3 -4
- data/lib/sisimai/lhost/apachejames.rb +2 -2
- data/lib/sisimai/lhost/biglobe.rb +6 -6
- data/lib/sisimai/lhost/courier.rb +7 -7
- data/lib/sisimai/lhost/domino.rb +6 -6
- data/lib/sisimai/lhost/dragonfly.rb +5 -5
- data/lib/sisimai/lhost/einsundeins.rb +4 -4
- data/lib/sisimai/lhost/exchange2003.rb +7 -7
- data/lib/sisimai/lhost/exchange2007.rb +3 -3
- data/lib/sisimai/lhost/exim.rb +7 -7
- data/lib/sisimai/lhost/ezweb.rb +3 -2
- data/lib/sisimai/lhost/fml.rb +9 -9
- data/lib/sisimai/lhost/gmail.rb +9 -9
- data/lib/sisimai/lhost/gmx.rb +3 -3
- data/lib/sisimai/lhost/googlegroups.rb +6 -7
- data/lib/sisimai/lhost/googleworkspace.rb +5 -6
- data/lib/sisimai/lhost/imailserver.rb +4 -4
- data/lib/sisimai/lhost/kddi.rb +4 -4
- data/lib/sisimai/lhost/mailfoundry.rb +3 -3
- data/lib/sisimai/lhost/{mailmarshalsmtp.rb → mailmarshal.rb} +5 -5
- data/lib/sisimai/lhost/messagingserver.rb +8 -8
- data/lib/sisimai/lhost/mfilter.rb +8 -4
- data/lib/sisimai/lhost/mimecast.rb +105 -0
- data/lib/sisimai/lhost/notes.rb +5 -5
- data/lib/sisimai/lhost/opensmtpd.rb +5 -5
- data/lib/sisimai/lhost/postfix.rb +38 -32
- data/lib/sisimai/lhost/qmail.rb +6 -6
- data/lib/sisimai/lhost/sendmail.rb +13 -13
- data/lib/sisimai/lhost/{interscanmss.rb → trendmicro.rb} +8 -9
- data/lib/sisimai/lhost/v5sendmail.rb +7 -7
- data/lib/sisimai/lhost/verizon.rb +3 -3
- data/lib/sisimai/lhost/x1.rb +7 -4
- data/lib/sisimai/lhost/x2.rb +40 -12
- data/lib/sisimai/lhost/x3.rb +3 -3
- data/lib/sisimai/lhost/x6.rb +2 -2
- data/lib/sisimai/lhost/zoho.rb +5 -5
- data/lib/sisimai/lhost.rb +18 -17
- data/lib/sisimai/mail/maildir.rb +4 -4
- data/lib/sisimai/mail/mbox.rb +4 -4
- data/lib/sisimai/mail/memory.rb +1 -1
- data/lib/sisimai/mail/stdin.rb +2 -2
- data/lib/sisimai/message.rb +34 -34
- data/lib/sisimai/order.rb +5 -4
- data/lib/sisimai/reason/authfailure.rb +1 -1
- data/lib/sisimai/reason/badreputation.rb +1 -1
- data/lib/sisimai/reason/blocked.rb +2 -1
- data/lib/sisimai/reason/contenterror.rb +1 -2
- data/lib/sisimai/reason/exceedlimit.rb +1 -1
- data/lib/sisimai/reason/expired.rb +1 -1
- data/lib/sisimai/reason/failedstarttls.rb +1 -1
- data/lib/sisimai/reason/filtered.rb +1 -1
- data/lib/sisimai/reason/hasmoved.rb +1 -1
- data/lib/sisimai/reason/hostunknown.rb +2 -2
- data/lib/sisimai/reason/mailboxfull.rb +1 -1
- data/lib/sisimai/reason/mailererror.rb +1 -1
- data/lib/sisimai/reason/mesgtoobig.rb +1 -1
- data/lib/sisimai/reason/networkerror.rb +1 -1
- data/lib/sisimai/reason/norelaying.rb +2 -2
- data/lib/sisimai/reason/notaccept.rb +2 -3
- data/lib/sisimai/reason/notcompliantrfc.rb +1 -1
- data/lib/sisimai/reason/policyviolation.rb +2 -4
- data/lib/sisimai/reason/rejected.rb +5 -3
- data/lib/sisimai/reason/requireptr.rb +1 -1
- data/lib/sisimai/reason/securityerror.rb +1 -1
- data/lib/sisimai/reason/spamdetected.rb +1 -1
- data/lib/sisimai/reason/speeding.rb +1 -1
- data/lib/sisimai/reason/suspend.rb +2 -1
- data/lib/sisimai/reason/systemerror.rb +1 -1
- data/lib/sisimai/reason/systemfull.rb +1 -1
- data/lib/sisimai/reason/toomanyconn.rb +1 -1
- data/lib/sisimai/reason/userunknown.rb +4 -3
- data/lib/sisimai/reason/vacation.rb +1 -1
- data/lib/sisimai/reason/virusdetected.rb +1 -1
- data/lib/sisimai/reason.rb +12 -12
- data/lib/sisimai/rfc1123.rb +58 -18
- data/lib/sisimai/rfc1894.rb +6 -8
- data/lib/sisimai/rfc2045.rb +25 -13
- data/lib/sisimai/rfc3464/thirdparty.rb +2 -3
- data/lib/sisimai/rfc3464.rb +6 -6
- data/lib/sisimai/rfc3834.rb +18 -8
- data/lib/sisimai/rfc5322.rb +9 -9
- data/lib/sisimai/rfc791.rb +2 -2
- data/lib/sisimai/rhost/aol.rb +4 -1
- data/lib/sisimai/rhost/apple.rb +11 -7
- data/lib/sisimai/rhost/cox.rb +9 -5
- data/lib/sisimai/rhost/facebook.rb +9 -3
- data/lib/sisimai/rhost/franceptt.rb +86 -37
- data/lib/sisimai/rhost/godaddy.rb +10 -1
- data/lib/sisimai/rhost/google.rb +26 -22
- data/lib/sisimai/rhost/gsuite.rb +1 -1
- data/lib/sisimai/rhost/kddi.rb +1 -1
- data/lib/sisimai/rhost/messagelabs.rb +160 -2
- data/lib/sisimai/rhost/microsoft.rb +80 -29
- data/lib/sisimai/rhost/mimecast.rb +30 -21
- data/lib/sisimai/rhost/nttdocomo.rb +69 -89
- data/lib/sisimai/rhost/outlook.rb +1 -1
- data/lib/sisimai/rhost/spectrum.rb +1 -1
- data/lib/sisimai/rhost/tencent.rb +5 -4
- data/lib/sisimai/rhost/yahooinc.rb +2 -2
- data/lib/sisimai/rhost/zoho.rb +72 -0
- data/lib/sisimai/rhost.rb +5 -4
- data/lib/sisimai/smtp/command.rb +2 -2
- data/lib/sisimai/smtp/reply.rb +11 -4
- data/lib/sisimai/smtp/status.rb +17 -8
- data/lib/sisimai/smtp/transcript.rb +3 -3
- data/lib/sisimai/string.rb +6 -10
- data/lib/sisimai/version.rb +1 -1
- data/lib/sisimai.rb +1 -1
- data/set-of-emails/maildir/bsd/lhost-exim-56.eml +40 -40
- data/set-of-emails/maildir/bsd/lhost-mfilter-05.eml +41 -0
- data/set-of-emails/maildir/bsd/lhost-mimecast-01.eml +46 -0
- data/set-of-emails/maildir/bsd/lhost-mimecast-02.eml +59 -0
- data/set-of-emails/maildir/bsd/lhost-postfix-79.eml +81 -0
- data/set-of-emails/maildir/bsd/lhost-postfix-80.eml +84 -0
- data/set-of-emails/maildir/bsd/lhost-x1-03.eml +26 -0
- data/set-of-emails/maildir/bsd/lhost-x1-04.eml +45 -0
- data/set-of-emails/maildir/bsd/lhost-x2-07.eml +30 -0
- data/set-of-emails/maildir/bsd/rfc3464-66.eml +170 -0
- data/set-of-emails/maildir/bsd/rfc3834-06.eml +59 -0
- data/set-of-emails/maildir/bsd/rhost-apple-05.eml +96 -0
- data/set-of-emails/maildir/bsd/rhost-zoho-01.eml +88 -0
- data/set-of-emails/maildir/bsd/rhost-zoho-02.eml +86 -0
- data/set-of-emails/maildir/bsd/rhost-zoho-03.eml +87 -0
- data/set-of-emails/maildir/bsd/rhost-zoho-04.eml +86 -0
- data/set-of-emails/maildir/not/rb-issue-368-bug.eml +39 -0
- data/sisimai-java.gemspec +1 -1
- data/sisimai.gemspec +1 -1
- metadata +27 -9
- /data/set-of-emails/maildir/bsd/{lhost-mailmarshalsmtp-02.eml → lhost-mailmarshal-02.eml} +0 -0
- /data/set-of-emails/maildir/bsd/{lhost-interscanmss-01.eml → lhost-trendmicro-01.eml} +0 -0
- /data/set-of-emails/maildir/bsd/{lhost-interscanmss-02.eml → lhost-trendmicro-02.eml} +0 -0
- /data/set-of-emails/maildir/bsd/{lhost-interscanmss-03.eml → lhost-trendmicro-03.eml} +0 -0
|
@@ -6,6 +6,12 @@ module Sisimai
|
|
|
6
6
|
module FrancePTT
|
|
7
7
|
class << self
|
|
8
8
|
ErrorCodes = {
|
|
9
|
+
# - Your sending IP is listed on Abusix RBL
|
|
10
|
+
# Please visit: https://lookup.abusix.com/search?q=$IP
|
|
11
|
+
"100" => 'blocked',
|
|
12
|
+
|
|
13
|
+
# - Your sending IP is listed by SpamHaus RBL
|
|
14
|
+
# Please visit: https://check.spamhaus.org/listed/?searchterm=$IP
|
|
9
15
|
# - 550 5.7.1 Service unavailable; client [192.0.2.1] blocked using Spamhaus
|
|
10
16
|
# Les emails envoyes vers la messagerie Laposte.net ont ete bloques par nos services.
|
|
11
17
|
# Afin de regulariser votre situation, nous vous invitons a cliquer sur le lien ci-dessous
|
|
@@ -15,6 +21,8 @@ module Sisimai
|
|
|
15
21
|
# https://www.spamhaus.org/lookup/ LPNAAA_101 (in reply to RCPT TO command))
|
|
16
22
|
'101' => 'blocked',
|
|
17
23
|
|
|
24
|
+
# - Your sending IP is listed by Cloudmark RBL
|
|
25
|
+
# Please visit: https://csi.cloudmark.com/reset-request/?ip=$IP#
|
|
18
26
|
# - 550 mwinf5c04 ME Adresse IP source bloquee pour incident de spam.
|
|
19
27
|
# - Client host blocked for spamming issues. OFR006_102 Ref http://csi.cloudmark.com ...
|
|
20
28
|
# - 550 5.5.0 Les emails envoyes vers la messagerie Laposte.net ont ete bloques par nos
|
|
@@ -25,6 +33,9 @@ module Sisimai
|
|
|
25
33
|
# https://senderscore.org/blacklistlookup/ LPN007_102
|
|
26
34
|
'102' => 'blocked',
|
|
27
35
|
|
|
36
|
+
# - Your sending IP has been blacklisted by Orange
|
|
37
|
+
# Please contact Orange by using our contact form and select option
|
|
38
|
+
# "Un problème d'envoi d'emails vers les adresses Orange ou Wanadoo (deliverability issue)"
|
|
28
39
|
# - 550 mwinf5c10 ME Service refuse. Veuillez essayer plus tard.
|
|
29
40
|
# - Service refused, please try later. OFR006_103 192.0.2.1 [103]
|
|
30
41
|
'103' => 'blocked',
|
|
@@ -34,31 +45,45 @@ module Sisimai
|
|
|
34
45
|
# - Too many connections, slow down. LPN105_104
|
|
35
46
|
'104' => 'toomanyconn',
|
|
36
47
|
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
'
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
#
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
#
|
|
53
|
-
|
|
54
|
-
|
|
48
|
+
# - Your IP address is missing a DNS PTR record, it also called a rDNS (reverse DNS)
|
|
49
|
+
# Please set up a valid DNS PTR record for your IP address that point to your domain,
|
|
50
|
+
# It's important that the sending IP address must match the IP address of the hostname
|
|
51
|
+
# defined in the PTR record
|
|
52
|
+
# - Service refused, please try later. LPN006_107
|
|
53
|
+
"107" => 'requireptr',
|
|
54
|
+
|
|
55
|
+
# - You are sending too many messages per SMTP connection
|
|
56
|
+
# Please reduce the number of messages per connection, recommended value is 100
|
|
57
|
+
# messages per connections
|
|
58
|
+
# - Veuillez essayer plus tard. LPN003_109
|
|
59
|
+
"109" => 'toomanyconn',
|
|
60
|
+
|
|
61
|
+
# - Invalid HELO/EHLO
|
|
62
|
+
# Please set up a valid HELO/EHLO, it must be fully qualified domain name (FQDN) and
|
|
63
|
+
# should resolve (DNS record needed). E.g.: "mail.yourdomain.com"
|
|
64
|
+
# - Veuillez essayer plus tard. OFR004_201
|
|
65
|
+
"201" => 'blocked',
|
|
66
|
+
"20X" => 'blocked',
|
|
67
|
+
|
|
68
|
+
# - Sender's Domain name SPF Error
|
|
69
|
+
# Please verify your mail from domain name DNS/TXT configuration for your SPF
|
|
70
|
+
# configuration. Please visit https://mxtoolbox.com/supertool3?action=spf:$YOUR_DOMAIN
|
|
71
|
+
# to check your domain. (replace $YOUR_DOMAIN by your sender domain name)
|
|
72
|
+
# Please note:
|
|
73
|
+
# If you have changed your DNS record recently, please let DNS caches expire (TTL)
|
|
74
|
+
"39X" => 'authfailure',
|
|
75
|
+
|
|
76
|
+
# - Sender's Domain DNS Error
|
|
77
|
+
# Please verify your mail from domain name DNS configuration. Your domain name must
|
|
78
|
+
# have valid A or MX records. You can check your DNS configuration on MxToolBox
|
|
79
|
+
# Please note:
|
|
80
|
+
# If you have changed your DNS record recently, please let DNS caches expire (TTL)
|
|
55
81
|
# - 5.0.1 Emetteur invalide. Invalid Sender. LPN105_405
|
|
56
82
|
# - 501 5.1.0 Emetteur invalide. Invalid Sender. OFR004_405 [405] (in reply to MAIL FROM command))
|
|
57
83
|
'405' => 'rejected',
|
|
58
84
|
|
|
59
|
-
#
|
|
60
|
-
|
|
61
|
-
|
|
85
|
+
# - User doesn't exist here
|
|
86
|
+
# Please remove this email address from your distribution list, it does not exist
|
|
62
87
|
# - 550 5.1.1 Adresse d au moins un destinataire invalide.
|
|
63
88
|
# - Invalid recipient. LPN416 (in reply to RCPT TO command)
|
|
64
89
|
# - Invalid recipient. OFR_416 [416] (in reply to RCPT TO command)
|
|
@@ -68,17 +93,15 @@ module Sisimai
|
|
|
68
93
|
# - Recipient overquota. OFR_417 [417] (in reply to RCPT TO command))
|
|
69
94
|
'417' => 'mailboxfull',
|
|
70
95
|
|
|
71
|
-
# - Adresse d au moins un destinataire invalide
|
|
72
|
-
|
|
73
96
|
# - 550 5.5.0 Boite du destinataire archivee.
|
|
74
97
|
# - Archived recipient. LPN007_420 (in reply to RCPT TO command)
|
|
75
98
|
'420' => 'suspend',
|
|
76
99
|
|
|
77
|
-
# -
|
|
78
|
-
|
|
79
|
-
|
|
80
|
-
|
|
81
|
-
|
|
100
|
+
# - Your sender domain name has been blacklisted
|
|
101
|
+
# Your sender domain name has been blacklisted by Abusix OR SpamHaus, Please visit:
|
|
102
|
+
# - https://lookup.abusix.com/search?q=$YOUR_DOMAIN
|
|
103
|
+
# - https://check.spamhaus.org/listed/?searchterm=$YOUR_DOMAIN
|
|
104
|
+
"425" => 'rejected',
|
|
82
105
|
|
|
83
106
|
# - 550 5.5.0 Le compte du destinataire est bloque. The recipient account isblocked.
|
|
84
107
|
# LPN007_426 (in reply to RCPT TO command)
|
|
@@ -90,6 +113,9 @@ module Sisimai
|
|
|
90
113
|
# LPN007_505 (in reply to end of DATA command)
|
|
91
114
|
'505' => 'systemerror',
|
|
92
115
|
|
|
116
|
+
# - Your message has been blocked by Orange, suspected spam
|
|
117
|
+
# Please contact Orange by using our contact form and select option
|
|
118
|
+
# "Un problème d'envoi d'emails vers les adresses Orange ou Wanadoo (deliverability issue)"
|
|
93
119
|
# - Mail rejete. Mail rejected. OFR_506 [506]
|
|
94
120
|
'506' => 'spamdetected',
|
|
95
121
|
|
|
@@ -97,21 +123,43 @@ module Sisimai
|
|
|
97
123
|
# LPN005_510 (in reply to end of DATA command)
|
|
98
124
|
'510' => 'blocked',
|
|
99
125
|
|
|
100
|
-
|
|
101
|
-
|
|
102
|
-
#
|
|
103
|
-
|
|
126
|
+
# - DMARC authentication failed, message rejected as defined by your DMARC policy
|
|
127
|
+
# Please check your SPF/DKIM/DMARC configuration. Please visit MxToolBox DMARC to
|
|
128
|
+
# check your domain configuration
|
|
129
|
+
"515" => 'authfailure',
|
|
104
130
|
|
|
105
131
|
# - 571 5.7.1 Message refused, DMARC verification Failed.
|
|
106
132
|
# - Message refuse, verification DMARC en echec LPN007_517
|
|
107
133
|
'517' => 'authfailure',
|
|
108
134
|
|
|
109
|
-
# -
|
|
110
|
-
'
|
|
135
|
+
# - The sending IP address is not authorized to send messages for your domain as defined
|
|
136
|
+
# in the sender's Domain name SPF configuration (DNS/TXT)
|
|
137
|
+
# Please verify your mail from domain name DNS/TXT configuration for your SPF configuration.
|
|
138
|
+
# Please visit https://mxtoolbox.com/supertool3?action=spf:$YOUR_DOMAIN to check your
|
|
139
|
+
# domain. (replace $YOUR_DOMAIN by your sender domain name)
|
|
140
|
+
"519" => 'authfailure',
|
|
111
141
|
|
|
142
|
+
# - Due to bad behavior you have been rate limited, please try again later
|
|
143
|
+
# Due to inappropriate behavior, you have been rate limited. Please check what you
|
|
144
|
+
# are trying to send
|
|
112
145
|
# - 421 mwinf5c77 ME Service refuse. Veuillez essayer plus tard. Service refused, please try
|
|
113
146
|
# later. OFR_999 [999]
|
|
114
|
-
|
|
147
|
+
"99X" => 'toomanyconn',
|
|
148
|
+
|
|
149
|
+
# Other undocumented or old error codes
|
|
150
|
+
"105" => "", # Veuillez essayer plus tard.
|
|
151
|
+
"108" => "", # service refused, please try later. LPN001_108
|
|
152
|
+
"305" => "securityerror", # 550 5.7.0 Code d'authentification invalide OFR_305
|
|
153
|
+
"401" => "authfailure", # 550 5.5.0 SPF: *** is not allowed to send mail. LPN004_401
|
|
154
|
+
"402" => "securityerror", # 550 5.5.0 Authentification requise. Authentication Required. LPN105_402
|
|
155
|
+
"403" => "rejected", # 5.0.1 Emetteur invalide. Invalid Sender.
|
|
156
|
+
"415" => "rejected", # Emetteur invalide. Invalid Sender. OFR_415
|
|
157
|
+
"421" => "rejected", # 5.5.3 Mail from not owned by user. LPN105_421.
|
|
158
|
+
"423" => "", # Service refused, please try later. LPN105_423
|
|
159
|
+
"424" => "", # Veuillez essayer plus tard. LPN105_424
|
|
160
|
+
"513" => "", # Mail rejete. Mail rejected. OUK_513
|
|
161
|
+
"514" => "messagetoobig", # Taille limite du message atteinte
|
|
162
|
+
"630" => "policyviolation", # 554 5.7.1 Client host rejected LPN000_630
|
|
115
163
|
}.freeze
|
|
116
164
|
MessagesOf = {
|
|
117
165
|
'authfailure' => [
|
|
@@ -135,14 +183,15 @@ module Sisimai
|
|
|
135
183
|
if cv = issuedcode.match(/\b(LPN|LPNAAA|OFR|OUK)(_[0-9]{3}|[0-9]{3}[-_][0-9]{3})\b/i)
|
|
136
184
|
# OUK_513, LPN105-104, OFR102-104, ofr_506
|
|
137
185
|
v = sprintf("%03d", (cv[1] + cv[2])[-3, 3])
|
|
138
|
-
|
|
186
|
+
x = v.clone; x[-1] = "X"
|
|
187
|
+
reasontext = ErrorCodes[v] || ErrorCodes[x] || ''
|
|
139
188
|
end
|
|
140
189
|
return reasontext if reasontext.size > 0
|
|
141
190
|
|
|
142
191
|
issuedcode = issuedcode.downcase
|
|
143
192
|
MessagesOf.each_key do |e|
|
|
144
193
|
MessagesOf[e].each do |f|
|
|
145
|
-
next
|
|
194
|
+
next if issuedcode.include?(f) == false
|
|
146
195
|
reasontext = e
|
|
147
196
|
break
|
|
148
197
|
end
|
|
@@ -188,6 +188,15 @@ module Sisimai
|
|
|
188
188
|
# other. They need to correct their forwarding settings.
|
|
189
189
|
'message is looping',
|
|
190
190
|
],
|
|
191
|
+
'toomanyconn' => [
|
|
192
|
+
# - 550 5.7.232 Your message can't be sent because your trial tenant has exceeded
|
|
193
|
+
# its daily limit for sending email to external recipients (tenant external
|
|
194
|
+
# recipient rate limit)
|
|
195
|
+
# - 550 5.7.233 - Your message can't be sent because your tenant exceeded its daily
|
|
196
|
+
# limit for sending email to external recipients (tenant external recipient rate
|
|
197
|
+
# limit)
|
|
198
|
+
"exceeded its daily limit",
|
|
199
|
+
],
|
|
191
200
|
'userunknown' => [
|
|
192
201
|
# - 550 Recipient not found
|
|
193
202
|
# - The recipient is not a valid email address.
|
|
@@ -218,7 +227,7 @@ module Sisimai
|
|
|
218
227
|
issuedcode = issuedcode.downcase
|
|
219
228
|
MessagesOf.each_key do |e|
|
|
220
229
|
MessagesOf[e].each do |f|
|
|
221
|
-
next
|
|
230
|
+
next if issuedcode.include?(f) == false
|
|
222
231
|
reasontext = e
|
|
223
232
|
break
|
|
224
233
|
end
|
data/lib/sisimai/rhost/google.rb
CHANGED
|
@@ -90,7 +90,11 @@ module Sisimai
|
|
|
90
90
|
# - 421 4.7.40 Your email has been rate limited because the sending domain doesn't
|
|
91
91
|
# have a DMARC record, or the DMARC record doesn’t specify a DMARC policy. Gmail
|
|
92
92
|
# requires all bulk email senders to add a DMARC record to their sending domain.
|
|
93
|
+
# - 550 5.7.40 Your message was blocked because the sending domain doesn't have a DMARC
|
|
94
|
+
# record or the DMARC record doesn't specify a DMARC policy. Gmail requires all bulk
|
|
95
|
+
# email senders to add a DMARC record to their sending domain.
|
|
93
96
|
["421", "4.7.40", "to add a dmarc record to "],
|
|
97
|
+
["550", "5.7.40", "to add a dmarc record to "],
|
|
94
98
|
],
|
|
95
99
|
'badreputation' => [
|
|
96
100
|
# - 421 4.7.0 This message is suspicious due to the very low reputation of the sending
|
|
@@ -363,19 +367,19 @@ module Sisimai
|
|
|
363
367
|
|
|
364
368
|
# - 535 5.7.1 Application-specific password required.
|
|
365
369
|
# For more information, visit https://support.google.com/accounts/answer/185833
|
|
366
|
-
['535', '5.7.1',
|
|
367
|
-
['535', '5.7.
|
|
370
|
+
['535', '5.7.1', 'application-specific password required'],
|
|
371
|
+
['535', '5.7.90', 'application-specific password required'],
|
|
368
372
|
|
|
369
373
|
# - 535 5.7.1 Please log in with your web browser and then try again. For more infor-
|
|
370
374
|
# mation, visit https://support.google.com/mail/bin/accounts/answer/78754
|
|
371
375
|
['535', '5.7.1', 'please log in with your web browser'],
|
|
372
|
-
['534', '5.7.
|
|
376
|
+
['534', '5.7.90', 'please log in with your web browser'],
|
|
373
377
|
['534', '5.7.14', 'please log in through your web browser'],
|
|
374
378
|
|
|
375
379
|
# - 535 5.7.1 Username and Password not accepted. For more information, visit
|
|
376
380
|
# https://support.google.com/accounts/troubleshooter/2402620
|
|
377
|
-
['535', '5.7.1',
|
|
378
|
-
['535', '5.7.
|
|
381
|
+
['535', '5.7.1', 'username and password not accepted'],
|
|
382
|
+
['535', '5.7.80', 'username and password not accepted'],
|
|
379
383
|
],
|
|
380
384
|
'spamdetected' => [
|
|
381
385
|
# - 421 4.7.0 This message is suspicious due to the nature of the content or the links
|
|
@@ -454,17 +458,17 @@ module Sisimai
|
|
|
454
458
|
# sequence. For more information, go to About SMTP error messages and review RFC 3030
|
|
455
459
|
# specifications.
|
|
456
460
|
# - https://support.google.com/a/answer/3221692
|
|
457
|
-
['502', '5.5.1',
|
|
458
|
-
['502', '5.5.1',
|
|
459
|
-
['502', '5.5.1',
|
|
460
|
-
['503', '5.5.1',
|
|
461
|
-
['503', '5.5.1',
|
|
462
|
-
['503', '5.5.1',
|
|
463
|
-
['503', '5.5.1',
|
|
464
|
-
['503', '5.5.1',
|
|
465
|
-
['504', '5.7.
|
|
466
|
-
['504', '5.7.
|
|
467
|
-
['554', '5.7.0',
|
|
461
|
+
['502', '5.5.1', 'too many unrecognized commands, goodbye'],
|
|
462
|
+
['502', '5.5.1', 'unimplemented command'],
|
|
463
|
+
['502', '5.5.1', 'unrecognized command'],
|
|
464
|
+
['503', '5.5.1', 'bad sequence of commands'],
|
|
465
|
+
['503', '5.5.1', 'ehlo/helo first'],
|
|
466
|
+
['503', '5.5.1', 'mail first'],
|
|
467
|
+
['503', '5.5.1', 'rcpt first'],
|
|
468
|
+
['503', '5.5.1', 'no data after bdat'],
|
|
469
|
+
['504', '5.7.40', 'unrecognized authentication type'],
|
|
470
|
+
['504', '5.7.40', 'xoauth is no longer supported'],
|
|
471
|
+
['554', '5.7.0', 'too many unauthenticated commands'],
|
|
468
472
|
],
|
|
469
473
|
'systemerror' => [
|
|
470
474
|
# About SMTP error messages, https://support.google.com/a/answer/3221692
|
|
@@ -523,8 +527,8 @@ module Sisimai
|
|
|
523
527
|
# @see https://support.google.com/a/answer/3726730?hl=en
|
|
524
528
|
def find(argvs)
|
|
525
529
|
return "" if argvs["diagnosticcode"].empty?
|
|
526
|
-
return ''
|
|
527
|
-
return ''
|
|
530
|
+
return '' if Sisimai::SMTP::Reply.test(argvs['replycode']) == false
|
|
531
|
+
return '' if Sisimai::SMTP::Status.test(argvs['deliverystatus']) == false
|
|
528
532
|
|
|
529
533
|
statuscode = argvs['deliverystatus'][2,6]
|
|
530
534
|
esmtpreply = argvs['replycode'][1,2]
|
|
@@ -535,13 +539,13 @@ module Sisimai
|
|
|
535
539
|
# Each key is a reason name
|
|
536
540
|
MessagesOf[e].each do |f|
|
|
537
541
|
# Try to match an SMTP reply code, a D.S.N, and an error message
|
|
538
|
-
next
|
|
539
|
-
next
|
|
540
|
-
next
|
|
542
|
+
next if issuedcode.include?(f[2]) == false
|
|
543
|
+
next if f[0].end_with?(esmtpreply) == false
|
|
544
|
+
next if f[1].end_with?(statuscode) == false
|
|
541
545
|
reasontext = e
|
|
542
546
|
break
|
|
543
547
|
end
|
|
544
|
-
break
|
|
548
|
+
break if reasontext.empty? == false
|
|
545
549
|
end
|
|
546
550
|
|
|
547
551
|
return reasontext
|
data/lib/sisimai/rhost/gsuite.rb
CHANGED
|
@@ -24,7 +24,7 @@ module Sisimai
|
|
|
24
24
|
|
|
25
25
|
MessagesOf.each_key do |e|
|
|
26
26
|
# Try to match the error message with message patterns defined in $MessagesOf
|
|
27
|
-
next
|
|
27
|
+
next if MessagesOf[e].none? { |a| argvs["diagnosticcode"].include?(a) }
|
|
28
28
|
next if e == "networkerror" && (statuscode == "5" || esmtpreply == "5")
|
|
29
29
|
next if e == "hostunknown" && (statuscode == "4" || statuscode == "")
|
|
30
30
|
next if e == "hostunknown" && (esmtpreply == "4" || esmtpreply == "")
|
data/lib/sisimai/rhost/kddi.rb
CHANGED
|
@@ -21,7 +21,7 @@ module Sisimai
|
|
|
21
21
|
|
|
22
22
|
MessagesOf.each_key do |e|
|
|
23
23
|
# Try to match the error message with message patterns defined in $MessagesOf
|
|
24
|
-
next
|
|
24
|
+
next if issuedcode.include?(MessagesOf[e]) == false
|
|
25
25
|
reasontext = e
|
|
26
26
|
break
|
|
27
27
|
end
|
|
@@ -6,8 +6,166 @@ module Sisimai
|
|
|
6
6
|
module MessageLabs
|
|
7
7
|
class << self
|
|
8
8
|
MessagesOf = {
|
|
9
|
+
"authfailure" => [
|
|
10
|
+
# - 553 DMARC domain authentication fail
|
|
11
|
+
# - https://knowledge.broadcom.com/external/article/175407
|
|
12
|
+
# An email has failed delivery and the reason provided in Track and Trace is due
|
|
13
|
+
# to SPF Record. 553-SPF (Sender Policy Framework) domain authentication fail.
|
|
14
|
+
"domain authentication fail",
|
|
15
|
+
],
|
|
16
|
+
"badreputation" => [
|
|
17
|
+
# - https://knowledge.broadcom.com/external/article/164955
|
|
18
|
+
# "501 Connection rejected by policy [7.7]" 20805, please visit www.messagelabs.com/support
|
|
19
|
+
# for more details about this error message.
|
|
20
|
+
# My IP has a negative reputation with Symantec. To check the reputation of a
|
|
21
|
+
# specific IP address, go to https://ipremoval.sms.symantec.com/.
|
|
22
|
+
# - https://knowledge.broadcom.com/external/article/384503
|
|
23
|
+
# Users are receiving a non-delivery receipt (NDR) when sending an email to a
|
|
24
|
+
# Symantec Email Security.cloud customer:
|
|
25
|
+
"Connection rejected by policy",
|
|
26
|
+
],
|
|
27
|
+
"blocked" => [
|
|
28
|
+
# - https://knowledge.broadcom.com/external/article/165165
|
|
29
|
+
# You are sending an email to a domain protected by the Symantec Email Security.Cloud
|
|
30
|
+
# service and are receiving a non delivery receipt (NDR) stating the email delivery failed.
|
|
31
|
+
# 553-mail rejected because your IP is in the PBL. See http://www.spamhaus.org/pbl
|
|
32
|
+
# - Sorry, your IP address has been blocked
|
|
33
|
+
# * This error message indicates that your public IP address has been put on a
|
|
34
|
+
# block list by the Spamhaus PBL block list. To resolve this issue, request to
|
|
35
|
+
# have your IP removed at http://www.spamhaus.org/pbl/.
|
|
36
|
+
# * The delisting process is normally quicker than an hour. Once an hour has passed
|
|
37
|
+
# try to resend your email.
|
|
38
|
+
# * If the problem persists, contact the recipient by other means (e.g. phone)
|
|
39
|
+
# and request that your email address is added to their Email Security.cloud
|
|
40
|
+
# approved sender's list.
|
|
41
|
+
# - Sorry, your email address (addr) has been blocked
|
|
42
|
+
# * Check with your administrator or ISP that your mail server is not in open relay.
|
|
43
|
+
# Search “Open Relay Test” for an independent testing tool. If your mail server
|
|
44
|
+
# is an open relay, please fix the open relay, wait 24 hours, and then try to
|
|
45
|
+
# resend your email.
|
|
46
|
+
# * Check with your administrator or ISP that your IP address is not on any spam
|
|
47
|
+
# block lists. Search “email blacklist check” to check using an independent tool.
|
|
48
|
+
# If your IP address is on any block lists, please request for removal, wait 24
|
|
49
|
+
# hours, and then try to resend your email.
|
|
50
|
+
# If the problem persists, contact the recipient by other means (e.g. phone) for
|
|
51
|
+
# further assistance.
|
|
52
|
+
# - Sorry, your IP address (ip-addr) has been blocked
|
|
53
|
+
"mail rejected because your IP is in the PBL",
|
|
54
|
+
"your IP address has been ",
|
|
55
|
+
"your IP address (ip-addr) has been blocked",
|
|
56
|
+
"your email address (addr) has been blocked",
|
|
57
|
+
],
|
|
58
|
+
"contenterror" => [
|
|
59
|
+
# - 553 Stray linefeeds in message (#5.6.2)
|
|
60
|
+
# This error message happens because we strictly enforce the Internet Message Format
|
|
61
|
+
# standard RFC 5322 (and its predecessor RFC 2822) which state, "CR and LF MUST
|
|
62
|
+
# only occur together as CRLF; they MUST NOT appear independently in the body.
|
|
63
|
+
"Stray linefeeds in message",
|
|
64
|
+
],
|
|
65
|
+
"failedstarttls" => [
|
|
66
|
+
# - https://knowledge.broadcom.com/external/article/162152
|
|
67
|
+
# You are sending to a domain protected by the Symantec Email Security.cloud
|
|
68
|
+
# service, or you are a customer subscribed to Symantec Email Security.cloud
|
|
69
|
+
# sending outbound through the service. The Email Security.cloud server responds
|
|
70
|
+
# to the SMTP RCPT TO: command with "451 TLS/SSLv3 Connection required. (#4.7.1)".
|
|
71
|
+
# - 451 TLS/SSLv3 Connection required. (#4.7.1)
|
|
72
|
+
# - Within the ClientNet portal, the Email Track and Trace tool shows "Not Delivered"
|
|
73
|
+
# in the Delivered column and "Boundary Encryption" in the "Service" column.
|
|
74
|
+
"TLS/SSLv3 Connection required",
|
|
75
|
+
],
|
|
76
|
+
"norelaying" => [
|
|
77
|
+
# - https://knowledge.broadcom.com/external/article/162137
|
|
78
|
+
# You received a Non-Delivery Report (NDR) for email sent through the Symantec
|
|
79
|
+
# Email Security.cloud infrastructure, with the message "You are trying to use
|
|
80
|
+
# me [server-X.tower-x.messagelabs.com] as a relay, but I have not been configured
|
|
81
|
+
# to let you [IP, address] do this."
|
|
82
|
+
" as a relay, ",
|
|
83
|
+
],
|
|
84
|
+
"notcompliantrfc" => [
|
|
85
|
+
# - The format of your message did not comply with RFC 2822.
|
|
86
|
+
# - Contact your IT administrator or ISP.
|
|
87
|
+
# - If the problem persists, contact the recipient by other means (e.g. phone).
|
|
88
|
+
#
|
|
89
|
+
# - 550 [XX.XX.XX.XX] has detected that this message is not RFC 5322
|
|
90
|
+
# * Ensure that the message complied to RFC 5322.
|
|
91
|
+
"550 Requested action aborted [4]",
|
|
92
|
+
"has detected that this message is not RFC 5322",
|
|
93
|
+
],
|
|
94
|
+
"rejected" => [
|
|
95
|
+
# - 550 sender envelope domain not allowed for sender IP address (#5.1.8)
|
|
96
|
+
# This error occurs when a sender attempts to send an email and any one of the
|
|
97
|
+
# following are true:
|
|
98
|
+
# * The sending domain has not been registered under My Domains or Third-Party Domains.
|
|
99
|
+
# * The sending domain is inactive.
|
|
100
|
+
# * The sending IP is not in Outbound Routes.
|
|
101
|
+
# - 553 Sorry, your domain has been blocked
|
|
102
|
+
# The error message indicates that your IP address is on the recipient’s private
|
|
103
|
+
# block list. Contact the recipient and request that your email address is added
|
|
104
|
+
# to their Email Security.cloud approved sender's list.
|
|
105
|
+
# - 553 Sorry, your email address has been blocked
|
|
106
|
+
# The error message indicates that your domain is on the recipient’s private block
|
|
107
|
+
# list. Contact the recipient by other means (e.g. phone) and request that your
|
|
108
|
+
# email address is added to their Email Security.cloud approved senders list.
|
|
109
|
+
# - https://knowledge.broadcom.com/external/article/162232
|
|
110
|
+
# You have received an email notification from Symantec Email Security.cloud:
|
|
111
|
+
# * An individual end user account is either sending spam through Symantec Email
|
|
112
|
+
# Security.cloud or is receiving a bounceback error message indicating they are
|
|
113
|
+
# on the "badmailfrom" list.
|
|
114
|
+
# * The error message received is: "553 sorry, your envelope sender is in my
|
|
115
|
+
# badmailfrom list. Please visit www.symanteccloud.com/troubleshooting for more
|
|
116
|
+
# details about this error message and instructions to resolve this issue. (#5.7.1)."
|
|
117
|
+
# - https://knowledge.broadcom.com/external/article/173082
|
|
118
|
+
# Emails from a sender are blocked by the Anti-Spam service stating that they are
|
|
119
|
+
# in your company's blacklist.
|
|
120
|
+
# * 553-Sorry, your email address has been blacklisted
|
|
121
|
+
# * 553-Sorry, your domain has been blacklisted
|
|
122
|
+
# * 553-Sorry, your IP address has been blacklisted
|
|
123
|
+
"sender envelope domain not allowed for sender IP address",
|
|
124
|
+
"your domain has been blocked",
|
|
125
|
+
"your email address has been blocked",
|
|
126
|
+
"your envelope sender is in my badmailfrom list",
|
|
127
|
+
"your email address has been blacklisted",
|
|
128
|
+
"your domain has been blacklisted",
|
|
129
|
+
],
|
|
9
130
|
"securityerror" => ["Please turn on SMTP Authentication in your mail client"],
|
|
10
|
-
"
|
|
131
|
+
"spamdetected" => [
|
|
132
|
+
# - https://knowledge.broadcom.com/external/article/173867
|
|
133
|
+
# Legitimate email, either outbound or inbound, is incorrectly flagged as spam
|
|
134
|
+
# (false positive) by Email Security.cloud. This email may have the following errors:
|
|
135
|
+
# * 553 - Message Filtered
|
|
136
|
+
# * filtered by Outbound scanning.
|
|
137
|
+
"Message Filtered",
|
|
138
|
+
"filtered by Outbound scanning",
|
|
139
|
+
],
|
|
140
|
+
"toomanyconn" => [
|
|
141
|
+
# - https://knowledge.broadcom.com/external/article/385809
|
|
142
|
+
# Email Security Cloud is attempting to deliver the email and recipient MTA is
|
|
143
|
+
# responding "452 Too many recipients received this hour".
|
|
144
|
+
# - https://knowledge.broadcom.com/external/article/164767
|
|
145
|
+
# This error can occur when sending outbound or inbound emails through Email
|
|
146
|
+
# Security.Cloud. A non-delivery receipt (NDR) stating delivery contains a message
|
|
147
|
+
# that the intended recipient has failed with error:
|
|
148
|
+
# "460 too many messages (#4.3.0)"
|
|
149
|
+
"Too many recipients received this hour",
|
|
150
|
+
"too many messages",
|
|
151
|
+
],
|
|
152
|
+
"userunknown" => [
|
|
153
|
+
# - https://knowledge.broadcom.com/external/article/165163
|
|
154
|
+
# When sending email to a user on the Symantec Email Security.cloud service, the
|
|
155
|
+
# message is rejected. The sender receives a non-delivery email with a 500 series
|
|
156
|
+
# error code indicating that the recipient is invalid.
|
|
157
|
+
# <username@example.com>: 550-Invalid recipient <username@example.com> 550 (#5.1.1)
|
|
158
|
+
# - 553 Recipient mailbox is not allowed
|
|
159
|
+
# The error message indicates that you have sent an email to an invalid address
|
|
160
|
+
# in the recipient’s domain. Double-check the email address for any spelling errors.
|
|
161
|
+
# - https://knowledge.broadcom.com/external/article/175710
|
|
162
|
+
# This error indicates that you have sent an email to an invalid address to the
|
|
163
|
+
# recipient’s domain. "Recipient mailbox is not allowed"
|
|
164
|
+
"No such user",
|
|
165
|
+
"Invalid recipient",
|
|
166
|
+
"mailbox is not allowed",
|
|
167
|
+
"Recipient mailbox is not allowed",
|
|
168
|
+
],
|
|
11
169
|
}.freeze
|
|
12
170
|
|
|
13
171
|
# Detect bounce reason from Email Security (formerly MessageLabs.com)
|
|
@@ -22,7 +180,7 @@ module Sisimai
|
|
|
22
180
|
|
|
23
181
|
MessagesOf.each_key do |e|
|
|
24
182
|
# Try to match the error message with message patterns defined in $MessagesOf
|
|
25
|
-
next
|
|
183
|
+
next if MessagesOf[e].none? { |a| issuedcode.include?(a) }
|
|
26
184
|
reasontext = e
|
|
27
185
|
break
|
|
28
186
|
end
|