otherinbox-mail 2.4.4

Sign up to get free protection for your applications and to get access to all the features.
Files changed (141) hide show
  1. data/CHANGELOG.rdoc +607 -0
  2. data/CONTRIBUTING.md +45 -0
  3. data/Dependencies.txt +3 -0
  4. data/Gemfile +26 -0
  5. data/Gemfile.lock +44 -0
  6. data/README.md +663 -0
  7. data/Rakefile +40 -0
  8. data/TODO.rdoc +9 -0
  9. data/lib/VERSION +4 -0
  10. data/lib/mail.rb +101 -0
  11. data/lib/mail/attachments_list.rb +104 -0
  12. data/lib/mail/body.rb +291 -0
  13. data/lib/mail/configuration.rb +75 -0
  14. data/lib/mail/core_extensions/nil.rb +17 -0
  15. data/lib/mail/core_extensions/object.rb +13 -0
  16. data/lib/mail/core_extensions/shell_escape.rb +56 -0
  17. data/lib/mail/core_extensions/smtp.rb +25 -0
  18. data/lib/mail/core_extensions/string.rb +33 -0
  19. data/lib/mail/core_extensions/string/access.rb +145 -0
  20. data/lib/mail/core_extensions/string/multibyte.rb +78 -0
  21. data/lib/mail/elements.rb +14 -0
  22. data/lib/mail/elements/address.rb +306 -0
  23. data/lib/mail/elements/address_list.rb +74 -0
  24. data/lib/mail/elements/content_disposition_element.rb +30 -0
  25. data/lib/mail/elements/content_location_element.rb +25 -0
  26. data/lib/mail/elements/content_transfer_encoding_element.rb +24 -0
  27. data/lib/mail/elements/content_type_element.rb +35 -0
  28. data/lib/mail/elements/date_time_element.rb +26 -0
  29. data/lib/mail/elements/envelope_from_element.rb +34 -0
  30. data/lib/mail/elements/message_ids_element.rb +29 -0
  31. data/lib/mail/elements/mime_version_element.rb +26 -0
  32. data/lib/mail/elements/phrase_list.rb +21 -0
  33. data/lib/mail/elements/received_element.rb +30 -0
  34. data/lib/mail/encodings.rb +274 -0
  35. data/lib/mail/encodings/7bit.rb +31 -0
  36. data/lib/mail/encodings/8bit.rb +31 -0
  37. data/lib/mail/encodings/base64.rb +33 -0
  38. data/lib/mail/encodings/binary.rb +31 -0
  39. data/lib/mail/encodings/quoted_printable.rb +38 -0
  40. data/lib/mail/encodings/transfer_encoding.rb +58 -0
  41. data/lib/mail/envelope.rb +35 -0
  42. data/lib/mail/field.rb +234 -0
  43. data/lib/mail/field_list.rb +33 -0
  44. data/lib/mail/fields.rb +35 -0
  45. data/lib/mail/fields/bcc_field.rb +56 -0
  46. data/lib/mail/fields/cc_field.rb +55 -0
  47. data/lib/mail/fields/comments_field.rb +41 -0
  48. data/lib/mail/fields/common/address_container.rb +16 -0
  49. data/lib/mail/fields/common/common_address.rb +125 -0
  50. data/lib/mail/fields/common/common_date.rb +42 -0
  51. data/lib/mail/fields/common/common_field.rb +51 -0
  52. data/lib/mail/fields/common/common_message_id.rb +44 -0
  53. data/lib/mail/fields/common/parameter_hash.rb +58 -0
  54. data/lib/mail/fields/content_description_field.rb +19 -0
  55. data/lib/mail/fields/content_disposition_field.rb +69 -0
  56. data/lib/mail/fields/content_id_field.rb +63 -0
  57. data/lib/mail/fields/content_location_field.rb +42 -0
  58. data/lib/mail/fields/content_transfer_encoding_field.rb +50 -0
  59. data/lib/mail/fields/content_type_field.rb +198 -0
  60. data/lib/mail/fields/date_field.rb +57 -0
  61. data/lib/mail/fields/from_field.rb +55 -0
  62. data/lib/mail/fields/in_reply_to_field.rb +55 -0
  63. data/lib/mail/fields/keywords_field.rb +44 -0
  64. data/lib/mail/fields/message_id_field.rb +83 -0
  65. data/lib/mail/fields/mime_version_field.rb +53 -0
  66. data/lib/mail/fields/optional_field.rb +13 -0
  67. data/lib/mail/fields/received_field.rb +75 -0
  68. data/lib/mail/fields/references_field.rb +55 -0
  69. data/lib/mail/fields/reply_to_field.rb +55 -0
  70. data/lib/mail/fields/resent_bcc_field.rb +55 -0
  71. data/lib/mail/fields/resent_cc_field.rb +55 -0
  72. data/lib/mail/fields/resent_date_field.rb +35 -0
  73. data/lib/mail/fields/resent_from_field.rb +55 -0
  74. data/lib/mail/fields/resent_message_id_field.rb +34 -0
  75. data/lib/mail/fields/resent_sender_field.rb +62 -0
  76. data/lib/mail/fields/resent_to_field.rb +55 -0
  77. data/lib/mail/fields/return_path_field.rb +65 -0
  78. data/lib/mail/fields/sender_field.rb +67 -0
  79. data/lib/mail/fields/structured_field.rb +51 -0
  80. data/lib/mail/fields/subject_field.rb +16 -0
  81. data/lib/mail/fields/to_field.rb +55 -0
  82. data/lib/mail/fields/unstructured_field.rb +191 -0
  83. data/lib/mail/header.rb +265 -0
  84. data/lib/mail/indifferent_hash.rb +146 -0
  85. data/lib/mail/mail.rb +255 -0
  86. data/lib/mail/matchers/has_sent_mail.rb +124 -0
  87. data/lib/mail/message.rb +2059 -0
  88. data/lib/mail/multibyte.rb +42 -0
  89. data/lib/mail/multibyte/chars.rb +474 -0
  90. data/lib/mail/multibyte/exceptions.rb +8 -0
  91. data/lib/mail/multibyte/unicode.rb +392 -0
  92. data/lib/mail/multibyte/utils.rb +60 -0
  93. data/lib/mail/network.rb +14 -0
  94. data/lib/mail/network/delivery_methods/exim.rb +53 -0
  95. data/lib/mail/network/delivery_methods/file_delivery.rb +40 -0
  96. data/lib/mail/network/delivery_methods/sendmail.rb +62 -0
  97. data/lib/mail/network/delivery_methods/smtp.rb +153 -0
  98. data/lib/mail/network/delivery_methods/smtp_connection.rb +74 -0
  99. data/lib/mail/network/delivery_methods/test_mailer.rb +40 -0
  100. data/lib/mail/network/retriever_methods/base.rb +63 -0
  101. data/lib/mail/network/retriever_methods/imap.rb +168 -0
  102. data/lib/mail/network/retriever_methods/pop3.rb +140 -0
  103. data/lib/mail/network/retriever_methods/test_retriever.rb +47 -0
  104. data/lib/mail/parsers/address_lists.rb +64 -0
  105. data/lib/mail/parsers/address_lists.treetop +19 -0
  106. data/lib/mail/parsers/content_disposition.rb +535 -0
  107. data/lib/mail/parsers/content_disposition.treetop +46 -0
  108. data/lib/mail/parsers/content_location.rb +139 -0
  109. data/lib/mail/parsers/content_location.treetop +20 -0
  110. data/lib/mail/parsers/content_transfer_encoding.rb +162 -0
  111. data/lib/mail/parsers/content_transfer_encoding.treetop +20 -0
  112. data/lib/mail/parsers/content_type.rb +967 -0
  113. data/lib/mail/parsers/content_type.treetop +68 -0
  114. data/lib/mail/parsers/date_time.rb +114 -0
  115. data/lib/mail/parsers/date_time.treetop +11 -0
  116. data/lib/mail/parsers/envelope_from.rb +194 -0
  117. data/lib/mail/parsers/envelope_from.treetop +32 -0
  118. data/lib/mail/parsers/message_ids.rb +45 -0
  119. data/lib/mail/parsers/message_ids.treetop +15 -0
  120. data/lib/mail/parsers/mime_version.rb +144 -0
  121. data/lib/mail/parsers/mime_version.treetop +19 -0
  122. data/lib/mail/parsers/phrase_lists.rb +45 -0
  123. data/lib/mail/parsers/phrase_lists.treetop +15 -0
  124. data/lib/mail/parsers/received.rb +71 -0
  125. data/lib/mail/parsers/received.treetop +11 -0
  126. data/lib/mail/parsers/rfc2045.rb +464 -0
  127. data/lib/mail/parsers/rfc2045.treetop +36 -0
  128. data/lib/mail/parsers/rfc2822.rb +5341 -0
  129. data/lib/mail/parsers/rfc2822.treetop +410 -0
  130. data/lib/mail/parsers/rfc2822_obsolete.rb +3768 -0
  131. data/lib/mail/parsers/rfc2822_obsolete.treetop +241 -0
  132. data/lib/mail/part.rb +116 -0
  133. data/lib/mail/parts_list.rb +55 -0
  134. data/lib/mail/patterns.rb +34 -0
  135. data/lib/mail/utilities.rb +215 -0
  136. data/lib/mail/version.rb +24 -0
  137. data/lib/mail/version_specific/ruby_1_8.rb +98 -0
  138. data/lib/mail/version_specific/ruby_1_9.rb +113 -0
  139. data/lib/tasks/corpus.rake +125 -0
  140. data/lib/tasks/treetop.rake +10 -0
  141. metadata +253 -0
