sisimai 5.0.2-java → 5.1.0-java
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 +35 -0
- data/.github/workflows/rake-test.yml +27 -24
- data/ChangeLog.md +62 -0
- data/Gemfile +2 -0
- data/README-JA.md +21 -18
- data/README.md +23 -20
- data/lib/sisimai/arf.rb +27 -8
- data/lib/sisimai/fact/json.rb +2 -2
- data/lib/sisimai/fact/yaml.rb +2 -2
- data/lib/sisimai/fact.rb +4 -19
- data/lib/sisimai/lhost/activehunter.rb +4 -3
- data/lib/sisimai/lhost/amavis.rb +4 -4
- data/lib/sisimai/lhost/amazonses.rb +6 -6
- data/lib/sisimai/lhost/amazonworkmail.rb +4 -4
- data/lib/sisimai/lhost/aol.rb +4 -4
- data/lib/sisimai/lhost/apachejames.rb +4 -4
- data/lib/sisimai/lhost/barracuda.rb +4 -4
- data/lib/sisimai/lhost/bigfoot.rb +4 -4
- data/lib/sisimai/lhost/biglobe.rb +4 -4
- data/lib/sisimai/lhost/courier.rb +4 -4
- data/lib/sisimai/lhost/domino.rb +4 -4
- data/lib/sisimai/lhost/dragonfly.rb +114 -0
- data/lib/sisimai/lhost/einsundeins.rb +4 -4
- data/lib/sisimai/lhost/exchange2003.rb +4 -3
- data/lib/sisimai/lhost/exchange2007.rb +4 -3
- data/lib/sisimai/lhost/exim.rb +4 -4
- data/lib/sisimai/lhost/ezweb.rb +4 -4
- data/lib/sisimai/lhost/facebook.rb +4 -4
- data/lib/sisimai/lhost/fml.rb +4 -4
- data/lib/sisimai/lhost/gmail.rb +4 -4
- data/lib/sisimai/lhost/gmx.rb +4 -4
- data/lib/sisimai/lhost/googlegroups.rb +4 -4
- data/lib/sisimai/lhost/gsuite.rb +4 -4
- data/lib/sisimai/lhost/imailserver.rb +4 -3
- data/lib/sisimai/lhost/interscanmss.rb +5 -4
- data/lib/sisimai/lhost/kddi.rb +4 -4
- data/lib/sisimai/lhost/mailfoundry.rb +4 -4
- data/lib/sisimai/lhost/mailmarshalsmtp.rb +6 -5
- data/lib/sisimai/lhost/mailru.rb +4 -4
- data/lib/sisimai/lhost/mcafee.rb +4 -4
- data/lib/sisimai/lhost/messagelabs.rb +4 -3
- data/lib/sisimai/lhost/messagingserver.rb +5 -4
- data/lib/sisimai/lhost/mfilter.rb +4 -4
- data/lib/sisimai/lhost/mxlogic.rb +3 -3
- data/lib/sisimai/lhost/notes.rb +4 -4
- data/lib/sisimai/lhost/office365.rb +4 -4
- data/lib/sisimai/lhost/opensmtpd.rb +9 -7
- data/lib/sisimai/lhost/outlook.rb +4 -4
- data/lib/sisimai/lhost/postfix.rb +4 -4
- data/lib/sisimai/lhost/powermta.rb +4 -4
- data/lib/sisimai/lhost/qmail.rb +10 -10
- data/lib/sisimai/lhost/receivingses.rb +4 -4
- data/lib/sisimai/lhost/sendgrid.rb +4 -4
- data/lib/sisimai/lhost/sendmail.rb +4 -4
- data/lib/sisimai/lhost/surfcontrol.rb +4 -4
- data/lib/sisimai/lhost/v5sendmail.rb +5 -4
- data/lib/sisimai/lhost/verizon.rb +4 -4
- data/lib/sisimai/lhost/x1.rb +3 -3
- data/lib/sisimai/lhost/x2.rb +3 -3
- data/lib/sisimai/lhost/x3.rb +3 -3
- data/lib/sisimai/lhost/x4.rb +3 -3
- data/lib/sisimai/lhost/x5.rb +3 -3
- data/lib/sisimai/lhost/x6.rb +3 -3
- data/lib/sisimai/lhost/yahoo.rb +4 -4
- data/lib/sisimai/lhost/yandex.rb +4 -4
- data/lib/sisimai/lhost/zoho.rb +4 -4
- data/lib/sisimai/lhost.rb +5 -5
- data/lib/sisimai/mail/maildir.rb +1 -1
- data/lib/sisimai/mail/stdin.rb +1 -1
- data/lib/sisimai/mda.rb +3 -3
- data/lib/sisimai/message.rb +9 -9
- data/lib/sisimai/order.rb +1 -0
- data/lib/sisimai/reason/badreputation.rb +1 -1
- data/lib/sisimai/reason/blocked.rb +1 -0
- data/lib/sisimai/reason/expired.rb +7 -0
- data/lib/sisimai/reason/filtered.rb +1 -0
- data/lib/sisimai/reason/mailboxfull.rb +3 -0
- data/lib/sisimai/reason/norelaying.rb +2 -0
- data/lib/sisimai/reason/rejected.rb +2 -1
- data/lib/sisimai/reason/suspend.rb +4 -0
- data/lib/sisimai/reason/userunknown.rb +4 -1
- data/lib/sisimai/reason.rb +8 -8
- data/lib/sisimai/rfc3464.rb +3 -3
- data/lib/sisimai/rfc3834.rb +2 -2
- data/lib/sisimai/rhost/apple.rb +92 -0
- data/lib/sisimai/rhost/cox.rb +81 -32
- data/lib/sisimai/rhost/franceptt.rb +84 -81
- data/lib/sisimai/rhost/godaddy.rb +205 -43
- data/lib/sisimai/rhost/google.rb +85 -72
- data/lib/sisimai/rhost/iua.rb +2 -2
- data/lib/sisimai/rhost/kddi.rb +6 -5
- data/lib/sisimai/rhost/microsoft.rb +12 -5
- data/lib/sisimai/rhost/mimecast.rb +15 -4
- data/lib/sisimai/rhost/nttdocomo.rb +4 -4
- data/lib/sisimai/rhost/spectrum.rb +100 -40
- data/lib/sisimai/rhost/tencent.rb +46 -25
- data/lib/sisimai/rhost/yahooinc.rb +110 -0
- data/lib/sisimai/rhost.rb +28 -35
- data/lib/sisimai/smtp/reply.rb +4 -3
- data/lib/sisimai/smtp/transcript.rb +3 -3
- data/lib/sisimai/version.rb +1 -1
- data/lib/sisimai.rb +0 -6
- data/set-of-emails/maildir/bsd/arf-26.eml +27 -0
- data/set-of-emails/maildir/bsd/lhost-dragonfly-01.eml +36 -0
- data/set-of-emails/maildir/bsd/lhost-dragonfly-02.eml +32 -0
- data/set-of-emails/maildir/bsd/lhost-dragonfly-03.eml +32 -0
- data/set-of-emails/maildir/bsd/lhost-dragonfly-04.eml +31 -0
- data/set-of-emails/maildir/bsd/lhost-dragonfly-05.eml +32 -0
- data/set-of-emails/maildir/bsd/lhost-dragonfly-06.eml +32 -0
- data/set-of-emails/maildir/bsd/lhost-dragonfly-07.eml +32 -0
- data/set-of-emails/maildir/bsd/lhost-dragonfly-08.eml +32 -0
- data/set-of-emails/maildir/bsd/lhost-dragonfly-09.eml +32 -0
- data/set-of-emails/maildir/bsd/lhost-dragonfly-10.eml +32 -0
- data/set-of-emails/maildir/bsd/lhost-dragonfly-11.eml +32 -0
- data/set-of-emails/maildir/bsd/lhost-dragonfly-12.eml +32 -0
- data/set-of-emails/maildir/bsd/lhost-dragonfly-13.eml +32 -0
- data/set-of-emails/maildir/bsd/lhost-dragonfly-14.eml +32 -0
- data/set-of-emails/maildir/bsd/lhost-dragonfly-15.eml +32 -0
- data/set-of-emails/maildir/bsd/lhost-dragonfly-16.eml +32 -0
- data/set-of-emails/maildir/bsd/lhost-dragonfly-17.eml +32 -0
- data/set-of-emails/maildir/bsd/lhost-dragonfly-18.eml +32 -0
- data/set-of-emails/maildir/bsd/lhost-dragonfly-19.eml +32 -0
- data/set-of-emails/maildir/bsd/lhost-dragonfly-20.eml +32 -0
- data/set-of-emails/maildir/bsd/lhost-dragonfly-21.eml +33 -0
- data/set-of-emails/maildir/bsd/lhost-dragonfly-22.eml +32 -0
- data/set-of-emails/maildir/bsd/lhost-dragonfly-23.eml +32 -0
- data/set-of-emails/maildir/bsd/lhost-dragonfly-24.eml +32 -0
- data/set-of-emails/maildir/bsd/lhost-dragonfly-25.eml +33 -0
- data/set-of-emails/maildir/bsd/lhost-dragonfly-26.eml +33 -0
- data/set-of-emails/maildir/bsd/lhost-dragonfly-27.eml +47 -0
- data/set-of-emails/maildir/bsd/lhost-dragonfly-28.eml +47 -0
- data/set-of-emails/maildir/bsd/lhost-dragonfly-29.eml +32 -0
- data/set-of-emails/maildir/bsd/lhost-dragonfly-30.eml +32 -0
- data/set-of-emails/maildir/bsd/lhost-opensmtpd-10.eml +58 -0
- data/set-of-emails/maildir/bsd/lhost-opensmtpd-11.eml +58 -0
- data/set-of-emails/maildir/bsd/lhost-opensmtpd-12.eml +62 -0
- data/set-of-emails/maildir/bsd/lhost-opensmtpd-13.eml +62 -0
- data/set-of-emails/maildir/bsd/lhost-opensmtpd-14.eml +58 -0
- data/set-of-emails/maildir/bsd/lhost-opensmtpd-15.eml +63 -0
- data/set-of-emails/maildir/bsd/lhost-opensmtpd-16.eml +62 -0
- data/set-of-emails/maildir/bsd/lhost-opensmtpd-17.eml +63 -0
- data/set-of-emails/maildir/bsd/lhost-qmail-11.eml +29 -0
- data/set-of-emails/maildir/bsd/lhost-qmail-12.eml +29 -0
- data/set-of-emails/maildir/bsd/lhost-qmail-13.eml +29 -0
- data/set-of-emails/maildir/bsd/lhost-qmail-14.eml +34 -0
- data/set-of-emails/maildir/bsd/lhost-qmail-15.eml +30 -0
- data/set-of-emails/maildir/bsd/lhost-qmail-16.eml +31 -0
- data/set-of-emails/maildir/bsd/lhost-qmail-17.eml +38 -0
- data/set-of-emails/maildir/bsd/lhost-qmail-18.eml +31 -0
- data/set-of-emails/maildir/bsd/lhost-qmail-19.eml +31 -0
- data/set-of-emails/maildir/bsd/lhost-qmail-20.eml +46 -0
- data/set-of-emails/maildir/bsd/lhost-qmail-21.eml +41 -0
- data/set-of-emails/maildir/bsd/lhost-qmail-22.eml +42 -0
- data/set-of-emails/maildir/bsd/lhost-qmail-23.eml +43 -0
- data/set-of-emails/maildir/bsd/lhost-qmail-24.eml +43 -0
- data/set-of-emails/maildir/bsd/lhost-qmail-25.eml +54 -0
- data/set-of-emails/maildir/bsd/rhost-apple-01.eml +79 -0
- data/set-of-emails/maildir/bsd/rhost-apple-02.eml +81 -0
- data/set-of-emails/maildir/bsd/rhost-apple-03.eml +75 -0
- data/set-of-emails/maildir/bsd/rhost-apple-04.eml +74 -0
- data/set-of-emails/maildir/bsd/rhost-microsoft-04.eml +86 -0
- data/set-of-emails/maildir/bsd/rhost-microsoft-05.eml +83 -0
- data/set-of-emails/maildir/bsd/rhost-yahooinc-01.eml +80 -0
- data/set-of-emails/maildir/bsd/rhost-yahooinc-02.eml +83 -0
- data/set-of-emails/maildir/bsd/rhost-yahooinc-03.eml +125 -0
- metadata +69 -3
- data/.travis.yml +0 -23
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
module Sisimai::Lhost
|
|
2
|
-
# Sisimai::Lhost::MailMarshalSMTP
|
|
3
|
-
# Gateway: formerly MailMarshal SMTP
|
|
2
|
+
# Sisimai::Lhost::MailMarshalSMTP decodes a bounce email which created by Trustwave Secure Email
|
|
3
|
+
# Gateway: formerly MailMarshal SMTP https://www.trustwave.com/en-us/services/email-security/.
|
|
4
|
+
# Methods in the module are called from only Sisimai::Message.
|
|
4
5
|
module MailMarshalSMTP
|
|
5
6
|
class << self
|
|
6
7
|
require 'sisimai/lhost'
|
|
@@ -13,11 +14,11 @@ module Sisimai::Lhost
|
|
|
13
14
|
rcpts: ['The following recipients were affected:'],
|
|
14
15
|
}.freeze
|
|
15
16
|
|
|
16
|
-
#
|
|
17
|
+
# @abstract Decodes the bounce message from Trustwave Secure Email Gateway (Formerly MailMarshalSMTP)
|
|
17
18
|
# @param [Hash] mhead Message headers of a bounce email
|
|
18
19
|
# @param [String] mbody Message body of a bounce email
|
|
19
20
|
# @return [Hash] Bounce data list and message/rfc822 part
|
|
20
|
-
# @return [Nil] it failed to
|
|
21
|
+
# @return [Nil] it failed to decode or the arguments are missing
|
|
21
22
|
def inquire(mhead, mbody)
|
|
22
23
|
return nil unless mhead['subject'].start_with?('Undeliverable Mail: "')
|
|
23
24
|
|
|
@@ -42,7 +43,7 @@ module Sisimai::Lhost
|
|
|
42
43
|
|
|
43
44
|
# Your message:
|
|
44
45
|
# From: originalsender@example.com
|
|
45
|
-
# Subject:
|
|
46
|
+
# Subject: ...
|
|
46
47
|
#
|
|
47
48
|
# Could not be delivered because of
|
|
48
49
|
#
|
data/lib/sisimai/lhost/mailru.rb
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
module Sisimai::Lhost
|
|
2
|
-
# Sisimai::Lhost::MailRu
|
|
3
|
-
# called from only Sisimai::Message.
|
|
2
|
+
# Sisimai::Lhost::MailRu decodes a bounce email which created by @mail.ru https://mail.ru/.
|
|
3
|
+
# Methods in the module are called from only Sisimai::Message.
|
|
4
4
|
module MailRu
|
|
5
5
|
class << self
|
|
6
6
|
# Based on Sisimai::Lhost::Exim
|
|
@@ -44,11 +44,11 @@ module Sisimai::Lhost
|
|
|
44
44
|
'contenterror' => ['Too many "Received" headers'],
|
|
45
45
|
}.freeze
|
|
46
46
|
|
|
47
|
-
#
|
|
47
|
+
# @abstract Decodes the bounce message from @mail.ru
|
|
48
48
|
# @param [Hash] mhead Message headers of a bounce email
|
|
49
49
|
# @param [String] mbody Message body of a bounce email
|
|
50
50
|
# @return [Hash] Bounce data list and message/rfc822 part
|
|
51
|
-
# @return [Nil] it failed to
|
|
51
|
+
# @return [Nil] it failed to decode or the arguments are missing
|
|
52
52
|
def inquire(mhead, mbody)
|
|
53
53
|
mfrom = mhead['from'].downcase
|
|
54
54
|
msgid = mhead['message-id'] ? mhead['message-id'].downcase : ''
|
data/lib/sisimai/lhost/mcafee.rb
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
module Sisimai::Lhost
|
|
2
|
-
# Sisimai::Lhost::McAfee
|
|
3
|
-
# the module are called from only Sisimai::Message.
|
|
2
|
+
# Sisimai::Lhost::McAfee decodes a bounce email which created by McAfee Email Appliance.
|
|
3
|
+
# Methods in the module are called from only Sisimai::Message.
|
|
4
4
|
module McAfee
|
|
5
5
|
class << self
|
|
6
6
|
require 'sisimai/lhost'
|
|
@@ -10,11 +10,11 @@ module Sisimai::Lhost
|
|
|
10
10
|
StartingOf = { message: ['--- The following addresses had delivery problems ---'] }.freeze
|
|
11
11
|
MessagesOf = { 'userunknown' => [' User not exist', ' unknown.', '550 Unknown user ', 'No such user'] }.freeze
|
|
12
12
|
|
|
13
|
-
#
|
|
13
|
+
# @abstract Decodes the bounce message from McAfee Email Appliance
|
|
14
14
|
# @param [Hash] mhead Message headers of a bounce email
|
|
15
15
|
# @param [String] mbody Message body of a bounce email
|
|
16
16
|
# @return [Hash] Bounce data list and message/rfc822 part
|
|
17
|
-
# @return [Nil] it failed to
|
|
17
|
+
# @return [Nil] it failed to decode or the arguments are missing
|
|
18
18
|
def inquire(mhead, mbody)
|
|
19
19
|
# X-NAI-Header: Modified by McAfee Email and Web Security Virtual Appliance
|
|
20
20
|
return nil unless mhead['x-nai-header']
|
|
@@ -1,5 +1,6 @@
|
|
|
1
1
|
module Sisimai::Lhost
|
|
2
|
-
# Sisimai::Lhost::MessageLabs
|
|
2
|
+
# Sisimai::Lhost::MessageLabs decodes a bounce email which created by Email Security (formerly MessageLab)
|
|
3
|
+
# https://www.broadcom.com/products/cybersecurity/emails.
|
|
3
4
|
# Methods in the module are called from only Sisimai::Message.
|
|
4
5
|
module MessageLabs
|
|
5
6
|
class << self
|
|
@@ -13,11 +14,11 @@ module Sisimai::Lhost
|
|
|
13
14
|
'securityerror' => ['Please turn on SMTP Authentication in your mail client'],
|
|
14
15
|
}.freeze
|
|
15
16
|
|
|
16
|
-
#
|
|
17
|
+
# @abstract Decodes the bounce message from Email Security (formerly Symantec.cloud (formerly MessageLabs))
|
|
17
18
|
# @param [Hash] mhead Message headers of a bounce email
|
|
18
19
|
# @param [String] mbody Message body of a bounce email
|
|
19
20
|
# @return [Hash] Bounce data list and message/rfc822 part
|
|
20
|
-
# @return [Nil] it failed to
|
|
21
|
+
# @return [Nil] it failed to decode or the arguments are missing
|
|
21
22
|
def inquire(mhead, mbody)
|
|
22
23
|
# X-Msg-Ref: server-11.tower-143.messagelabs.com!1419367175!36473369!1
|
|
23
24
|
# X-Originating-IP: [10.245.230.38]
|
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
module Sisimai::Lhost
|
|
2
|
-
# Sisimai::Lhost::MessagingServer
|
|
3
|
-
# Server and Sun Java System Messaging Server
|
|
2
|
+
# Sisimai::Lhost::MessagingServer decodes a bounce email which created by Oracle Communications
|
|
3
|
+
# Messaging Server and Sun Java System Messaging Server https://docs.oracle.com/en/industries/communications/messaging-server/index.html.
|
|
4
|
+
# Methods in the module are called from only Sisimai::Message.
|
|
4
5
|
module MessagingServer
|
|
5
6
|
class << self
|
|
6
7
|
require 'sisimai/lhost'
|
|
@@ -10,11 +11,11 @@ module Sisimai::Lhost
|
|
|
10
11
|
StartingOf = { message: ['This report relates to a message you sent with the following header fields:'] }.freeze
|
|
11
12
|
MessagesOf = { 'hostunknown' => ['Illegal host/domain name found'] }.freeze
|
|
12
13
|
|
|
13
|
-
#
|
|
14
|
+
# @abstract Decodes the bounce message from MessagingServer
|
|
14
15
|
# @param [Hash] mhead Message headers of a bounce email
|
|
15
16
|
# @param [String] mbody Message body of a bounce email
|
|
16
17
|
# @return [Hash] Bounce data list and message/rfc822 part
|
|
17
|
-
# @return [Nil] it failed to
|
|
18
|
+
# @return [Nil] it failed to decode or the arguments are missing
|
|
18
19
|
def inquire(mhead, mbody)
|
|
19
20
|
match = 0
|
|
20
21
|
match += 1 if mhead['content-type'].include?('Boundary_(ID_')
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
module Sisimai::Lhost
|
|
2
|
-
# Sisimai::Lhost::mFILTER
|
|
3
|
-
# the module are called from only Sisimai::Message.
|
|
2
|
+
# Sisimai::Lhost::mFILTER decodes a bounce email which created by Digital Arts m-FILTER https://www.daj.jp/bs/mf/.
|
|
3
|
+
# Methods in the module are called from only Sisimai::Message.
|
|
4
4
|
module MFILTER
|
|
5
5
|
class << self
|
|
6
6
|
require 'sisimai/lhost'
|
|
@@ -12,11 +12,11 @@ module Sisimai::Lhost
|
|
|
12
12
|
command: ['-------SMTP command'],
|
|
13
13
|
}.freeze
|
|
14
14
|
|
|
15
|
-
#
|
|
15
|
+
# @abstract Decodes the bounce message from Digital Arts m-FILTER
|
|
16
16
|
# @param [Hash] mhead Message headers of a bounce email
|
|
17
17
|
# @param [String] mbody Message body of a bounce email
|
|
18
18
|
# @return [Hash] Bounce data list and message/rfc822 part
|
|
19
|
-
# @return [Nil] it failed to
|
|
19
|
+
# @return [Nil] it failed to decode or the arguments are missing
|
|
20
20
|
def inquire(mhead, mbody)
|
|
21
21
|
# X-Mailer: m-FILTER
|
|
22
22
|
return nil unless mhead['x-mailer'].to_s == 'm-FILTER'
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
module Sisimai::Lhost
|
|
2
|
-
# Sisimai::Lhost::MXLogic
|
|
2
|
+
# Sisimai::Lhost::MXLogic decodes a bounce email which created by McAfee SaaS (formerly MXLogic).
|
|
3
3
|
# Methods in the module are called from only Sisimai::Message.
|
|
4
4
|
module MXLogic
|
|
5
5
|
class << self
|
|
@@ -67,11 +67,11 @@ module Sisimai::Lhost
|
|
|
67
67
|
'was frozen on arrival by ',
|
|
68
68
|
].freeze
|
|
69
69
|
|
|
70
|
-
#
|
|
70
|
+
# @abstract Decodes the bounce message from McAfee Saas (Formerly MXLogic)
|
|
71
71
|
# @param [Hash] mhead Message headers of a bounce email
|
|
72
72
|
# @param [String] mbody Message body of a bounce email
|
|
73
73
|
# @return [Hash] Bounce data list and message/rfc822 part
|
|
74
|
-
# @return [Nil] it failed to
|
|
74
|
+
# @return [Nil] it failed to decode or the arguments are missing
|
|
75
75
|
def inquire(mhead, mbody)
|
|
76
76
|
# X-MX-Bounce: mta/src/queue/bounce
|
|
77
77
|
# X-MXL-NoteHash: ffffffffffffffff-0000000000000000000000000000000000000000
|
data/lib/sisimai/lhost/notes.rb
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
module Sisimai::Lhost
|
|
2
|
-
# Sisimai::Lhost::Notes
|
|
3
|
-
# module are called from only Sisimai::Message.
|
|
2
|
+
# Sisimai::Lhost::Notes decodes a bounce email which created by HCL Notes (formerly IMB Notes Server
|
|
3
|
+
# (formerly Lotus Notes Server)). Methods in the module are called from only Sisimai::Message.
|
|
4
4
|
module Notes
|
|
5
5
|
class << self
|
|
6
6
|
require 'sisimai/lhost'
|
|
@@ -16,11 +16,11 @@ module Sisimai::Lhost
|
|
|
16
16
|
'networkerror' => ['Message has exceeded maximum hop count'],
|
|
17
17
|
}.freeze
|
|
18
18
|
|
|
19
|
-
#
|
|
19
|
+
# @abstract Decodes the bounce messages from HCL Notes (Formerly IBM Notes (Formerly Lotus Notes))
|
|
20
20
|
# @param [Hash] mhead Message headers of a bounce email
|
|
21
21
|
# @param [String] mbody Message body of a bounce email
|
|
22
22
|
# @return [Hash] Bounce data list and message/rfc822 part
|
|
23
|
-
# @return [Nil] it failed to
|
|
23
|
+
# @return [Nil] it failed to decode or the arguments are missing
|
|
24
24
|
def inquire(mhead, mbody)
|
|
25
25
|
return nil unless mhead['subject'].start_with?('Undeliverable message')
|
|
26
26
|
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
module Sisimai::Lhost
|
|
2
|
-
# Sisimai::Lhost::Office365
|
|
3
|
-
# the module are called from only Sisimai::Message.
|
|
2
|
+
# Sisimai::Lhost::Office365 decodes a bounce email which created by Microsoft 365 https://office.microsoft.com/'.
|
|
3
|
+
# Methods in the module are called from only Sisimai::Message.
|
|
4
4
|
module Office365
|
|
5
5
|
class << self
|
|
6
6
|
require 'sisimai/lhost'
|
|
@@ -89,11 +89,11 @@ module Sisimai::Lhost
|
|
|
89
89
|
RCPT: %r/unknown recipient or mailbox unavailable ->.+[<]?.+[@].+[.][a-zA-Z]+[>]?/,
|
|
90
90
|
}.freeze
|
|
91
91
|
|
|
92
|
-
#
|
|
92
|
+
# @abstract decodes the bounce message from Microsoft 365
|
|
93
93
|
# @param [Hash] mhead Message headers of a bounce email
|
|
94
94
|
# @param [String] mbody Message body of a bounce email
|
|
95
95
|
# @return [Hash] Bounce data list and message/rfc822 part
|
|
96
|
-
# @return [Nil] it failed to
|
|
96
|
+
# @return [Nil] it failed to decode or the arguments are missing
|
|
97
97
|
def inquire(mhead, mbody)
|
|
98
98
|
# X-MS-Exchange-Message-Is-Ndr:
|
|
99
99
|
# X-Microsoft-Antispam-PRVS: <....@...outlook.com>
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
module Sisimai::Lhost
|
|
2
|
-
# Sisimai::Lhost::OpenSMTPD
|
|
3
|
-
# are called from only Sisimai::Message.
|
|
2
|
+
# Sisimai::Lhost::OpenSMTPD decodes a bounce email which created by OpenSMTPD https://www.opensmtpd.org/.
|
|
3
|
+
# Methods in the module are called from only Sisimai::Message.
|
|
4
4
|
module OpenSMTPD
|
|
5
5
|
class << self
|
|
6
6
|
require 'sisimai/lhost'
|
|
@@ -45,7 +45,11 @@ module Sisimai::Lhost
|
|
|
45
45
|
'Domain does not exist',
|
|
46
46
|
],
|
|
47
47
|
# smtp/mta.c:1085| relay->failstr = "Destination seem to reject all mails";
|
|
48
|
-
'notaccept' => [
|
|
48
|
+
'notaccept' => [
|
|
49
|
+
'Destination seem to reject all mails',
|
|
50
|
+
'No MX found for domain',
|
|
51
|
+
'No MX found for destination',
|
|
52
|
+
],
|
|
49
53
|
# smtpd/mta.c:972| relay->failstr = "Temporary failure in MX lookup";
|
|
50
54
|
'networkerror' => [
|
|
51
55
|
'Address family mismatch on destination MXs',
|
|
@@ -54,8 +58,6 @@ module Sisimai::Lhost
|
|
|
54
58
|
'Could not retrieve source address',
|
|
55
59
|
'Loop detected',
|
|
56
60
|
'Network error on destination MXs',
|
|
57
|
-
'No MX found for domain',
|
|
58
|
-
'No MX found for destination',
|
|
59
61
|
'No valid route to remote MX',
|
|
60
62
|
'No valid route to destination',
|
|
61
63
|
'Temporary failure in MX lookup',
|
|
@@ -64,11 +66,11 @@ module Sisimai::Lhost
|
|
|
64
66
|
'securityerror' => ['Could not retrieve credentials'],
|
|
65
67
|
}.freeze
|
|
66
68
|
|
|
67
|
-
#
|
|
69
|
+
# @abstract Decodes the bounce message from OpenSMTPD
|
|
68
70
|
# @param [Hash] mhead Message headers of a bounce email
|
|
69
71
|
# @param [String] mbody Message body of a bounce email
|
|
70
72
|
# @return [Hash] Bounce data list and message/rfc822 part
|
|
71
|
-
# @return [Nil] it failed to
|
|
73
|
+
# @return [Nil] it failed to decode or the arguments are missing
|
|
72
74
|
def inquire(mhead, mbody)
|
|
73
75
|
return nil unless mhead['subject'].start_with?('Delivery status notification')
|
|
74
76
|
return nil unless mhead['from'].start_with?('Mailer Daemon <')
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
module Sisimai::Lhost
|
|
2
|
-
# Sisimai::Lhost::Outlook
|
|
3
|
-
# the module are called from only Sisimai::Message.
|
|
2
|
+
# Sisimai::Lhost::Outlook decode a bounce email which created by Microsoft outlook.com https://www.outlook.com/.
|
|
3
|
+
# Methods in the module are called from only Sisimai::Message.
|
|
4
4
|
module Outlook
|
|
5
5
|
class << self
|
|
6
6
|
require 'sisimai/lhost'
|
|
@@ -13,11 +13,11 @@ module Sisimai::Lhost
|
|
|
13
13
|
'userunknown' => ['Requested action not taken: mailbox unavailable'],
|
|
14
14
|
}.freeze
|
|
15
15
|
|
|
16
|
-
#
|
|
16
|
+
# @abstract Decodes the bounce message from Microsoft Outlook.com
|
|
17
17
|
# @param [Hash] mhead Message headers of a bounce email
|
|
18
18
|
# @param [String] mbody Message body of a bounce email
|
|
19
19
|
# @return [Hash] Bounce data list and message/rfc822 part
|
|
20
|
-
# @return [Nil] it failed to
|
|
20
|
+
# @return [Nil] it failed to decode or the arguments are missing
|
|
21
21
|
def inquire(mhead, mbody)
|
|
22
22
|
# X-Message-Delivery: Vj0xLjE7RD0wO0dEPTA7U0NMPTk7bD0xO3VzPTE=
|
|
23
23
|
# X-Message-Info: AuEzbeVr9u5fkDpn2vR5iCu5wb6HBeY4iruBjnutBzpStnUabbM...
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
module Sisimai::Lhost
|
|
2
|
-
# Sisimai::Lhost::Postfix
|
|
3
|
-
# called from only Sisimai::Message.
|
|
2
|
+
# Sisimai::Lhost::Postfix decodes a bounce email which created by Postfix https://www.postfix.org/.
|
|
3
|
+
# Methods in the module are called from only Sisimai::Message.
|
|
4
4
|
module Postfix
|
|
5
5
|
class << self
|
|
6
6
|
require 'sisimai/lhost'
|
|
@@ -20,11 +20,11 @@ module Sisimai::Lhost
|
|
|
20
20
|
],
|
|
21
21
|
}.freeze
|
|
22
22
|
|
|
23
|
-
#
|
|
23
|
+
# @abstract Decodes the bounce message from Postfix
|
|
24
24
|
# @param [Hash] mhead Message headers of a bounce email
|
|
25
25
|
# @param [String] mbody Message body of a bounce email
|
|
26
26
|
# @return [Hash] Bounce data list and message/rfc822 part
|
|
27
|
-
# @return [Nil] it failed to
|
|
27
|
+
# @return [Nil] it failed to decode or the arguments are missing
|
|
28
28
|
def inquire(mhead, mbody)
|
|
29
29
|
match = nil
|
|
30
30
|
sessx = nil
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
module Sisimai::Lhost
|
|
2
|
-
# Sisimai::Lhost::PowerMTA
|
|
3
|
-
# are called from only Sisimai::Message.
|
|
2
|
+
# Sisimai::Lhost::PowerMTA decodes a bounce email which created by PowerMTA https://bird.com/email/power-mta.
|
|
3
|
+
# Methods in the module are called from only Sisimai::Message.
|
|
4
4
|
module PowerMTA
|
|
5
5
|
class << self
|
|
6
6
|
require 'sisimai/lhost'
|
|
@@ -20,11 +20,11 @@ module Sisimai::Lhost
|
|
|
20
20
|
'spam-related' => 'spamdetected',
|
|
21
21
|
}.freeze
|
|
22
22
|
|
|
23
|
-
#
|
|
23
|
+
# @abstract Decodes the bounce message from PowerMTA
|
|
24
24
|
# @param [Hash] mhead Message headers of a bounce email
|
|
25
25
|
# @param [String] mbody Message body of a bounce email
|
|
26
26
|
# @return [Hash] Bounce data list and message/rfc822 part
|
|
27
|
-
# @return [Nil] it failed to
|
|
27
|
+
# @return [Nil] it failed to decode or the arguments are missing
|
|
28
28
|
# @since v4.25.6
|
|
29
29
|
def inquire(mhead, mbody)
|
|
30
30
|
return nil unless mhead['subject'].to_s.start_with?('Delivery report')
|
data/lib/sisimai/lhost/qmail.rb
CHANGED
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
module Sisimai::Lhost
|
|
2
|
-
# Sisimai::Lhost::Qmail
|
|
3
|
-
#
|
|
2
|
+
# Sisimai::Lhost::Qmail decodes a bounce email which created by qmail https://cr.yp.to/qmail.html
|
|
3
|
+
# or qmail clones or notqmail https://notqmail.org/.
|
|
4
|
+
# Methods in the module are called from only Sisimai::Message.
|
|
4
5
|
module Qmail
|
|
5
6
|
class << self
|
|
6
7
|
require 'sisimai/lhost'
|
|
@@ -79,18 +80,21 @@ module Sisimai::Lhost
|
|
|
79
80
|
'system error',
|
|
80
81
|
'Unable to',
|
|
81
82
|
],
|
|
83
|
+
'notaccept' => [
|
|
84
|
+
# notqmail 1.08 returns the following error message when the destination MX is NullMX
|
|
85
|
+
"Sorry, I couldn't find a mail exchanger or IP address",
|
|
86
|
+
],
|
|
82
87
|
'networkerror' => [
|
|
83
88
|
"Sorry, I wasn't able to establish an SMTP connection",
|
|
84
|
-
"Sorry, I couldn't find a mail exchanger or IP address",
|
|
85
89
|
"Sorry. Although I'm listed as a best-preference MX or A for that host",
|
|
86
90
|
],
|
|
87
91
|
}.freeze
|
|
88
92
|
|
|
89
|
-
#
|
|
93
|
+
# @abstract Decodes the bounce message from qmail
|
|
90
94
|
# @param [Hash] mhead Message headers of a bounce email
|
|
91
95
|
# @param [String] mbody Message body of a bounce email
|
|
92
96
|
# @return [Hash] Bounce data list and message/rfc822 part
|
|
93
|
-
# @return [Nil] it failed to
|
|
97
|
+
# @return [Nil] it failed to decode or the arguments are missing
|
|
94
98
|
def inquire(mhead, mbody)
|
|
95
99
|
# Pre process email headers and the body part of the message which generated
|
|
96
100
|
# by qmail, see https://cr.yp.to/qmail.html
|
|
@@ -181,11 +185,7 @@ module Sisimai::Lhost
|
|
|
181
185
|
end
|
|
182
186
|
|
|
183
187
|
# Detect the reason of bounce
|
|
184
|
-
if e['command']
|
|
185
|
-
# MAIL | Connected to 192.0.2.135 but sender was rejected.
|
|
186
|
-
e['reason'] = 'rejected'
|
|
187
|
-
|
|
188
|
-
elsif %w[HELO EHLO].index(e['command'])
|
|
188
|
+
if %w[HELO EHLO].index(e['command'])
|
|
189
189
|
# HELO | Connected to 192.0.2.135 but my name was rejected.
|
|
190
190
|
e['reason'] = 'blocked'
|
|
191
191
|
else
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
module Sisimai::Lhost
|
|
2
|
-
# Sisimai::Lhost::ReceivingSES
|
|
3
|
-
# Methods in the module are called from only Sisimai::Message.
|
|
2
|
+
# Sisimai::Lhost::ReceivingSES decodes a bounce email which created by Amazon Simple Email Service
|
|
3
|
+
# https://aws.amazon.com/ses. Methods in the module are called from only Sisimai::Message.
|
|
4
4
|
module ReceivingSES
|
|
5
5
|
class << self
|
|
6
6
|
require 'sisimai/lhost'
|
|
@@ -17,11 +17,11 @@ module Sisimai::Lhost
|
|
|
17
17
|
'contenterror' => ['Message content rejected'],
|
|
18
18
|
}.freeze
|
|
19
19
|
|
|
20
|
-
#
|
|
20
|
+
# @abstract Decodes the bounce message from Amazon SES/Receiving
|
|
21
21
|
# @param [Hash] mhead Message headers of a bounce email
|
|
22
22
|
# @param [String] mbody Message body of a bounce email
|
|
23
23
|
# @return [Hash] Bounce data list and message/rfc822 part
|
|
24
|
-
# @return [Nil] it failed to
|
|
24
|
+
# @return [Nil] it failed to decode or the arguments are missing
|
|
25
25
|
def inquire(mhead, mbody)
|
|
26
26
|
# X-SES-Outgoing: 2015.10.01-54.240.27.7
|
|
27
27
|
# Feedback-ID: 1.us-west-2.HX6/J9OVlHTadQhEu1+wdF9DBj6n6Pa9sW5Y/0pSOi8=:AmazonSES
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
module Sisimai::Lhost
|
|
2
|
-
# Sisimai::Lhost::SendGrid
|
|
3
|
-
# are called from only Sisimai::Message.
|
|
2
|
+
# Sisimai::Lhost::SendGrid decodes a bounce email which created by Twilio SendGrid https://sendgrid.com/.
|
|
3
|
+
# Methods in the module are called from only Sisimai::Message.
|
|
4
4
|
module SendGrid
|
|
5
5
|
class << self
|
|
6
6
|
require 'sisimai/lhost'
|
|
@@ -9,11 +9,11 @@ module Sisimai::Lhost
|
|
|
9
9
|
Boundaries = ['Content-Type: message/rfc822'].freeze
|
|
10
10
|
StartingOf = { message: ['This is an automatically generated message from SendGrid.'] }.freeze
|
|
11
11
|
|
|
12
|
-
#
|
|
12
|
+
# @abstract Decodes the bounce message from Twilio SendGrid
|
|
13
13
|
# @param [Hash] mhead Message headers of a bounce email
|
|
14
14
|
# @param [String] mbody Message body of a bounce email
|
|
15
15
|
# @return [Hash] Bounce data list and message/rfc822 part
|
|
16
|
-
# @return [Nil] it failed to
|
|
16
|
+
# @return [Nil] it failed to decode or the arguments are missing
|
|
17
17
|
def inquire(mhead, mbody)
|
|
18
18
|
# Return-Path: <apps@sendgrid.net>
|
|
19
19
|
# X-Mailer: MIME-tools 5.502 (Entity 5.502)
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
module Sisimai::Lhost
|
|
2
|
-
# Sisimai::Lhost::Sendmail
|
|
3
|
-
# are called from only Sisimai::Message.
|
|
2
|
+
# Sisimai::Lhost::Sendmail decodes a bounce email which created by Sendmail Open Source https://sendmail.org/.
|
|
3
|
+
# Methods in the module are called from only Sisimai::Message.
|
|
4
4
|
module Sendmail
|
|
5
5
|
class << self
|
|
6
6
|
require 'sisimai/lhost'
|
|
@@ -23,11 +23,11 @@ module Sisimai::Lhost
|
|
|
23
23
|
error: ['... while talking to '],
|
|
24
24
|
}.freeze
|
|
25
25
|
|
|
26
|
-
#
|
|
26
|
+
# @abstract Decodes the bounce message from Sendmail Open Source
|
|
27
27
|
# @param [Hash] mhead Message headers of a bounce email
|
|
28
28
|
# @param [String] mbody Message body of a bounce email
|
|
29
29
|
# @return [Hash] Bounce data list and message/rfc822 part
|
|
30
|
-
# @return [Nil] it failed to
|
|
30
|
+
# @return [Nil] it failed to decode or the arguments are missing
|
|
31
31
|
def inquire(mhead, mbody)
|
|
32
32
|
return nil if mhead['x-aol-ip']
|
|
33
33
|
match = nil
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
module Sisimai::Lhost
|
|
2
|
-
# Sisimai::Lhost::SurfControl
|
|
2
|
+
# Sisimai::Lhost::SurfControl decodes a bounce email which created by WebSense SurfControl.
|
|
3
3
|
# Methods in the module are called from only Sisimai::Message.
|
|
4
4
|
module SurfControl
|
|
5
5
|
class << self
|
|
@@ -9,11 +9,11 @@ module Sisimai::Lhost
|
|
|
9
9
|
Boundaries = ['Content-Type: message/rfc822'].freeze
|
|
10
10
|
StartingOf = { message: ['Your message could not be sent.'] }.freeze
|
|
11
11
|
|
|
12
|
-
#
|
|
12
|
+
# @abstract Decodes the bounce message from SurfControl
|
|
13
13
|
# @param [Hash] mhead Message headers of a bounce email
|
|
14
14
|
# @param [String] mbody Message body of a bounce email
|
|
15
15
|
# @return [Hash] Bounce data list and message/rfc822 part
|
|
16
|
-
# @return [Nil] it failed to
|
|
16
|
+
# @return [Nil] it failed to decode or the arguments are missing
|
|
17
17
|
def inquire(mhead, mbody)
|
|
18
18
|
# X-SEF-ZeroHour-RefID: fgs=000000000
|
|
19
19
|
# X-SEF-Processed: 0_0_0_000__2010_04_29_23_34_45
|
|
@@ -77,7 +77,7 @@ module Sisimai::Lhost
|
|
|
77
77
|
v['diagnosis'] = Sisimai::String.sweep(e[p2 + 2, e.size])
|
|
78
78
|
|
|
79
79
|
else
|
|
80
|
-
# Fallback,
|
|
80
|
+
# Fallback, Decode RFC3464 headers.
|
|
81
81
|
if f = Sisimai::RFC1894.match(e)
|
|
82
82
|
# "e" matched with any field defined in RFC3464
|
|
83
83
|
next unless o = Sisimai::RFC1894.field(e)
|
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
module Sisimai::Lhost
|
|
2
|
-
# Sisimai::Lhost::V5sendmail
|
|
3
|
-
#
|
|
2
|
+
# Sisimai::Lhost::V5sendmail decodes a bounce email which created by Sendmail version 5 or any
|
|
3
|
+
# email appliances based on Sendmail version 5.
|
|
4
|
+
# Methods in the module are called from only Sisimai::Message.
|
|
4
5
|
module V5sendmail
|
|
5
6
|
class << self
|
|
6
7
|
require 'sisimai/lhost'
|
|
@@ -28,11 +29,11 @@ module Sisimai::Lhost
|
|
|
28
29
|
message: ['----- Transcript of session follows -----'],
|
|
29
30
|
}.freeze
|
|
30
31
|
|
|
31
|
-
#
|
|
32
|
+
# @abstract Decodes the bounce message from Sendmail version 5
|
|
32
33
|
# @param [Hash] mhead Message headers of a bounce email
|
|
33
34
|
# @param [String] mbody Message body of a bounce email
|
|
34
35
|
# @return [Hash] Bounce data list and message/rfc822 part
|
|
35
|
-
# @return [Nil] it failed to
|
|
36
|
+
# @return [Nil] it failed to decode or the arguments are missing
|
|
36
37
|
def inquire(mhead, mbody)
|
|
37
38
|
# :from => %r/\AMail Delivery Subsystem/,
|
|
38
39
|
return nil unless mhead['subject'].start_with?('Returned mail: ')
|
|
@@ -1,16 +1,16 @@
|
|
|
1
1
|
module Sisimai::Lhost
|
|
2
|
-
# Sisimai::Lhost::Verizon
|
|
3
|
-
# module are called from only Sisimai::Message.
|
|
2
|
+
# Sisimai::Lhost::Verizon decodes a bounce email which created by Verizon https://www.verizon.com/.
|
|
3
|
+
# Methods in the module are called from only Sisimai::Message.
|
|
4
4
|
module Verizon
|
|
5
5
|
class << self
|
|
6
6
|
require 'sisimai/lhost'
|
|
7
7
|
Indicators = Sisimai::Lhost.INDICATORS
|
|
8
8
|
|
|
9
|
-
#
|
|
9
|
+
# @abstract Decodes the bounce message from Verizon
|
|
10
10
|
# @param [Hash] mhead Message headers of a bounce email
|
|
11
11
|
# @param [String] mbody Message body of a bounce email
|
|
12
12
|
# @return [Hash] Bounce data list and message/rfc822 part
|
|
13
|
-
# @return [Nil] it failed to
|
|
13
|
+
# @return [Nil] it failed to decode or the arguments are missing
|
|
14
14
|
def inquire(mhead, mbody)
|
|
15
15
|
match = -1
|
|
16
16
|
while true
|
data/lib/sisimai/lhost/x1.rb
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
module Sisimai::Lhost
|
|
2
|
-
# Sisimai::Lhost::X1
|
|
2
|
+
# Sisimai::Lhost::X1 decodes a bounce email which created by Unknown MTA #1. Methods in the module
|
|
3
3
|
# are called from only Sisimai::Message.
|
|
4
4
|
module X1
|
|
5
5
|
class << self
|
|
@@ -9,11 +9,11 @@ module Sisimai::Lhost
|
|
|
9
9
|
Boundaries = ['Received: from '].freeze
|
|
10
10
|
MarkingsOf = { message: ['The original message was received at '] }.freeze
|
|
11
11
|
|
|
12
|
-
#
|
|
12
|
+
# @abstract Decodes the bounce message from Unknown MTA #1
|
|
13
13
|
# @param [Hash] mhead Message headers of a bounce email
|
|
14
14
|
# @param [String] mbody Message body of a bounce email
|
|
15
15
|
# @return [Hash] Bounce data list and message/rfc822 part
|
|
16
|
-
# @return [Nil] it failed to
|
|
16
|
+
# @return [Nil] it failed to decode or the arguments are missing
|
|
17
17
|
def inquire(mhead, mbody)
|
|
18
18
|
return nil unless mhead['subject'].start_with?('Returned Mail: ')
|
|
19
19
|
return nil unless mhead['from'].start_with?('"Mail Deliver System" ')
|
data/lib/sisimai/lhost/x2.rb
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
module Sisimai::Lhost
|
|
2
|
-
# Sisimai::Lhost::X2
|
|
2
|
+
# Sisimai::Lhost::X2 decodes a bounce email which created by Unknown MTA #2. Methods in the module
|
|
3
3
|
# are called from only Sisimai::Message.
|
|
4
4
|
module X2
|
|
5
5
|
class << self
|
|
@@ -9,11 +9,11 @@ module Sisimai::Lhost
|
|
|
9
9
|
Boundaries = ['--- Original message follows.'].freeze
|
|
10
10
|
StartingOf = { message: ['Unable to deliver message to the following address'] }.freeze
|
|
11
11
|
|
|
12
|
-
#
|
|
12
|
+
# @abstract Decodes the bounce message from Unknown MTA #2
|
|
13
13
|
# @param [Hash] mhead Message headers of a bounce email
|
|
14
14
|
# @param [String] mbody Message body of a bounce email
|
|
15
15
|
# @return [Hash] Bounce data list and message/rfc822 part
|
|
16
|
-
# @return [Nil] it failed to
|
|
16
|
+
# @return [Nil] it failed to decode or the arguments are missing
|
|
17
17
|
def inquire(mhead, mbody)
|
|
18
18
|
match = nil
|
|
19
19
|
match ||= 1 if mhead['from'].include?('MAILER-DAEMON@')
|
data/lib/sisimai/lhost/x3.rb
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
module Sisimai::Lhost
|
|
2
|
-
# Sisimai::Lhost::X3
|
|
2
|
+
# Sisimai::Lhost::X3 decodes a bounce email which created by Unknown MTA #3. Methods in the module
|
|
3
3
|
# are called from only Sisimai::Message.
|
|
4
4
|
module X3
|
|
5
5
|
class << self
|
|
@@ -9,11 +9,11 @@ module Sisimai::Lhost
|
|
|
9
9
|
Boundaries = ['Content-Type: message/rfc822'].freeze
|
|
10
10
|
StartingOf = { message: [' This is an automatically generated Delivery Status Notification.'] }.freeze
|
|
11
11
|
|
|
12
|
-
#
|
|
12
|
+
# @abstract Decodes the bounce message from Unknown MTA #3
|
|
13
13
|
# @param [Hash] mhead Message headers of a bounce email
|
|
14
14
|
# @param [String] mbody Message body of a bounce email
|
|
15
15
|
# @return [Hash] Bounce data list and message/rfc822 part
|
|
16
|
-
# @return [Nil] it failed to
|
|
16
|
+
# @return [Nil] it failed to decode or the arguments are missing
|
|
17
17
|
def inquire(mhead, mbody)
|
|
18
18
|
return nil unless mhead['subject'].start_with?('Delivery status notification')
|
|
19
19
|
return nil unless mhead['from'].start_with?('Mail Delivery System')
|
data/lib/sisimai/lhost/x4.rb
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
module Sisimai::Lhost
|
|
2
|
-
# Sisimai::Lhost::X4
|
|
2
|
+
# Sisimai::Lhost::X4 decodes a bounce email which created by some qmail clone. Methods in the module
|
|
3
3
|
# are called from only Sisimai::Message.
|
|
4
4
|
module X4
|
|
5
5
|
class << self
|
|
@@ -122,11 +122,11 @@ module Sisimai::Lhost
|
|
|
122
122
|
],
|
|
123
123
|
}.freeze
|
|
124
124
|
|
|
125
|
-
#
|
|
125
|
+
# @abstract Decodes the bounce message from Unknown MTA #4
|
|
126
126
|
# @param [Hash] mhead Message headers of a bounce email
|
|
127
127
|
# @param [String] mbody Message body of a bounce email
|
|
128
128
|
# @return [Hash] Bounce data list and message/rfc822 part
|
|
129
|
-
# @return [Nil] it failed to
|
|
129
|
+
# @return [Nil] it failed to decode or the arguments are missing
|
|
130
130
|
def inquire(mhead, mbody)
|
|
131
131
|
# Pre process email headers and the body part of the message which generated by qmail, see
|
|
132
132
|
# https://cr.yp.to/qmail.html
|