data/CHANGELOG.rdoc ADDED
@@ -0,0 +1,607 @@
1
+ == HEAD
2
+
3
+ * Fixes #349 an inverted condition on imap open read_only
4
+ * Remove duplicated line feed from regexp
5
+ * Remove unused variable
6
+
7
+ == Version 2.4.4 - Wed Mar 14 22:44:00 +1100 2012 Mikel Lindsaar <mikel@reinteractive.net>
8
+
9
+ * Fix security vulnerability allowing command line exploit when using file delivery method
10
+
11
+ == Version 2.4.3 - Tue Mar 6 19:38:00 UTC 2012 Mikel Lindsaar <mikel@reinteractive.net>
12
+
13
+ * Fix security vulnerability allowing command line exploit when using exim or sendmail from the command line
14
+ * Change Mail#deliver! to also inform the interceptors
15
+ * Encodings.value_decode(str): Treat lines with mixed encoding correctly when the line ends with a plain text part.
16
+
17
+ == Version 2.4.1 - Thu Jan 19 13:49:34 UTC 2012 Mikel Lindsaar <mikel@reinteractive.net>
18
+
19
+ * Fix non ascii character folding problems
20
+ * Handle multipart mail in Mail::Message#to_yaml / #from_yaml
21
+ * More warning fixes
22
+ * Normalize the Parse Error class and messages
23
+ * Fix for Mail::Encodings.unquote_and_convert not handling unquoted characters mixed in between quoted strings
24
+ * Updated treetop to latest version, specs now run approximately 25-30% faster!
25
+ * Version bump to 2.4.1 and gem release
26
+
27
+ == Version 2.4.0 - Sun Jan 15 18:15:56 UTC 2011 Mikel Lindsaar <mikel@reinteractive.net>
28
+
29
+ * Speed up reading of messages by about 12x
30
+ * Added Message#without_attachments! that removes all message's attachments
31
+ * Added shoulda-style RSpec matchers
32
+ * Added support for @ in display name
33
+ * Added support for the :tls and :ssl options
34
+ * Added UTF-16 and UTF-32 support
35
+ * Added Exim as it's own delivery manager
36
+ * Added Ruby 1.9.3 compatibility
37
+ * Fix for Sendmail return-path escaping
38
+ * Fix for alias for SJIS was changed from shift_jis to windows-31J in Ruby 1.9.3
39
+ * Fix for undefined method 'constantize' error when no ActiveSupport loaded
40
+ * Fix Mail::Field#== comparison
41
+ * Fixed Regexp warning: character class has duplicated range
42
+ * Fixed encoding non-latin names in addresses
43
+ * Fixed issue with non-7bit attachment filenames
44
+ * Now define String#blank? only if not defined yet
45
+ * Decoding text parts using charset from Content-Type field
46
+ * Per RFC 5322, do not accept emails with consecutive dots
47
+ * Bunch of bug fixes from contributed pull requests
48
+ * Travis CI setup and passing on 6 rubies
49
+ * Upgrade RSpec to 2.8.0
50
+ * Lots of warnings fixed
51
+ * Version bump to 2.4.0 and gem release
52
+
53
+ == Version 2.3.0 - Tue Apr 26 09:59:56 UTC 2011 Mikel Lindsaar <mikel@rubyx.com>
54
+
55
+ * Remove ActiveSupport from the dependencies, load Active Support if present, or use internals if not
56
+ * Created v2.2 branch for all 2.2 related commits
57
+ * Update activesupport require to use inflector - closes #217
58
+ * Version bump to 2.3 and gem release
59
+
60
+ == Tue Apr 26 06:18:19 UTC 2011 Mikel Lindsaar <mikel@rubyx.com>
61
+
62
+ * Fixed charset warning issue with multipart messages - https://github.com/arvindsv
63
+ * Version bump to 2.2.18 and gem release
64
+
65
+ == Wed 20 Apr 2011 15:16:20 UTC Mikel Lindsaar <mikel@rubyx.com>
66
+
67
+ * Mail::Field.new("Subject: foobar", 'iso-2022-jp') does not set charset - https://github.com/yalab
68
+
69
+ == Tue Apr 19 00:20:54 UTC 2011 Mikel Lindsaar <mikel@rubyx.com>
70
+
71
+ * Fixed an exception with nil in Reply-To and References field - https://github.com/dcormier
72
+ * Version bump to 2.2.17 and gem release
73
+
74
+ == Sat Apr 16 12:57:27 UTC 2011 Mikel Lindsaar <mikel@rubyx.com>
75
+
76
+ * Added support for open SMTP connections and returning the Mail server's response - https://github.com/spiegela
77
+ * RE: not appended to subject when replying to a reply - https://github.com/prateekdayal
78
+ * Support not ascii compatible charset mail send - https://github.com/yalab
79
+ * Fix for issue 208 "mail.body after mail.add_file truncates message body" - https://github.com/glongman
80
+ * Handle bad subject encoding (or ":invalid => :replace" is ineffective for utf-8 to utf-8 encoding) - https://github.com/choonkeat
81
+ * Handle blank Received header field - https://github.com/bcantin
82
+ * Handle part with missing content type - https://github.com/bcantin
83
+ * Handle a "<>" Return field - https://github.com/bcantin
84
+ * Performance improvements for 1.9 - https://github.com/nobu
85
+ * Fix heavy CPU issues when messages are missing a space - https://github.com/scsmith
86
+ * Tighten up allowed encodings - https://github.com/scsmith
87
+ * Added to_yaml & from_yaml (as well as to_hash & from_hash) - https://github.com/srushti
88
+ * Fix up some comments - https://github.com/takahashim
89
+ * Version bump to 2.2.16 and gem release
90
+
91
+ == Wed 26 Jan 2011 02:23:09 UTC Mikel Lindsaar <mikel@rubyx.com>
92
+
93
+ * Update addresses passed into sendmail to escape them (Andy Lindeman)
94
+ * Version bump to 2.2.15 and gem release
95
+
96
+ == Mon 3 Jan 2011 12:48:59 UTC Mikel Lindsaar <mikel@rubyx.com>
97
+
98
+ * Update field_spec to handle encodings, closes issues 44 and 120 (Luis Lopez)
99
+ * Version bump to 2.2.14 and gem release
100
+
101
+ == Mon 3 Jan 2011 00:09:27 UTC Mikel Lindsaar <mikel@rubyx.com>
102
+
103
+ * Use default IANA port on the IMAP retriever_method (Adrian Silva)
104
+ * Updated README to reflect latest ruby versions we test against (mikel)
105
+ * Only remove tlsconnect if it exists (mikel)
106
+
107
+ == Thu 23 Dec 2010 09:15:58 UTC Mikel Lindsaar <mikel@rubyx.com>
108
+
109
+ * Added backport fix for net/smtp bug (Aaron Patterson)
110
+ * Changed "Mail#text_part" so that it does not return a plain text attachment (Anton Mironov)
111
+ * Added in rescue blocks for badly formatted dates as well as encoding problems (Karl Baum)
112
+ * Fixed warning errors of duplicated regular expressions (Kouhei Sutou)
113
+ * Removed duplication from Regex's containing [\w\d]+ as \w contains \d (mikel)
114
+ * Add authentication selection for imap retriever (Björn Albers)
115
+ * Removing warning on @name not being initialized (mikel)
116
+ * Version bump to 2.2.13 and gem release
117
+
118
+ == Fri 10 Dec 2010 09:06:49 UTC Mikel Lindsaar <mikel@rubyx.com>
119
+
120
+ * Fixing problems with multibyte filenamed attachment (amatsuda)
121
+ * Providing IMAP uid and imap object as options to IMAP calls (dball)
122
+ * Fixing filename for windows (mikel)
123
+
124
+ == Sun Dec 5 02:24:55 UTC 2010 Mikel Lindsaar <mikel@rubyx.com>
125
+
126
+ * Updating requirement on i18n to be more relaxed for now until we nuke ActiveSupport dependency (Mikel)
127
+ * Version bump to 2.2.12 and gem release
128
+
129
+ == Tue 30 Nov 2010 00:36:11 UTC Mikel Lindsaar <mikel@rubyx.com>
130
+
131
+ * Allow address lists to handle and ignore empty addresses (Donald Ball)
132
+ * Allow address lists to handle repeating strings of commas (Donald Ball)
133
+ * Noting pending test for malformed folding whitespace (Donald Ball)
134
+ * Adding spec to test error email for missing addresses in to header (Mikel)
135
+ * Bumping i18n dependency to ~> 0.5.0
136
+ * Version bump to 2.2.11 and gem release
137
+
138
+ == Wed 17 Nov 2010 00:43:31 UTC Mikel Lindsaar <mikel@rubyx.com>
139
+
140
+ * Added test retriever and updated documentation (Donald Ball)
141
+ * Fix test suite to work in any timezone (Donald Ball)
142
+ * Added dependency for tlsmail for Ruby 1.8.6 (Donald Ball)
143
+ * Added new feature, replies for mail message
144
+ * Fix references header to use CFWS instead of comma as the separator per RFC2822
145
+ * Version Bum to 2.2.10 and pushed.
146
+
147
+ == Mon Nov 15 13:04:41 UTC 2010 Mikel Lindsaar <mikel@rubyx.com>
148
+
149
+ * Add find_and_delete convenience method for consistency with POP3, document delete_after_find option (Donald Ball)
150
+ * Documenting the openssl_verify_mode setting (Donald Ball)
151
+ * Added ruby-1.8.6 back into the list of tested platforms (Donald Ball)
152
+ * Relax i18n dependency until we remove active support requirement
153
+ * Version Bump to 2.2.9.1 to include new i18n dependency
154
+
155
+ == Tue Oct 26 07:14:36 UTC 2010 Mikel Lindsaar <mikel@rubyx.com>
156
+
157
+ * Version Bump to 2.2.9 and tag
158
+ * Updating Gemfile and gemspec to include i18n and sync dependency versions
159
+ * Added work from Kendall Gifford closing issues #104, #107 and #117
160
+ * Always encode mailbox names with UTF-7 (github: fasta)
161
+
162
+ == Tue Oct 26 06:43:17 UTC 2010 Mikel Lindsaar <mikel@rubyx.com>
163
+
164
+ * Added updates from Donald Ball (github: dball) to improve 1.8.6 support
165
+ * Added patch from Ryan Bigg (github: ryanb) for #mark_for_delete
166
+
167
+ == Thu Oct 7 15:44:31 UTC 2010 Mikel Lindsaar <mikel@rubyx.com>
168
+
169
+ * Version Bump to 2.2.7
170
+ * Release 2.2.7
171
+
172
+ == Thu Oct 7 15:42:57 UTC 2010 Mikel Lindsaar <mikel@rubyx.com>
173
+
174
+ * Added fix for Windows using 'rb' flags, thanks to Luis Lavena and dzhang for pointing it out
175
+ * Fixed up Rakefile to require bundler to run specs and give more appropriate errors messages if this fails
176
+
177
+ == Tue Sep 28 14:59:03 UTC 2010 Mikel Lindsaar <mikel@rubyx.com>
178
+
179
+ * Merged POP3 delete support work from Michael Prendergast
180
+ * Merged IMAP support work from Fabian Staubli
181
+
182
+ == Mon Sep 13 02:31:21 UTC 2010 Mikel Lindsaar <mikel@rubyx.com>
183
+
184
+ * Replace some missing documentation
185
+ * Version bump to 2.2.6.1
186
+
187
+ == Sat 11 Sep 2010 05:13:36 UTC Mikel Lindsaar <mikel@rubyx.com>
188
+
189
+ * Fixed parsing an email with an empty In-Reply-To header (Reported by Eugene Pimenov)
190
+ * Adding address spec for groupname+domain.com@example.com format emails
191
+ * Version bump to 2.2.6
192
+
193
+ == Sat Sep 11 01:56:59 UTC 2010 Mikel Lindsaar <mikel@rubyx.com>
194
+
195
+ * Added new way to do versioning for rubygems
196
+ * Added additional specs for Content-Disposition: inline which are not being encoded correctly - Shawn Pyle
197
+ * Make sure Mail::Message#attachment? returns true/false - Simone Carletti
198
+ * Replace hard-coded references to Mail with more generic self references to allow easier inheritance (closes #61) - Simone Carletti
199
+ * Force encoding on Regexp for Ruby 1.9 to avoid encoding conflicts - Golubev Pavel
200
+ * Added lazy evaluation to message body: body is not parsed until need. It greatly improves performance with big mails if you don't need to read the body (yet)
201
+ * Added Mail.read_from_string as an explicit method (mcansky)
202
+ * Fixed bounce detection for multipart reports that contain a human readable report status part
203
+ * Closed Issue #65 found (incredibly) by quetz - major Kudos for bug hunting
204
+ * Fixed missing trailing CRLF in content type field - Closes issue #57 - Kudos to Henry Flower for finding it
205
+ * Version bump to 2.2.5.2
206
+
207
+ == Sat Sep 11 01:32:13 UTC 2010 Mikel Lindsaar <mikel@rubyx.com>
208
+
209
+ * Closed issue #58 - Content Type not parsing unless lower case.
210
+ * Version bump to 2.2.5.1
211
+
212
+ == Thu 17 Jun 2010 22:13:18 UTC Mikel Lindsaar <mikel@rubyx.com>
213
+
214
+ * Added Mail::POP3.delete_all, including specs (Martijn Storck)
215
+ * Lars Pind updates on header folding
216
+ * Version bump to 2.2.5
217
+
218
+ == Tue Jun 8 01:55:21 UTC 2010 Mikel Lindsaar <mikel@rubyx.com>
219
+
220
+ * Added inline attachment support to mail (mikel)
221
+
222
+ == Mon Jun 7 18:00:39 UTC 2010 Mikel Lindsaar <mikel@rubyx.com>
223
+
224
+ * Updating versioning so we only have one source, VERSION.yml (mikel)
225
+ * Changed activesupport dependency to 2.3.6 to fix #53, #64, and def #67. (Artem Titoulenko)
226
+ * Fixing typo in break_down_to.rb. (mikel)
227
+
228
+ == Mon Jun 7 18:07:16 UTC 2010 Mikel Lindsaar <mikel@rubyx.com>
229
+
230
+ * fixing a typo when generating docs. (Andrew Bloom)
231
+ * Changing \r\n\t to \r\n\s throughout mail (mikel)
232
+ * Handle multiple quoted words in Encodings.unquote_and_convert_to (Eric Kidd)
233
+ * Ruby 1.9: mark source encoding so it's usable with -Ks, -Ke, etc (Jeremy Kemper)
234
+ * Add #include? to mail body for convenience (Maxim Chernyak)
235
+ * Use Mail::TestMailer.deliveries in README example (John Trupiano)
236
+ * Allow bundler to automatically build a gem directly from git (Eric Kidd)
237
+
238
+ == Sun Apr 11 07:49:15 UTC 2010 Mikel Lindsaar <raasdnil@gmail.com>
239
+
240
+ * Lots of updates on encoding and decoding of headers and unstructured fields. This
241
+ is now a lot cleaner and nicer. Also more predictable.
242
+ * Merged encoding branch back into head
243
+ * Version bump to 2.2.0
244
+ * Tagged 2.2.0
245
+
246
+ == Sun Apr 4 06:41:46 UTC 2010 Mikel Lindsaar <raasdnil@gmail.com>
247
+
248
+ * Created non-ascii header auto encoding for address fields and unstructured fields
249
+ * Changed default behaviour of mail, if you specify a charset, it will use that charset
250
+ regardless of what is in the body. Previously, if the body was all US-ASCII, it would
251
+ set the charset to US-ASCII in preference.
252
+ * Many internal version jumps from 2.1.5.3 => 2.1.5.8 - unreleased development versions
253
+
254
+ == Mon 29 Mar 2010 07:04:34 UTC Mikel Lindsaar <raasdnil@gmail.com>
255
+
256
+ * Version bump to 2.1.5.3
257
+ * No longer depend on vendor'd treetop as treetop now has optional loading of parts of the library
258
+ * Change treetop dependency to 1.4.5
259
+
260
+ == Sun 28 Mar 2010 10:31:33 UTC Mikel Lindsaar <raasdnil@gmail.com>
261
+
262
+ * Version bump to 2.1.5.2
263
+ * Fixed up preserve case in header fields when assigned from a message closes issue #46
264
+
265
+ == Sun 28 Mar 2010 09:02:20 UTC Mikel Lindsaar <raasdnil@gmail.com>
266
+
267
+ * Version bump to 2.1.5.1
268
+ * Fixed net/pop3.rb regression for Ruby 1.8.6
269
+ * Merged in Jeremy Kemper's updates:
270
+ * Bump vendored treetop to 1.4.4
271
+ * Use Mikel's treetop for cucumber workaround
272
+ * Use LOAD_PATH for spec_helper instead of relative requires
273
+ * Force treetop from git so cucumber doesn't pull in old version
274
+
275
+ == Sun Mar 28 07:01:07 UTC 2010 Mikel Lindsaar <raasdnil@gmail.com>
276
+
277
+ * Version bump to 2.1.5
278
+ * Changed guess encoding to short circuit to binary if the mime type is unknown, should be safe
279
+ * Renaming spec to match the file for attachment_lists.rb
280
+ * Adding Message#decoded returns Message#body#decoded if the message is not multipart
281
+
282
+ == Sun Mar 28 02:55:42 UTC 2010 Mikel Lindsaar <raasdnil@gmail.com>
283
+
284
+ * Version bump to 2.1.4
285
+
286
+ == Sun Mar 28 00:26:27 UTC 2010 Mikel Lindsaar <raasdnil@gmail.com>
287
+
288
+ * Merged in Jeremy/treetop to vendored treetop
289
+ * Merged in nathansobo/treetop to vendored treetop
290
+ * Merged in pzbowen/mail into mail - Adds body auto encoding - awesome work
291
+ * Fixed content-transfer-encoding parser to be more compliant per RFC, also now handles trailing semi-colons correctly
292
+ * Fixed content-transfer-encoding parser to handle weird "from the wild" misspellings
293
+ * Added message.errors, header.errors arrays, returns array of [field_name, value, error_object] for each field that failed to parse
294
+ * Removed bundler require from Rakefile
295
+
296
+ == Sun Mar 17 03:03:03 UTC 2010 Mikel Lindsaar <raasdnil@gmail.com>
297
+
298
+ * Keep header name case when failing to unstructured field
299
+
300
+ == Wed Feb 24 09:14:56 UTC 2010 Mikel Lindsaar <raasdnil@gmail.com>
301
+
302
+ * Fixed multiaddress bounce messages crashing when calling .bounced? Now just take the first report and return that.
303
+ * Closes issue 38 - final_recipient method give problem when one bounce email for multiple email ids
304
+ * Fixing up TODO and Docs
305
+
306
+ == Sun Mar 22 03:24:15 UTC 2010 Mikel Lindsaar <raasdnil@gmail.com>
307
+
308
+ * Version bump to 2.1.3
309
+
310
+ == Thu Jan 28 00:25:02 UTC 2010 Mikel Lindsaar <raasdnil@gmail.com>
311
+
312
+ * Added TMM1's patch to not raise errors if a email is not multipart/report
313
+ * Added html_part and text_part now return the first text/html or text/plain part they find. Order is from top to bottom of the email, all parts, flattened.
314
+ * Cleaning up register_interceptor and register_observer including documentation
315
+ * Renamed #register_for_delivery_notification to #register_observer
316
+ * Renamed #register_for_delivery_interception to #register_interceptor
317
+ * Adding spec to check for folding of non ASCII words that have been encoded
318
+ * Updating Message#inspect to be a bit more friendly... it is for us mere mortals after all
319
+ * Version bump to 2.1.2
320
+
321
+ == Sun Jan 28 02:59:34 UTC 2010 Mikel Lindsaar <raasdnil@gmail.com>
322
+
323
+ * Removed old method of setting delivery_method
324
+
325
+ == Mon Jan 25 11:36:13 UTC 2010 Mikel Lindsaar <raasdnil@gmail.com>
326
+
327
+ * Added ability for address fields to init on an array instead of just a string.
328
+ * Version bump to 2.1.1
329
+
330
+ == Mon Jan 25 10:36:33 UTC 2010 Mikel Lindsaar <raasdnil@gmail.com>
331
+
332
+ * Now passes a block to the delivery handler, which can just call yield if it want's Mail to just do it's normal delivery method
333
+ * Moved Mail.deliveries into Mail::TestMailer.deliveries. Now only gets mail appended to it if you are sending with the :test delivery_method (only for testing)
334
+ * Version bump to 2.1.0
335
+
336
+ == Mon Jan 25 01:44:13 UTC 2010 Mikel Lindsaar <raasdnil@gmail.com>
337
+
338
+ * Change :deliver! to deliver a mail object, bypassing the :perform_deliveries and :raise_delivery_errors flags, also does not append the mail object to Mail.deliveries, thus the ! (dangerous). The intended use for :deliver! is for people wanting to have their own delivery_handler (like ActionMailer uses) to track and handle delivery failures.
339
+ * Added :delivery_handler to Message. Allows you to pass an object that will be sent :deliver_mail(self) by the Mail::Message instance when it is sent :deliver and bypasses the usual delivery method.
340
+ * Changed :perform_deliveries flag to be more consistent with it's name, mail will not append itself to the Mail.deliveries collection if :perform_deliveries is false
341
+
342
+ == Sat Jan 23 23:49:50 UTC 2010 Mikel Lindsaar <raasdnil@gmail.com>
343
+
344
+ * Version bump to 2.0.5
345
+ * Added :raise_delivery_errors to Mail::Message, if set to false will silently rescue all errors raised by the delivery methods, set to true by default
346
+
347
+ == Sat Jan 23 23:28:42 UTC 2010 Mikel Lindsaar <raasdnil@gmail.com>
348
+
349
+ * Version bump to 2.0.4
350
+ * Added :perform_deliveries to mail, will not actually call deliver on the delivery method if this is set to false, set to true by default.
351
+ * Added @delivery_notification_observers to mail messages, you can register an observer with mail by calling mail.register_for_delivery_notification(observer) and then when mail is told to :deliver it will call your observer with observer.delivered_email(self). It will call your observer if it actually performed the delivery or not (that is, irregardless of the :perform_deliveries flag)
352
+ * Added ability to overwrite the Mail.deliveries store with an object of your choice instead of just an array, this is a good way to find out if something actually got delivered as if :perform_deliveries is false, this collection will not get the mail message appended
353
+
354
+ == Sat Jan 23 05:32:53 UTC 2010 Mikel Lindsaar <raasdnil@gmail.com>
355
+
356
+ * Version bump to 2.0.3
357
+ * Made body.sort_parts! recursive, to do the entire body
358
+ * Added ability to use << on the results returned by the various address fields, ie, mail.to << 'new@address' now works
359
+ * Message now adds multipart/mixed as the content type if nothing is set and there are parts to the message
360
+ * Added #display_names and #addrs to all address fields. #addrs returns the actual Mail::Address object for each address in the field.
361
+ * Body should call to_s on given input... incase someone gave it an IO.readlines result (Array)
362
+ *
363
+
364
+ == Thu Jan 21 05:27:17 UTC 2010 Mikel Lindsaar <raasdnil@gmail.com>
365
+
366
+ * Version bump to 2.0.2
367
+ * Major change to attachments, add_file now only accepts
368
+ {:filename => 'full/path/to/file.png'} or
369
+ {:filename => 'file.png', :content => 'string of file content'}
370
+ you can also now do mail.attachments['filename.png'] = File.read('path/to/file.png')
371
+ which is nice too!
372
+
373
+ == Fri Jan 15 09:20:51 UTC 2010 Mikel Lindsaar <raasdnil@gmail.com>
374
+
375
+ * Rewrote all network classes to not use singletons. Means different Mail::Message objects can have different delivery methods.
376
+ * Added examples for how to send via GMail, MobileMe, Sendmail, File etc.
377
+ * Version bump to 2.0.0 as Network API changed drastically, now not a singleton class.
378
+ * Fixed that return-path should only return one address
379
+
380
+ == Thu Jan 14 10:41:22 UTC 2010 Mikel Lindsaar <raasdnil@gmail.com>
381
+
382
+ * Version update to 1.6.0 - API change on mail.address_fields to always return arrays
383
+ * Updated all message.address_field methods to always return arrays, so mail.from #=> ['one@address.com'] now, is least surprise
384
+ * Updated handling of empty group lists so it didn't crash
385
+
386
+ == Thu Jan 12 10:41:47 UTC 2010 Mikel Lindsaar <raasdnil@gmail.com>
387
+
388
+ * Version 1.5.3, handling invalid input on fields. Highly recommended update
389
+ * Updated fields to always try parsing the given data (unless blank). This allows mail to catch invalid input and return UnstructuredFields. Makes mail a lot more resistant to invalid input.
390
+
391
+ == Fri 8 Jan 2010 00:00:08 UTC Mikel Lindsaar <raasdnil@gmail.com>
392
+
393
+ * Version bump to 1.5.2
394
+
395
+ == Fri 8 Jan 8:55:49 2010 +1100 Mikel Lindsaar <raasdnil@gmail.com>
396
+
397
+ * Updated Sendmail and SMTP delivery methods to use return-path if present
398
+ * Fix up a lot of content-type parsing problems
399
+ * Updating compat listing
400
+ * Moving error emails into one directory
401
+ * Moving error emails into one directory
402
+ * Initializing @tls variable to remove warnings
403
+ * Moved default corpus directory
404
+ * Fixed up git ignore file
405
+
406
+ == Thu 6 Jan 2010 23:59:29 UTC Mikel Lindsaar <raasdnil@gmail.com>
407
+
408
+ * Added compatibility list to Readme.rdoc
409
+ * Fixing encoding of return path to be per RFC 2822, adding angle brackets around the addr_spec
410
+ * Specs covering return path setting and preserving
411
+
412
+ == Thu 5 Jan 2010 23:59:48 UTC Mikel Lindsaar <raasdnil@gmail.com>
413
+
414
+ * Moving the require for tlsmail for Ruby 1.8.6 into mail.rb
415
+
416
+ == Sun Jan 3 00:08:06 UTC 2010 Mikel Lindsaar <raasdnil@gmail.com>
417
+
418
+ * Version bump to 1.5.0
419
+
420
+ * Major API change in Message#field_name. This WILL break your applications that use Mail. Message#field_name now returns good, intelligent, default values. You can still access the field object by calling Message#[:field_name] or Message#['field_name'].
421
+
422
+ == Sat Jan 2 04:12:53 UTC 2010 Mikel Lindsaar <raasdnil@gmail.com>
423
+
424
+ * Message-ID, Content-ID, References et al, now return the default value of the message ID without the angle brackets, as per RFC 2822, "Semantically, the angle bracket characters are not part of the msg-id; the msg-id is what is contained between the two angle bracket characters."
425
+
426
+ * Message class now has getter and setter methods for all the supported field types explicitly. This allows us to return a "default" value for all fields.
427
+
428
+ * All address fields, when called from Message#to or Message#from or the like, return either a string of the address spec (mikel@test.lindsaar.net) if it is a single entry, or an array of address specs if there is more than one ['mikel@test.lindsaar.net', 'ada@test.lindsaar.net']
429
+
430
+ == Mon 28 Dec 2009 01:21:52 UTC Mikel Lindsaar <raasdnil@gmail.com>
431
+
432
+ * Added sorting of parts, default is text/plain, then text/enriched and text/html. Access through Body#set_sort_order and Body#sort_parts! (called from Body#encode automatically)
433
+ * Version bump to 1.4.2
434
+
435
+ == Sun Dec 27 10:38:24 UTC 2009 Mikel Lindsaar <raasdnil@gmail.com>
436
+
437
+ * Updating treetop and mail to initialize uninitialized instance variables to
438
+ nil
439
+ * Version bump to 1.4.1
440
+
441
+ == Sun Dec 27 09:51:27 UTC 2009 Mikel Lindsaar <raasdnil@gmail.com>
442
+
443
+ * Version bump to 1.4 because now :to_s calls :decoded for all fields and body
444
+ while :to_s calls :encoded for Message and Header containers. Makes sense...
445
+ really.
446
+
447
+ == Sun Dec 27 07:30:02 UTC 2009 Mikel Lindsaar <raasdnil@gmail.com>
448
+
449
+ * Changed fields to default to :decoded on :to_s, all container objects
450
+ retain :encoded as the default for :to_s
451
+
452
+ == Thu Dec 17 06:35:05 UTC 2009 Mikel Lindsaar <raasdnil@gmail.com>
453
+
454
+ * Fixed parsing error 'Subject: =?ISO-8859-1?Q?Re=3A_ol=E1?=' (has a new line embedded)
455
+
456
+ == Thu Dec 17 02:14:23 UTC 2009 Mikel Lindsaar <raasdnil@gmail.com>
457
+
458
+ * Version 1.3.4
459
+ * Vendor'd treetop
460
+
461
+ == Thu Dec 17 01:32:00 UTC 2009 Mikel Lindsaar <raasdnil@gmail.com>
462
+
463
+ * Version 1.3.3
464
+ * Removed dependency on treetop, don't need it at runtime
465
+
466
+ == Wed Dec 16 23:48:46 UTC 2009 Mikel Lindsaar <raasdnil@gmail.com>
467
+
468
+ * Version 1.3.2
469
+ * Resolved Ruby 1.9.1-head not working because File.basename only accepts US-ASCII or 8Bit
470
+
471
+ == Sun Dec 13 01:06:17 UTC 2009 Mikel Lindsaar <raasdnil@gmail.com>
472
+
473
+ * Version 1.3.1
474
+ * Resolved Issue #18 - Wrong instance variable name
475
+ * Resolved Issue #15 - Duplicate block call
476
+
477
+ == Thu Dec 10 21:25:37 UTC 2009 Mikel Lindsaar <raasdnil@gmail.com>
478
+
479
+ * Resolved Issue #13 - replacing From field results in from field becoming optional field.
480
+
481
+ == Thu 3 Dec 2009 00:52:12 UTC Mikel Lindsaar <raasdnil@gmail.com>
482
+
483
+ * Added POP upgrades from Nicolas Fouché
484
+ * Added patch to handle multiple from lines in email from Luke Grimstrup
485
+
486
+ == Mon Nov 23 23:34:22 UTC 2009 Mikel Lindsaar <raasdnil@gmail.com>
487
+
488
+ * Resolved Issue #12 - Wrong comment in smtp.rb
489
+
490
+ == Mon Nov 23 22:35:50 UTC 2009 Mikel Lindsaar <raasdnil@gmail.com>
491
+
492
+ * Changed the way attachments are added so that it does not break depending on the order of the Hash passed in.
493
+ * Version bump to 1.3.0 - Now works with Edge ActionMailer, MRI 1.8.6, 1.8.7, 1.9.1, all tests passing
494
+
495
+ == Sun Nov 22 12:19:44 UTC 2009 Mikel Lindsaar <raasdnil@gmail.com>
496
+
497
+ * Added check on add_part to make sure if there is already a body, and if so, make a text_part of the body
498
+ * Fixing up attachment adding and making sure multipart emails always have boundaries
499
+ * Change Message#attachments to now recursively return all attachments in the email in an ordered flattened array
500
+ * Added ability for Mail::Message to accept {:headers => {'custom-header' => 'value', 'another-custom-header' => 'value'}} as a param on init
501
+ * Adding ability to Mail::Message to add a part via :part(params) with optional block
502
+ * Fixed up QP encoding forcing underscores into everything with a space
503
+ * Added ReturnPathField#address
504
+ * Updating gem loads and active support loads
505
+
506
+ == Sat Nov 21 12:52:46 UTC 2009 Mikel Lindsaar <raasdnil@gmail.com>
507
+
508
+ * Changed Mail::Encodings to clean it up, added in unquote_and_convert_to as well as refactor in this area
509
+
510
+ == Thu Nov 19 04:16:10 UTC 2009 Mikel Lindsaar <raasdnil@gmail.com>
511
+
512
+ * Added sendmail support from (Simon Rozet)
513
+ * Changed to bundler for gem dependancies and moved gem generation into rakefile (Simon Rozet)
514
+ * Bumped to 1.2.6 for sendmail support
515
+
516
+ == Wed Nov 18 04:26:21 UTC 2009 Mikel Lindsaar <raasdnil@gmail.com>
517
+
518
+ * Changed Encodings.param_encode(string) so it intelligently encodes and quotes needed
519
+ items and leaves plain, no special char, US-ASCII alone unquoted.
520
+
521
+ == Sat Nov 14 08:20:21 UTC 2009 Mikel Lindsaar <raasdnil@gmail.com>
522
+
523
+ * Resolved Issue #10 - empty/nil cc/bcc field causes exception (Mail::Field::ParseError)
524
+
525
+ == Fri Nov 13 00:31:04 UTC 2009 Mikel Lindsaar <raasdnil@gmail.com>
526
+
527
+ * Hacked and mutilated the network section, made it easier to extend out with other
528
+ delivery and retriever methods. API changed SLIGHTLY with this. Please check the
529
+ readme
530
+ * Resolved Issue #8 - Mail::SMTP now delivers to all mail.destinations
531
+ * Version bump to 1.2.5
532
+
533
+ == Thu Nov 12 02:58:01 UTC 2009 Mikel Lindsaar <raasdnil@gmail.com>
534
+
535
+ * Resolved Issue #5 - Message ID not handling multiple periods in left hand side
536
+ * Resolved Issue #6 - Ordering of add_file and body items causes invalid emails
537
+
538
+ == Tue Nov 10 08:15:14 UTC 2009 Mikel Lindsaar <raasdnil@gmail.com>
539
+
540
+ * Resolved Issue #5 - Message ID generation issue
541
+ * Resolved Issue #7 - README add_file examples don't seem to work - Updated readme and
542
+ rdoc in Message#add_file
543
+
544
+ == Mon Nov 9 23:38:33 UTC 2009 Mikel Lindsaar <raasdnil@gmail.com>
545
+
546
+ * Added ability to create new email via a hash or hash-like object. <mikel>
547
+ * Moved all of the Part init into the Message class. Part now just uses Message's init,
548
+ also moved all the attachment related functions into Message. As Part is a subclass
549
+ of message, you shouldn't see any interface changes here.
550
+
551
+ == Fri Nov 6 22:52:10 UTC 2009 Mikel Lindsaar <raasdnil@gmail.com>
552
+
553
+ * a6ef2b4: Fixed Issue #4 - Can't call encoding on non existant
554
+ content-transer-encoding header
555
+
556
+ == Fri Nov 6 00:51:55 UTC 2009 Mikel Lindsaar <raasdnil@gmail.com>
557
+
558
+ * Handled unstructured field folding "blank" lines
559
+ * Fixed error in header.rb that created fields into an array, instead of a FieldList, resulting
560
+ in mail.encode returning a random sort order on the header.
561
+ * Made unstructured fields attempt to decode their values on :decode
562
+
563
+ == Thu Nov 5 04:45:31 UTC 2009 Mikel Lindsaar <raasdnil@gmail.com>
564
+
565
+ * 2acb70a: Closes Issue #1 - Handling badly formatted content-type fields <mikel>
566
+
567
+ == Wed Nov 4 23:24:32 UTC 2009 Mikel Lindsaar <raasdnil@gmail.com>
568
+
569
+ * 2b5d608: Closes Issue #2 - Empty header field values not parsing <mikel>
570
+ * Version bumb to 1.2.1
571
+
572
+ == Wed Nov 4 12:54:43 UTC 2009 Mikel Lindsaar <raasdnil@gmail.com>
573
+
574
+ * Renamed Mail::Message.encode! to Mail::Message.ready_to_send!, deprecated :encode! <mikel>
575
+ * Rewrote encoding and decoding methods on all classes. Adds a lot of boiler plate code, but allows us to
576
+ be really precise in each field type that needs custom encoding. Now all encoding is done by the field_type
577
+ itself. Need to follow through on the body. <mikel>
578
+ * Bump version to 1.2.0 due to changes of :encoded, :decoded behaviour <mikel>
579
+
580
+ == Tue Nov 3 00:59:45 UTC 2009 Mikel Lindsaar <raasdnil@gmail.com>
581
+
582
+ * Tested mail against entire Enron set (2.3gb) and the Trec 2005 set (0.5gb), ~ half a million emails without crashing <jlindley>
583
+ * Some headers only can appear once, enforce during header parse assignment. <jlindley>
584
+ * Convert empty bodies into empty arrays instead of nil. <jlindley>
585
+ * Handle blank content dispositions. <jlindley>
586
+ * Mention Trec 2005 Spam Corpus in readme <jlindley>
587
+ * Add 'rake corpus:verify_all' to allow parse checks in bulk. <jlindley>
588
+ * Added handling of multi value parameters, like filename*1*="us-ascii'en'blah" filename*2="bleh" <mikel>
589
+ * Added dependency on ActiveSupport 2.3 or higher <mikel>
590
+
591
+ == Sun Nov 1 12:00:00 UTC 2009 Mikel Lindsaar <raasdnil@gmail.com>
592
+
593
+ * handle OpenSSL::SSL::VERIFY_NONE returning 0 <jlindley>
594
+ * doing Mail.new { content_type [text, plain, { charset => UTF-8 }] } is now
595
+ possible (content type accepts an array) <mikel>
596
+
597
+ == Sat Oct 31 11:00:41 UTC 2009 Mikel Lindsaar <raasdnil@gmail.com>
598
+
599
+ * Fixed attachment handling, so mail can find attachment from a content-type,
600
+ content-disposition or content-location
601
+ * Added content-location field and parser
602
+ * Added message.has_attachments? for ActionMailer friendliness
603
+ * Added attachment.original_filename for ActionMailer friendliness
604
+
605
+ == Sat Oct 25 13:38:01 UTC 2009 Mikel Lindsaar <raasdnil@gmail.com>
606
+
607
+ * Birthday, Mail released as a gem... phew