tdiary 5.4.0 → 5.5.0.beta1

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.
Files changed (641) hide show
  1. checksums.yaml +4 -4
  2. data/Gemfile +25 -2
  3. data/Gemfile.lock +211 -61
  4. data/README.md +4 -4
  5. data/doc/HOWTO-make-plugin.md +1 -1
  6. data/doc/HOWTO-testing-tDiary.md +2 -2
  7. data/doc/INSTALL-cgi.md +7 -0
  8. data/doc/INSTALL-paas.md +11 -11
  9. data/doc/INSTALL.md +2 -2
  10. data/doc/README.en.md +1 -1
  11. data/doc/README.md +1 -1
  12. data/lib/aws/pa_api.rb +6 -2
  13. data/lib/tdiary/admin.rb +6 -4
  14. data/lib/tdiary/application.rb +17 -17
  15. data/lib/tdiary/author_only_base.rb +6 -13
  16. data/lib/tdiary/base.rb +52 -16
  17. data/lib/tdiary/cgi_adapter.rb +86 -0
  18. data/lib/tdiary/cgi_compat.rb +189 -0
  19. data/lib/tdiary/configuration.rb +1 -1
  20. data/lib/tdiary/core_ext.rb +4 -53
  21. data/lib/tdiary/diary_container.rb +23 -11
  22. data/lib/tdiary/dispatcher/index_main.rb +16 -16
  23. data/lib/tdiary/dispatcher/update_main.rb +16 -16
  24. data/lib/tdiary/dispatcher.rb +4 -28
  25. data/lib/tdiary/environment.rb +12 -0
  26. data/lib/tdiary/filter.rb +5 -2
  27. data/lib/tdiary/io/pstore.rb +6 -3
  28. data/lib/tdiary/plugin/00default.rb +10 -14
  29. data/lib/tdiary/plugin/05referer.rb +6 -6
  30. data/lib/tdiary/plugin/60sf.rb +1 -1
  31. data/lib/tdiary/plugin.rb +76 -16
  32. data/lib/tdiary/request.rb +11 -353
  33. data/lib/tdiary/tasks/db.rake +17 -4
  34. data/lib/tdiary/tasks/heroku.rake +9 -0
  35. data/lib/tdiary/tasks/release.rake +126 -146
  36. data/lib/tdiary/version.rb +1 -1
  37. data/lib/tdiary/view.rb +3 -3
  38. data/lib/tdiary.rb +3 -1
  39. data/misc/convert2.rb +3 -0
  40. data/misc/migrate.rb +3 -0
  41. data/misc/plugin/a.rb +1 -6
  42. data/misc/plugin/amazon.rb +5 -4
  43. data/misc/plugin/calendar2.rb +1 -1
  44. data/misc/plugin/en/disp_referrer.rb +1 -1
  45. data/misc/plugin/ja/disp_referrer.rb +1 -1
  46. data/misc/plugin/kw.rb +2 -21
  47. data/misc/plugin/makelirs.rb +1 -4
  48. data/tdiary.conf.sample +8 -0
  49. data/theme/base.css +15 -0
  50. data/vendor/bundle/ruby/3.4.0/bin/emot +29 -0
  51. data/vendor/bundle/ruby/3.4.0/bin/hikidoc +29 -0
  52. data/vendor/bundle/ruby/3.4.0/bin/rackup +29 -0
  53. data/vendor/bundle/ruby/3.4.0/bin/rake +29 -0
  54. data/vendor/bundle/ruby/3.4.0/bin/thor +29 -0
  55. data/vendor/bundle/ruby/3.4.0/cache/base64-0.3.0.gem +0 -0
  56. data/vendor/bundle/ruby/3.4.0/cache/cgi-0.5.2.gem +0 -0
  57. data/vendor/bundle/ruby/3.4.0/cache/date-3.5.1.gem +0 -0
  58. data/vendor/bundle/ruby/3.4.0/cache/emot-0.0.4.gem +0 -0
  59. data/vendor/bundle/ruby/3.4.0/cache/fastimage-2.4.1.gem +0 -0
  60. data/vendor/bundle/ruby/3.4.0/cache/hikidoc-0.1.1.gem +0 -0
  61. data/vendor/bundle/ruby/3.4.0/cache/logger-1.7.0.gem +0 -0
  62. data/vendor/bundle/ruby/3.4.0/cache/mail-2.9.1.gem +0 -0
  63. data/vendor/bundle/ruby/3.4.0/cache/mini_mime-1.1.5.gem +0 -0
  64. data/vendor/bundle/ruby/3.4.0/cache/net-imap-0.5.15.gem +0 -0
  65. data/vendor/bundle/ruby/3.4.0/cache/net-pop-0.1.2.gem +0 -0
  66. data/vendor/bundle/ruby/3.4.0/cache/net-protocol-0.2.2.gem +0 -0
  67. data/vendor/bundle/ruby/3.4.0/cache/net-smtp-0.5.1.gem +0 -0
  68. data/vendor/bundle/ruby/3.4.0/cache/pstore-0.2.1.gem +0 -0
  69. data/vendor/bundle/ruby/3.4.0/cache/rack-3.2.6.gem +0 -0
  70. data/vendor/bundle/ruby/3.4.0/cache/rack-session-2.1.2.gem +0 -0
  71. data/vendor/bundle/ruby/3.4.0/cache/rackup-2.3.1.gem +0 -0
  72. data/vendor/bundle/ruby/3.4.0/cache/rake-13.4.2.gem +0 -0
  73. data/vendor/bundle/ruby/3.4.0/cache/thor-1.5.0.gem +0 -0
  74. data/vendor/bundle/ruby/3.4.0/cache/timeout-0.6.1.gem +0 -0
  75. data/vendor/bundle/ruby/3.4.0/extensions/x86_64-linux/3.4.0/cgi-0.5.2/cgi/escape.so +0 -0
  76. data/vendor/bundle/ruby/3.4.0/extensions/x86_64-linux/3.4.0/cgi-0.5.2/gem.build_complete +0 -0
  77. data/vendor/bundle/ruby/3.4.0/extensions/x86_64-linux/3.4.0/cgi-0.5.2/gem_make.out +18 -0
  78. data/vendor/bundle/ruby/3.4.0/extensions/x86_64-linux/3.4.0/date-3.5.1/date_core.so +0 -0
  79. data/vendor/bundle/ruby/3.4.0/extensions/x86_64-linux/3.4.0/date-3.5.1/gem.build_complete +0 -0
  80. data/vendor/bundle/ruby/3.4.0/extensions/x86_64-linux/3.4.0/date-3.5.1/gem_make.out +24 -0
  81. data/vendor/bundle/ruby/3.4.0/extensions/x86_64-linux/3.4.0/date-3.5.1/mkmf.log +93 -0
  82. data/vendor/bundle/ruby/3.4.0/gems/base64-0.3.0/BSDL +22 -0
  83. data/vendor/bundle/ruby/3.4.0/gems/base64-0.3.0/COPYING +56 -0
  84. data/vendor/bundle/ruby/3.4.0/gems/base64-0.3.0/LEGAL +60 -0
  85. data/vendor/bundle/ruby/3.4.0/gems/base64-0.3.0/README.md +48 -0
  86. data/vendor/bundle/ruby/3.4.0/gems/base64-0.3.0/lib/base64.rb +381 -0
  87. data/vendor/bundle/ruby/3.4.0/gems/base64-0.3.0/sig/base64.rbs +355 -0
  88. data/vendor/bundle/ruby/3.4.0/gems/cgi-0.5.2/BSDL +22 -0
  89. data/vendor/bundle/ruby/3.4.0/gems/cgi-0.5.2/COPYING +56 -0
  90. data/vendor/bundle/ruby/3.4.0/gems/cgi-0.5.2/README.md +98 -0
  91. data/vendor/bundle/ruby/3.4.0/gems/cgi-0.5.2/ext/cgi/escape/Makefile +275 -0
  92. data/vendor/bundle/ruby/3.4.0/gems/cgi-0.5.2/ext/cgi/escape/depend +2 -0
  93. data/vendor/bundle/ruby/3.4.0/gems/cgi-0.5.2/ext/cgi/escape/escape.c +487 -0
  94. data/vendor/bundle/ruby/3.4.0/gems/cgi-0.5.2/ext/cgi/escape/extconf.rb +7 -0
  95. data/vendor/bundle/ruby/3.4.0/gems/cgi-0.5.2/lib/cgi/cookie.rb +212 -0
  96. data/vendor/bundle/ruby/3.4.0/gems/cgi-0.5.2/lib/cgi/core.rb +1273 -0
  97. data/vendor/bundle/ruby/3.4.0/gems/cgi-0.5.2/lib/cgi/escape.rb +227 -0
  98. data/vendor/bundle/ruby/3.4.0/gems/cgi-0.5.2/lib/cgi/escape.so +0 -0
  99. data/vendor/bundle/ruby/3.4.0/gems/cgi-0.5.2/lib/cgi/html.rb +1040 -0
  100. data/vendor/bundle/ruby/3.4.0/gems/cgi-0.5.2/lib/cgi/session/pstore.rb +91 -0
  101. data/vendor/bundle/ruby/3.4.0/gems/cgi-0.5.2/lib/cgi/session.rb +574 -0
  102. data/vendor/bundle/ruby/3.4.0/gems/cgi-0.5.2/lib/cgi/util.rb +48 -0
  103. data/vendor/bundle/ruby/3.4.0/gems/cgi-0.5.2/lib/cgi.rb +310 -0
  104. data/vendor/bundle/ruby/3.4.0/gems/date-3.5.1/BSDL +22 -0
  105. data/vendor/bundle/ruby/3.4.0/gems/date-3.5.1/COPYING +56 -0
  106. data/vendor/bundle/ruby/3.4.0/gems/date-3.5.1/README.md +102 -0
  107. data/vendor/bundle/ruby/3.4.0/gems/date-3.5.1/ext/date/Makefile +273 -0
  108. data/vendor/bundle/ruby/3.4.0/gems/date-3.5.1/ext/date/date_core.c +10065 -0
  109. data/vendor/bundle/ruby/3.4.0/gems/date-3.5.1/ext/date/date_parse.c +3086 -0
  110. data/vendor/bundle/ruby/3.4.0/gems/date-3.5.1/ext/date/date_strftime.c +638 -0
  111. data/vendor/bundle/ruby/3.4.0/gems/date-3.5.1/ext/date/date_strptime.c +704 -0
  112. data/vendor/bundle/ruby/3.4.0/gems/date-3.5.1/ext/date/date_tmx.h +56 -0
  113. data/vendor/bundle/ruby/3.4.0/gems/date-3.5.1/ext/date/extconf.rb +13 -0
  114. data/vendor/bundle/ruby/3.4.0/gems/date-3.5.1/ext/date/prereq.mk +19 -0
  115. data/vendor/bundle/ruby/3.4.0/gems/date-3.5.1/ext/date/zonetab.h +1564 -0
  116. data/vendor/bundle/ruby/3.4.0/gems/date-3.5.1/ext/date/zonetab.list +330 -0
  117. data/vendor/bundle/ruby/3.4.0/gems/date-3.5.1/lib/date.rb +70 -0
  118. data/vendor/bundle/ruby/3.4.0/gems/date-3.5.1/lib/date_core.so +0 -0
  119. data/vendor/bundle/ruby/3.4.0/gems/emot-0.0.4/Gemfile +4 -0
  120. data/vendor/bundle/ruby/3.4.0/gems/emot-0.0.4/LICENSE.txt +22 -0
  121. data/vendor/bundle/ruby/3.4.0/gems/emot-0.0.4/README.md +87 -0
  122. data/vendor/bundle/ruby/3.4.0/gems/emot-0.0.4/Rakefile +7 -0
  123. data/vendor/bundle/ruby/3.4.0/gems/emot-0.0.4/bin/emot +5 -0
  124. data/vendor/bundle/ruby/3.4.0/gems/emot-0.0.4/emot.gemspec +26 -0
  125. data/vendor/bundle/ruby/3.4.0/gems/emot-0.0.4/lib/emot/cli.rb +62 -0
  126. data/vendor/bundle/ruby/3.4.0/gems/emot-0.0.4/lib/emot/map.rb +894 -0
  127. data/vendor/bundle/ruby/3.4.0/gems/emot-0.0.4/lib/emot/symbol_ext.rb +11 -0
  128. data/vendor/bundle/ruby/3.4.0/gems/emot-0.0.4/lib/emot/version.rb +3 -0
  129. data/vendor/bundle/ruby/3.4.0/gems/emot-0.0.4/lib/emot.rb +34 -0
  130. data/vendor/bundle/ruby/3.4.0/gems/emot-0.0.4/spec/cli_spec.rb +56 -0
  131. data/vendor/bundle/ruby/3.4.0/gems/emot-0.0.4/spec/emot_spec.rb +50 -0
  132. data/vendor/bundle/ruby/3.4.0/gems/emot-0.0.4/spec/spec_helper.rb +2 -0
  133. data/vendor/bundle/ruby/3.4.0/gems/fastimage-2.4.1/MIT-LICENSE +20 -0
  134. data/vendor/bundle/ruby/3.4.0/gems/fastimage-2.4.1/README.md +209 -0
  135. data/vendor/bundle/ruby/3.4.0/gems/fastimage-2.4.1/lib/fastimage/fastimage.rb +471 -0
  136. data/vendor/bundle/ruby/3.4.0/gems/fastimage-2.4.1/lib/fastimage/fastimage_parsing/avif.rb +12 -0
  137. data/vendor/bundle/ruby/3.4.0/gems/fastimage-2.4.1/lib/fastimage/fastimage_parsing/bmp.rb +17 -0
  138. data/vendor/bundle/ruby/3.4.0/gems/fastimage-2.4.1/lib/fastimage/fastimage_parsing/exif.rb +76 -0
  139. data/vendor/bundle/ruby/3.4.0/gems/fastimage-2.4.1/lib/fastimage/fastimage_parsing/fiber_stream.rb +58 -0
  140. data/vendor/bundle/ruby/3.4.0/gems/fastimage-2.4.1/lib/fastimage/fastimage_parsing/gif.rb +63 -0
  141. data/vendor/bundle/ruby/3.4.0/gems/fastimage-2.4.1/lib/fastimage/fastimage_parsing/heic.rb +8 -0
  142. data/vendor/bundle/ruby/3.4.0/gems/fastimage-2.4.1/lib/fastimage/fastimage_parsing/ico.rb +9 -0
  143. data/vendor/bundle/ruby/3.4.0/gems/fastimage-2.4.1/lib/fastimage/fastimage_parsing/image_base.rb +17 -0
  144. data/vendor/bundle/ruby/3.4.0/gems/fastimage-2.4.1/lib/fastimage/fastimage_parsing/iso_bmff.rb +176 -0
  145. data/vendor/bundle/ruby/3.4.0/gems/fastimage-2.4.1/lib/fastimage/fastimage_parsing/jpeg.rb +52 -0
  146. data/vendor/bundle/ruby/3.4.0/gems/fastimage-2.4.1/lib/fastimage/fastimage_parsing/jxl.rb +13 -0
  147. data/vendor/bundle/ruby/3.4.0/gems/fastimage-2.4.1/lib/fastimage/fastimage_parsing/jxlc.rb +75 -0
  148. data/vendor/bundle/ruby/3.4.0/gems/fastimage-2.4.1/lib/fastimage/fastimage_parsing/png.rb +26 -0
  149. data/vendor/bundle/ruby/3.4.0/gems/fastimage-2.4.1/lib/fastimage/fastimage_parsing/psd.rb +7 -0
  150. data/vendor/bundle/ruby/3.4.0/gems/fastimage-2.4.1/lib/fastimage/fastimage_parsing/stream_util.rb +19 -0
  151. data/vendor/bundle/ruby/3.4.0/gems/fastimage-2.4.1/lib/fastimage/fastimage_parsing/svg.rb +69 -0
  152. data/vendor/bundle/ruby/3.4.0/gems/fastimage-2.4.1/lib/fastimage/fastimage_parsing/tiff.rb +16 -0
  153. data/vendor/bundle/ruby/3.4.0/gems/fastimage-2.4.1/lib/fastimage/fastimage_parsing/type_parser.rb +74 -0
  154. data/vendor/bundle/ruby/3.4.0/gems/fastimage-2.4.1/lib/fastimage/fastimage_parsing/webp.rb +60 -0
  155. data/vendor/bundle/ruby/3.4.0/gems/fastimage-2.4.1/lib/fastimage/version.rb +5 -0
  156. data/vendor/bundle/ruby/3.4.0/gems/fastimage-2.4.1/lib/fastimage.rb +73 -0
  157. data/vendor/bundle/ruby/3.4.0/gems/hikidoc-0.1.1/COPYING +28 -0
  158. data/vendor/bundle/ruby/3.4.0/gems/hikidoc-0.1.1/Gemfile +4 -0
  159. data/vendor/bundle/ruby/3.4.0/gems/hikidoc-0.1.1/NEWS +36 -0
  160. data/vendor/bundle/ruby/3.4.0/gems/hikidoc-0.1.1/NEWS.ja +36 -0
  161. data/vendor/bundle/ruby/3.4.0/gems/hikidoc-0.1.1/README +95 -0
  162. data/vendor/bundle/ruby/3.4.0/gems/hikidoc-0.1.1/README.ja +92 -0
  163. data/vendor/bundle/ruby/3.4.0/gems/hikidoc-0.1.1/README.ja.md +112 -0
  164. data/vendor/bundle/ruby/3.4.0/gems/hikidoc-0.1.1/README.md +114 -0
  165. data/vendor/bundle/ruby/3.4.0/gems/hikidoc-0.1.1/Rakefile +18 -0
  166. data/vendor/bundle/ruby/3.4.0/gems/hikidoc-0.1.1/TextFormattingRules +320 -0
  167. data/vendor/bundle/ruby/3.4.0/gems/hikidoc-0.1.1/TextFormattingRules.ja +318 -0
  168. data/vendor/bundle/ruby/3.4.0/gems/hikidoc-0.1.1/TextFormattingRules.ja.md +385 -0
  169. data/vendor/bundle/ruby/3.4.0/gems/hikidoc-0.1.1/TextFormattingRules.md +388 -0
  170. data/vendor/bundle/ruby/3.4.0/gems/hikidoc-0.1.1/bin/hikidoc +70 -0
  171. data/vendor/bundle/ruby/3.4.0/gems/hikidoc-0.1.1/hikidoc.gemspec +24 -0
  172. data/vendor/bundle/ruby/3.4.0/gems/hikidoc-0.1.1/lib/hikidoc.rb +912 -0
  173. data/vendor/bundle/ruby/3.4.0/gems/hikidoc-0.1.1/test/hikidoc_test.rb +514 -0
  174. data/vendor/bundle/ruby/3.4.0/gems/logger-1.7.0/BSDL +22 -0
  175. data/vendor/bundle/ruby/3.4.0/gems/logger-1.7.0/COPYING +56 -0
  176. data/vendor/bundle/ruby/3.4.0/gems/logger-1.7.0/README.md +104 -0
  177. data/vendor/bundle/ruby/3.4.0/gems/logger-1.7.0/lib/logger/errors.rb +9 -0
  178. data/vendor/bundle/ruby/3.4.0/gems/logger-1.7.0/lib/logger/formatter.rb +36 -0
  179. data/vendor/bundle/ruby/3.4.0/gems/logger-1.7.0/lib/logger/log_device.rb +265 -0
  180. data/vendor/bundle/ruby/3.4.0/gems/logger-1.7.0/lib/logger/period.rb +47 -0
  181. data/vendor/bundle/ruby/3.4.0/gems/logger-1.7.0/lib/logger/severity.rb +38 -0
  182. data/vendor/bundle/ruby/3.4.0/gems/logger-1.7.0/lib/logger/version.rb +5 -0
  183. data/vendor/bundle/ruby/3.4.0/gems/logger-1.7.0/lib/logger.rb +789 -0
  184. data/vendor/bundle/ruby/3.4.0/gems/mail-2.9.1/MIT-LICENSE +20 -0
  185. data/vendor/bundle/ruby/3.4.0/gems/mail-2.9.1/README.md +771 -0
  186. data/vendor/bundle/ruby/3.4.0/gems/mail-2.9.1/lib/mail/attachments_list.rb +109 -0
  187. data/vendor/bundle/ruby/3.4.0/gems/mail-2.9.1/lib/mail/body.rb +305 -0
  188. data/vendor/bundle/ruby/3.4.0/gems/mail-2.9.1/lib/mail/configuration.rb +78 -0
  189. data/vendor/bundle/ruby/3.4.0/gems/mail-2.9.1/lib/mail/constants.rb +79 -0
  190. data/vendor/bundle/ruby/3.4.0/gems/mail-2.9.1/lib/mail/elements/address.rb +258 -0
  191. data/vendor/bundle/ruby/3.4.0/gems/mail-2.9.1/lib/mail/elements/address_list.rb +34 -0
  192. data/vendor/bundle/ruby/3.4.0/gems/mail-2.9.1/lib/mail/elements/content_disposition_element.rb +20 -0
  193. data/vendor/bundle/ruby/3.4.0/gems/mail-2.9.1/lib/mail/elements/content_location_element.rb +17 -0
  194. data/vendor/bundle/ruby/3.4.0/gems/mail-2.9.1/lib/mail/elements/content_transfer_encoding_element.rb +13 -0
  195. data/vendor/bundle/ruby/3.4.0/gems/mail-2.9.1/lib/mail/elements/content_type_element.rb +25 -0
  196. data/vendor/bundle/ruby/3.4.0/gems/mail-2.9.1/lib/mail/elements/date_time_element.rb +15 -0
  197. data/vendor/bundle/ruby/3.4.0/gems/mail-2.9.1/lib/mail/elements/envelope_from_element.rb +39 -0
  198. data/vendor/bundle/ruby/3.4.0/gems/mail-2.9.1/lib/mail/elements/message_ids_element.rb +31 -0
  199. data/vendor/bundle/ruby/3.4.0/gems/mail-2.9.1/lib/mail/elements/mime_version_element.rb +15 -0
  200. data/vendor/bundle/ruby/3.4.0/gems/mail-2.9.1/lib/mail/elements/phrase_list.rb +19 -0
  201. data/vendor/bundle/ruby/3.4.0/gems/mail-2.9.1/lib/mail/elements/received_element.rb +35 -0
  202. data/vendor/bundle/ruby/3.4.0/gems/mail-2.9.1/lib/mail/elements.rb +15 -0
  203. data/vendor/bundle/ruby/3.4.0/gems/mail-2.9.1/lib/mail/encodings/7bit.rb +27 -0
  204. data/vendor/bundle/ruby/3.4.0/gems/mail-2.9.1/lib/mail/encodings/8bit.rb +18 -0
  205. data/vendor/bundle/ruby/3.4.0/gems/mail-2.9.1/lib/mail/encodings/base64.rb +38 -0
  206. data/vendor/bundle/ruby/3.4.0/gems/mail-2.9.1/lib/mail/encodings/binary.rb +13 -0
  207. data/vendor/bundle/ruby/3.4.0/gems/mail-2.9.1/lib/mail/encodings/identity.rb +24 -0
  208. data/vendor/bundle/ruby/3.4.0/gems/mail-2.9.1/lib/mail/encodings/quoted_printable.rb +45 -0
  209. data/vendor/bundle/ruby/3.4.0/gems/mail-2.9.1/lib/mail/encodings/transfer_encoding.rb +77 -0
  210. data/vendor/bundle/ruby/3.4.0/gems/mail-2.9.1/lib/mail/encodings/unix_to_unix.rb +20 -0
  211. data/vendor/bundle/ruby/3.4.0/gems/mail-2.9.1/lib/mail/encodings.rb +314 -0
  212. data/vendor/bundle/ruby/3.4.0/gems/mail-2.9.1/lib/mail/envelope.rb +28 -0
  213. data/vendor/bundle/ruby/3.4.0/gems/mail-2.9.1/lib/mail/field.rb +313 -0
  214. data/vendor/bundle/ruby/3.4.0/gems/mail-2.9.1/lib/mail/field_list.rb +87 -0
  215. data/vendor/bundle/ruby/3.4.0/gems/mail-2.9.1/lib/mail/fields/bcc_field.rb +49 -0
  216. data/vendor/bundle/ruby/3.4.0/gems/mail-2.9.1/lib/mail/fields/cc_field.rb +33 -0
  217. data/vendor/bundle/ruby/3.4.0/gems/mail-2.9.1/lib/mail/fields/comments_field.rb +31 -0
  218. data/vendor/bundle/ruby/3.4.0/gems/mail-2.9.1/lib/mail/fields/common_address_field.rb +162 -0
  219. data/vendor/bundle/ruby/3.4.0/gems/mail-2.9.1/lib/mail/fields/common_date_field.rb +56 -0
  220. data/vendor/bundle/ruby/3.4.0/gems/mail-2.9.1/lib/mail/fields/common_field.rb +77 -0
  221. data/vendor/bundle/ruby/3.4.0/gems/mail-2.9.1/lib/mail/fields/common_message_id_field.rb +41 -0
  222. data/vendor/bundle/ruby/3.4.0/gems/mail-2.9.1/lib/mail/fields/content_description_field.rb +12 -0
  223. data/vendor/bundle/ruby/3.4.0/gems/mail-2.9.1/lib/mail/fields/content_disposition_field.rb +44 -0
  224. data/vendor/bundle/ruby/3.4.0/gems/mail-2.9.1/lib/mail/fields/content_id_field.rb +35 -0
  225. data/vendor/bundle/ruby/3.4.0/gems/mail-2.9.1/lib/mail/fields/content_location_field.rb +28 -0
  226. data/vendor/bundle/ruby/3.4.0/gems/mail-2.9.1/lib/mail/fields/content_transfer_encoding_field.rb +44 -0
  227. data/vendor/bundle/ruby/3.4.0/gems/mail-2.9.1/lib/mail/fields/content_type_field.rb +171 -0
  228. data/vendor/bundle/ruby/3.4.0/gems/mail-2.9.1/lib/mail/fields/date_field.rb +28 -0
  229. data/vendor/bundle/ruby/3.4.0/gems/mail-2.9.1/lib/mail/fields/from_field.rb +33 -0
  230. data/vendor/bundle/ruby/3.4.0/gems/mail-2.9.1/lib/mail/fields/in_reply_to_field.rb +45 -0
  231. data/vendor/bundle/ruby/3.4.0/gems/mail-2.9.1/lib/mail/fields/keywords_field.rb +30 -0
  232. data/vendor/bundle/ruby/3.4.0/gems/mail-2.9.1/lib/mail/fields/message_id_field.rb +36 -0
  233. data/vendor/bundle/ruby/3.4.0/gems/mail-2.9.1/lib/mail/fields/mime_version_field.rb +42 -0
  234. data/vendor/bundle/ruby/3.4.0/gems/mail-2.9.1/lib/mail/fields/named_structured_field.rb +10 -0
  235. data/vendor/bundle/ruby/3.4.0/gems/mail-2.9.1/lib/mail/fields/named_unstructured_field.rb +10 -0
  236. data/vendor/bundle/ruby/3.4.0/gems/mail-2.9.1/lib/mail/fields/optional_field.rb +15 -0
  237. data/vendor/bundle/ruby/3.4.0/gems/mail-2.9.1/lib/mail/fields/parameter_hash.rb +61 -0
  238. data/vendor/bundle/ruby/3.4.0/gems/mail-2.9.1/lib/mail/fields/received_field.rb +61 -0
  239. data/vendor/bundle/ruby/3.4.0/gems/mail-2.9.1/lib/mail/fields/references_field.rb +42 -0
  240. data/vendor/bundle/ruby/3.4.0/gems/mail-2.9.1/lib/mail/fields/reply_to_field.rb +33 -0
  241. data/vendor/bundle/ruby/3.4.0/gems/mail-2.9.1/lib/mail/fields/resent_bcc_field.rb +33 -0
  242. data/vendor/bundle/ruby/3.4.0/gems/mail-2.9.1/lib/mail/fields/resent_cc_field.rb +33 -0
  243. data/vendor/bundle/ruby/3.4.0/gems/mail-2.9.1/lib/mail/fields/resent_date_field.rb +10 -0
  244. data/vendor/bundle/ruby/3.4.0/gems/mail-2.9.1/lib/mail/fields/resent_from_field.rb +33 -0
  245. data/vendor/bundle/ruby/3.4.0/gems/mail-2.9.1/lib/mail/fields/resent_message_id_field.rb +10 -0
  246. data/vendor/bundle/ruby/3.4.0/gems/mail-2.9.1/lib/mail/fields/resent_sender_field.rb +32 -0
  247. data/vendor/bundle/ruby/3.4.0/gems/mail-2.9.1/lib/mail/fields/resent_to_field.rb +33 -0
  248. data/vendor/bundle/ruby/3.4.0/gems/mail-2.9.1/lib/mail/fields/return_path_field.rb +60 -0
  249. data/vendor/bundle/ruby/3.4.0/gems/mail-2.9.1/lib/mail/fields/sender_field.rb +45 -0
  250. data/vendor/bundle/ruby/3.4.0/gems/mail-2.9.1/lib/mail/fields/structured_field.rb +24 -0
  251. data/vendor/bundle/ruby/3.4.0/gems/mail-2.9.1/lib/mail/fields/subject_field.rb +14 -0
  252. data/vendor/bundle/ruby/3.4.0/gems/mail-2.9.1/lib/mail/fields/to_field.rb +33 -0
  253. data/vendor/bundle/ruby/3.4.0/gems/mail-2.9.1/lib/mail/fields/unstructured_field.rb +189 -0
  254. data/vendor/bundle/ruby/3.4.0/gems/mail-2.9.1/lib/mail/fields.rb +45 -0
  255. data/vendor/bundle/ruby/3.4.0/gems/mail-2.9.1/lib/mail/header.rb +237 -0
  256. data/vendor/bundle/ruby/3.4.0/gems/mail-2.9.1/lib/mail/indifferent_hash.rb +147 -0
  257. data/vendor/bundle/ruby/3.4.0/gems/mail-2.9.1/lib/mail/mail.rb +267 -0
  258. data/vendor/bundle/ruby/3.4.0/gems/mail-2.9.1/lib/mail/matchers/attachment_matchers.rb +44 -0
  259. data/vendor/bundle/ruby/3.4.0/gems/mail-2.9.1/lib/mail/matchers/has_sent_mail.rb +201 -0
  260. data/vendor/bundle/ruby/3.4.0/gems/mail-2.9.1/lib/mail/message.rb +2159 -0
  261. data/vendor/bundle/ruby/3.4.0/gems/mail-2.9.1/lib/mail/multibyte/chars.rb +318 -0
  262. data/vendor/bundle/ruby/3.4.0/gems/mail-2.9.1/lib/mail/multibyte/unicode.rb +405 -0
  263. data/vendor/bundle/ruby/3.4.0/gems/mail-2.9.1/lib/mail/multibyte/utils.rb +44 -0
  264. data/vendor/bundle/ruby/3.4.0/gems/mail-2.9.1/lib/mail/multibyte.rb +82 -0
  265. data/vendor/bundle/ruby/3.4.0/gems/mail-2.9.1/lib/mail/network/delivery_methods/exim.rb +50 -0
  266. data/vendor/bundle/ruby/3.4.0/gems/mail-2.9.1/lib/mail/network/delivery_methods/file_delivery.rb +43 -0
  267. data/vendor/bundle/ruby/3.4.0/gems/mail-2.9.1/lib/mail/network/delivery_methods/logger_delivery.rb +34 -0
  268. data/vendor/bundle/ruby/3.4.0/gems/mail-2.9.1/lib/mail/network/delivery_methods/sendmail.rb +87 -0
  269. data/vendor/bundle/ruby/3.4.0/gems/mail-2.9.1/lib/mail/network/delivery_methods/smtp.rb +200 -0
  270. data/vendor/bundle/ruby/3.4.0/gems/mail-2.9.1/lib/mail/network/delivery_methods/smtp_connection.rb +57 -0
  271. data/vendor/bundle/ruby/3.4.0/gems/mail-2.9.1/lib/mail/network/delivery_methods/test_mailer.rb +44 -0
  272. data/vendor/bundle/ruby/3.4.0/gems/mail-2.9.1/lib/mail/network/retriever_methods/base.rb +64 -0
  273. data/vendor/bundle/ruby/3.4.0/gems/mail-2.9.1/lib/mail/network/retriever_methods/imap.rb +190 -0
  274. data/vendor/bundle/ruby/3.4.0/gems/mail-2.9.1/lib/mail/network/retriever_methods/pop3.rb +143 -0
  275. data/vendor/bundle/ruby/3.4.0/gems/mail-2.9.1/lib/mail/network/retriever_methods/test_retriever.rb +45 -0
  276. data/vendor/bundle/ruby/3.4.0/gems/mail-2.9.1/lib/mail/network.rb +16 -0
  277. data/vendor/bundle/ruby/3.4.0/gems/mail-2.9.1/lib/mail/parser_tools.rb +15 -0
  278. data/vendor/bundle/ruby/3.4.0/gems/mail-2.9.1/lib/mail/parsers/address_lists_parser.rb +33245 -0
  279. data/vendor/bundle/ruby/3.4.0/gems/mail-2.9.1/lib/mail/parsers/address_lists_parser.rl +183 -0
  280. data/vendor/bundle/ruby/3.4.0/gems/mail-2.9.1/lib/mail/parsers/content_disposition_parser.rb +904 -0
  281. data/vendor/bundle/ruby/3.4.0/gems/mail-2.9.1/lib/mail/parsers/content_disposition_parser.rl +93 -0
  282. data/vendor/bundle/ruby/3.4.0/gems/mail-2.9.1/lib/mail/parsers/content_location_parser.rb +825 -0
  283. data/vendor/bundle/ruby/3.4.0/gems/mail-2.9.1/lib/mail/parsers/content_location_parser.rl +82 -0
  284. data/vendor/bundle/ruby/3.4.0/gems/mail-2.9.1/lib/mail/parsers/content_transfer_encoding_parser.rb +525 -0
  285. data/vendor/bundle/ruby/3.4.0/gems/mail-2.9.1/lib/mail/parsers/content_transfer_encoding_parser.rl +75 -0
  286. data/vendor/bundle/ruby/3.4.0/gems/mail-2.9.1/lib/mail/parsers/content_type_parser.rb +1051 -0
  287. data/vendor/bundle/ruby/3.4.0/gems/mail-2.9.1/lib/mail/parsers/content_type_parser.rl +94 -0
  288. data/vendor/bundle/ruby/3.4.0/gems/mail-2.9.1/lib/mail/parsers/date_time_parser.rb +894 -0
  289. data/vendor/bundle/ruby/3.4.0/gems/mail-2.9.1/lib/mail/parsers/date_time_parser.rl +73 -0
  290. data/vendor/bundle/ruby/3.4.0/gems/mail-2.9.1/lib/mail/parsers/envelope_from_parser.rb +3678 -0
  291. data/vendor/bundle/ruby/3.4.0/gems/mail-2.9.1/lib/mail/parsers/envelope_from_parser.rl +93 -0
  292. data/vendor/bundle/ruby/3.4.0/gems/mail-2.9.1/lib/mail/parsers/message_ids_parser.rb +5164 -0
  293. data/vendor/bundle/ruby/3.4.0/gems/mail-2.9.1/lib/mail/parsers/message_ids_parser.rl +97 -0
  294. data/vendor/bundle/ruby/3.4.0/gems/mail-2.9.1/lib/mail/parsers/mime_version_parser.rb +516 -0
  295. data/vendor/bundle/ruby/3.4.0/gems/mail-2.9.1/lib/mail/parsers/mime_version_parser.rl +72 -0
  296. data/vendor/bundle/ruby/3.4.0/gems/mail-2.9.1/lib/mail/parsers/phrase_lists_parser.rb +887 -0
  297. data/vendor/bundle/ruby/3.4.0/gems/mail-2.9.1/lib/mail/parsers/phrase_lists_parser.rl +94 -0
  298. data/vendor/bundle/ruby/3.4.0/gems/mail-2.9.1/lib/mail/parsers/received_parser.rb +8785 -0
  299. data/vendor/bundle/ruby/3.4.0/gems/mail-2.9.1/lib/mail/parsers/received_parser.rl +95 -0
  300. data/vendor/bundle/ruby/3.4.0/gems/mail-2.9.1/lib/mail/parsers/rfc2045_content_transfer_encoding.rl +13 -0
  301. data/vendor/bundle/ruby/3.4.0/gems/mail-2.9.1/lib/mail/parsers/rfc2045_content_type.rl +25 -0
  302. data/vendor/bundle/ruby/3.4.0/gems/mail-2.9.1/lib/mail/parsers/rfc2045_mime.rl +16 -0
  303. data/vendor/bundle/ruby/3.4.0/gems/mail-2.9.1/lib/mail/parsers/rfc2183_content_disposition.rl +15 -0
  304. data/vendor/bundle/ruby/3.4.0/gems/mail-2.9.1/lib/mail/parsers/rfc3629_utf8.rl +19 -0
  305. data/vendor/bundle/ruby/3.4.0/gems/mail-2.9.1/lib/mail/parsers/rfc5234_abnf_core_rules.rl +22 -0
  306. data/vendor/bundle/ruby/3.4.0/gems/mail-2.9.1/lib/mail/parsers/rfc5322.rl +74 -0
  307. data/vendor/bundle/ruby/3.4.0/gems/mail-2.9.1/lib/mail/parsers/rfc5322_address.rl +72 -0
  308. data/vendor/bundle/ruby/3.4.0/gems/mail-2.9.1/lib/mail/parsers/rfc5322_date_time.rl +37 -0
  309. data/vendor/bundle/ruby/3.4.0/gems/mail-2.9.1/lib/mail/parsers/rfc5322_lexical_tokens.rl +60 -0
  310. data/vendor/bundle/ruby/3.4.0/gems/mail-2.9.1/lib/mail/parsers.rb +13 -0
  311. data/vendor/bundle/ruby/3.4.0/gems/mail-2.9.1/lib/mail/part.rb +119 -0
  312. data/vendor/bundle/ruby/3.4.0/gems/mail-2.9.1/lib/mail/parts_list.rb +131 -0
  313. data/vendor/bundle/ruby/3.4.0/gems/mail-2.9.1/lib/mail/smtp_envelope.rb +57 -0
  314. data/vendor/bundle/ruby/3.4.0/gems/mail-2.9.1/lib/mail/utilities.rb +576 -0
  315. data/vendor/bundle/ruby/3.4.0/gems/mail-2.9.1/lib/mail/values/unicode_tables.dat +0 -0
  316. data/vendor/bundle/ruby/3.4.0/gems/mail-2.9.1/lib/mail/version.rb +17 -0
  317. data/vendor/bundle/ruby/3.4.0/gems/mail-2.9.1/lib/mail/yaml.rb +30 -0
  318. data/vendor/bundle/ruby/3.4.0/gems/mail-2.9.1/lib/mail.rb +65 -0
  319. data/vendor/bundle/ruby/3.4.0/gems/mini_mime-1.1.5/CHANGELOG +65 -0
  320. data/vendor/bundle/ruby/3.4.0/gems/mini_mime-1.1.5/CODE_OF_CONDUCT.md +74 -0
  321. data/vendor/bundle/ruby/3.4.0/gems/mini_mime-1.1.5/Gemfile +9 -0
  322. data/vendor/bundle/ruby/3.4.0/gems/mini_mime-1.1.5/LICENSE.txt +21 -0
  323. data/vendor/bundle/ruby/3.4.0/gems/mini_mime-1.1.5/README.md +114 -0
  324. data/vendor/bundle/ruby/3.4.0/gems/mini_mime-1.1.5/Rakefile +97 -0
  325. data/vendor/bundle/ruby/3.4.0/gems/mini_mime-1.1.5/bench/bench.rb +51 -0
  326. data/vendor/bundle/ruby/3.4.0/gems/mini_mime-1.1.5/bin/console +15 -0
  327. data/vendor/bundle/ruby/3.4.0/gems/mini_mime-1.1.5/bin/db_pull_request +20 -0
  328. data/vendor/bundle/ruby/3.4.0/gems/mini_mime-1.1.5/bin/setup +8 -0
  329. data/vendor/bundle/ruby/3.4.0/gems/mini_mime-1.1.5/lib/db/content_type_mime.db +880 -0
  330. data/vendor/bundle/ruby/3.4.0/gems/mini_mime-1.1.5/lib/db/ext_mime.db +1201 -0
  331. data/vendor/bundle/ruby/3.4.0/gems/mini_mime-1.1.5/lib/mini_mime/version.rb +4 -0
  332. data/vendor/bundle/ruby/3.4.0/gems/mini_mime-1.1.5/lib/mini_mime.rb +186 -0
  333. data/vendor/bundle/ruby/3.4.0/gems/mini_mime-1.1.5/mini_mime.gemspec +31 -0
  334. data/vendor/bundle/ruby/3.4.0/gems/net-imap-0.5.15/BSDL +22 -0
  335. data/vendor/bundle/ruby/3.4.0/gems/net-imap-0.5.15/COPYING +56 -0
  336. data/vendor/bundle/ruby/3.4.0/gems/net-imap-0.5.15/Gemfile +25 -0
  337. data/vendor/bundle/ruby/3.4.0/gems/net-imap-0.5.15/LICENSE.txt +65 -0
  338. data/vendor/bundle/ruby/3.4.0/gems/net-imap-0.5.15/README.md +77 -0
  339. data/vendor/bundle/ruby/3.4.0/gems/net-imap-0.5.15/Rakefile +13 -0
  340. data/vendor/bundle/ruby/3.4.0/gems/net-imap-0.5.15/docs/styles.css +85 -0
  341. data/vendor/bundle/ruby/3.4.0/gems/net-imap-0.5.15/lib/net/imap/authenticators.rb +37 -0
  342. data/vendor/bundle/ruby/3.4.0/gems/net-imap-0.5.15/lib/net/imap/command_data.rb +507 -0
  343. data/vendor/bundle/ruby/3.4.0/gems/net-imap-0.5.15/lib/net/imap/config/attr_accessors.rb +75 -0
  344. data/vendor/bundle/ruby/3.4.0/gems/net-imap-0.5.15/lib/net/imap/config/attr_inheritance.rb +90 -0
  345. data/vendor/bundle/ruby/3.4.0/gems/net-imap-0.5.15/lib/net/imap/config/attr_type_coercion.rb +74 -0
  346. data/vendor/bundle/ruby/3.4.0/gems/net-imap-0.5.15/lib/net/imap/config/attr_version_defaults.rb +93 -0
  347. data/vendor/bundle/ruby/3.4.0/gems/net-imap-0.5.15/lib/net/imap/config.rb +500 -0
  348. data/vendor/bundle/ruby/3.4.0/gems/net-imap-0.5.15/lib/net/imap/connection_state.rb +48 -0
  349. data/vendor/bundle/ruby/3.4.0/gems/net-imap-0.5.15/lib/net/imap/data_encoding.rb +214 -0
  350. data/vendor/bundle/ruby/3.4.0/gems/net-imap-0.5.15/lib/net/imap/data_lite.rb +226 -0
  351. data/vendor/bundle/ruby/3.4.0/gems/net-imap-0.5.15/lib/net/imap/deprecated_client_options.rb +142 -0
  352. data/vendor/bundle/ruby/3.4.0/gems/net-imap-0.5.15/lib/net/imap/errors.rb +118 -0
  353. data/vendor/bundle/ruby/3.4.0/gems/net-imap-0.5.15/lib/net/imap/esearch_result.rb +219 -0
  354. data/vendor/bundle/ruby/3.4.0/gems/net-imap-0.5.15/lib/net/imap/fetch_data.rb +597 -0
  355. data/vendor/bundle/ruby/3.4.0/gems/net-imap-0.5.15/lib/net/imap/flags.rb +262 -0
  356. data/vendor/bundle/ruby/3.4.0/gems/net-imap-0.5.15/lib/net/imap/response_data.rb +1113 -0
  357. data/vendor/bundle/ruby/3.4.0/gems/net-imap-0.5.15/lib/net/imap/response_parser/parser_utils.rb +245 -0
  358. data/vendor/bundle/ruby/3.4.0/gems/net-imap-0.5.15/lib/net/imap/response_parser.rb +2282 -0
  359. data/vendor/bundle/ruby/3.4.0/gems/net-imap-0.5.15/lib/net/imap/response_reader.rb +92 -0
  360. data/vendor/bundle/ruby/3.4.0/gems/net-imap-0.5.15/lib/net/imap/sasl/anonymous_authenticator.rb +69 -0
  361. data/vendor/bundle/ruby/3.4.0/gems/net-imap-0.5.15/lib/net/imap/sasl/authentication_exchange.rb +139 -0
  362. data/vendor/bundle/ruby/3.4.0/gems/net-imap-0.5.15/lib/net/imap/sasl/authenticators.rb +122 -0
  363. data/vendor/bundle/ruby/3.4.0/gems/net-imap-0.5.15/lib/net/imap/sasl/client_adapter.rb +123 -0
  364. data/vendor/bundle/ruby/3.4.0/gems/net-imap-0.5.15/lib/net/imap/sasl/cram_md5_authenticator.rb +61 -0
  365. data/vendor/bundle/ruby/3.4.0/gems/net-imap-0.5.15/lib/net/imap/sasl/digest_md5_authenticator.rb +342 -0
  366. data/vendor/bundle/ruby/3.4.0/gems/net-imap-0.5.15/lib/net/imap/sasl/external_authenticator.rb +83 -0
  367. data/vendor/bundle/ruby/3.4.0/gems/net-imap-0.5.15/lib/net/imap/sasl/gs2_header.rb +80 -0
  368. data/vendor/bundle/ruby/3.4.0/gems/net-imap-0.5.15/lib/net/imap/sasl/login_authenticator.rb +56 -0
  369. data/vendor/bundle/ruby/3.4.0/gems/net-imap-0.5.15/lib/net/imap/sasl/oauthbearer_authenticator.rb +199 -0
  370. data/vendor/bundle/ruby/3.4.0/gems/net-imap-0.5.15/lib/net/imap/sasl/plain_authenticator.rb +101 -0
  371. data/vendor/bundle/ruby/3.4.0/gems/net-imap-0.5.15/lib/net/imap/sasl/protocol_adapters.rb +101 -0
  372. data/vendor/bundle/ruby/3.4.0/gems/net-imap-0.5.15/lib/net/imap/sasl/scram_algorithm.rb +58 -0
  373. data/vendor/bundle/ruby/3.4.0/gems/net-imap-0.5.15/lib/net/imap/sasl/scram_authenticator.rb +361 -0
  374. data/vendor/bundle/ruby/3.4.0/gems/net-imap-0.5.15/lib/net/imap/sasl/stringprep.rb +12 -0
  375. data/vendor/bundle/ruby/3.4.0/gems/net-imap-0.5.15/lib/net/imap/sasl/xoauth2_authenticator.rb +106 -0
  376. data/vendor/bundle/ruby/3.4.0/gems/net-imap-0.5.15/lib/net/imap/sasl.rb +182 -0
  377. data/vendor/bundle/ruby/3.4.0/gems/net-imap-0.5.15/lib/net/imap/sasl_adapter.rb +20 -0
  378. data/vendor/bundle/ruby/3.4.0/gems/net-imap-0.5.15/lib/net/imap/search_result.rb +145 -0
  379. data/vendor/bundle/ruby/3.4.0/gems/net-imap-0.5.15/lib/net/imap/sequence_set.rb +1952 -0
  380. data/vendor/bundle/ruby/3.4.0/gems/net-imap-0.5.15/lib/net/imap/stringprep/nameprep.rb +70 -0
  381. data/vendor/bundle/ruby/3.4.0/gems/net-imap-0.5.15/lib/net/imap/stringprep/saslprep.rb +69 -0
  382. data/vendor/bundle/ruby/3.4.0/gems/net-imap-0.5.15/lib/net/imap/stringprep/saslprep_tables.rb +96 -0
  383. data/vendor/bundle/ruby/3.4.0/gems/net-imap-0.5.15/lib/net/imap/stringprep/tables.rb +146 -0
  384. data/vendor/bundle/ruby/3.4.0/gems/net-imap-0.5.15/lib/net/imap/stringprep/trace.rb +85 -0
  385. data/vendor/bundle/ruby/3.4.0/gems/net-imap-0.5.15/lib/net/imap/stringprep.rb +159 -0
  386. data/vendor/bundle/ruby/3.4.0/gems/net-imap-0.5.15/lib/net/imap/uidplus_data.rb +244 -0
  387. data/vendor/bundle/ruby/3.4.0/gems/net-imap-0.5.15/lib/net/imap/vanished_data.rb +65 -0
  388. data/vendor/bundle/ruby/3.4.0/gems/net-imap-0.5.15/lib/net/imap.rb +3968 -0
  389. data/vendor/bundle/ruby/3.4.0/gems/net-imap-0.5.15/net-imap.gemspec +38 -0
  390. data/vendor/bundle/ruby/3.4.0/gems/net-imap-0.5.15/rakelib/benchmarks.rake +91 -0
  391. data/vendor/bundle/ruby/3.4.0/gems/net-imap-0.5.15/rakelib/rdoc.rake +70 -0
  392. data/vendor/bundle/ruby/3.4.0/gems/net-imap-0.5.15/rakelib/rfcs.rake +170 -0
  393. data/vendor/bundle/ruby/3.4.0/gems/net-imap-0.5.15/rakelib/saslprep.rake +30 -0
  394. data/vendor/bundle/ruby/3.4.0/gems/net-imap-0.5.15/rakelib/string_prep_tables_generator.rb +449 -0
  395. data/vendor/bundle/ruby/3.4.0/gems/net-imap-0.5.15/sample/net-imap.rb +167 -0
  396. data/vendor/bundle/ruby/3.4.0/gems/net-pop-0.1.2/Gemfile +7 -0
  397. data/vendor/bundle/ruby/3.4.0/gems/net-pop-0.1.2/LICENSE.txt +22 -0
  398. data/vendor/bundle/ruby/3.4.0/gems/net-pop-0.1.2/README.md +66 -0
  399. data/vendor/bundle/ruby/3.4.0/gems/net-pop-0.1.2/Rakefile +17 -0
  400. data/vendor/bundle/ruby/3.4.0/gems/net-pop-0.1.2/lib/net/pop.rb +1025 -0
  401. data/vendor/bundle/ruby/3.4.0/gems/net-pop-0.1.2/net-pop.gemspec +32 -0
  402. data/vendor/bundle/ruby/3.4.0/gems/net-protocol-0.2.2/Gemfile +7 -0
  403. data/vendor/bundle/ruby/3.4.0/gems/net-protocol-0.2.2/LICENSE.txt +22 -0
  404. data/vendor/bundle/ruby/3.4.0/gems/net-protocol-0.2.2/README.md +29 -0
  405. data/vendor/bundle/ruby/3.4.0/gems/net-protocol-0.2.2/Rakefile +10 -0
  406. data/vendor/bundle/ruby/3.4.0/gems/net-protocol-0.2.2/bin/console +14 -0
  407. data/vendor/bundle/ruby/3.4.0/gems/net-protocol-0.2.2/bin/setup +8 -0
  408. data/vendor/bundle/ruby/3.4.0/gems/net-protocol-0.2.2/lib/net/protocol.rb +544 -0
  409. data/vendor/bundle/ruby/3.4.0/gems/net-protocol-0.2.2/net-protocol.gemspec +33 -0
  410. data/vendor/bundle/ruby/3.4.0/gems/net-smtp-0.5.1/LICENSE.txt +2 -0
  411. data/vendor/bundle/ruby/3.4.0/gems/net-smtp-0.5.1/NEWS.md +133 -0
  412. data/vendor/bundle/ruby/3.4.0/gems/net-smtp-0.5.1/README.md +97 -0
  413. data/vendor/bundle/ruby/3.4.0/gems/net-smtp-0.5.1/lib/net/smtp/auth_cram_md5.rb +48 -0
  414. data/vendor/bundle/ruby/3.4.0/gems/net-smtp-0.5.1/lib/net/smtp/auth_login.rb +11 -0
  415. data/vendor/bundle/ruby/3.4.0/gems/net-smtp-0.5.1/lib/net/smtp/auth_plain.rb +9 -0
  416. data/vendor/bundle/ruby/3.4.0/gems/net-smtp-0.5.1/lib/net/smtp/auth_xoauth2.rb +17 -0
  417. data/vendor/bundle/ruby/3.4.0/gems/net-smtp-0.5.1/lib/net/smtp/authenticator.rb +57 -0
  418. data/vendor/bundle/ruby/3.4.0/gems/net-smtp-0.5.1/lib/net/smtp.rb +1164 -0
  419. data/vendor/bundle/ruby/3.4.0/gems/net-smtp-0.5.1/net-smtp.gemspec +31 -0
  420. data/vendor/bundle/ruby/3.4.0/gems/pstore-0.2.1/BSDL +22 -0
  421. data/vendor/bundle/ruby/3.4.0/gems/pstore-0.2.1/COPYING +56 -0
  422. data/vendor/bundle/ruby/3.4.0/gems/pstore-0.2.1/Gemfile +10 -0
  423. data/vendor/bundle/ruby/3.4.0/gems/pstore-0.2.1/README.md +95 -0
  424. data/vendor/bundle/ruby/3.4.0/gems/pstore-0.2.1/Rakefile +10 -0
  425. data/vendor/bundle/ruby/3.4.0/gems/pstore-0.2.1/bin/console +14 -0
  426. data/vendor/bundle/ruby/3.4.0/gems/pstore-0.2.1/bin/setup +8 -0
  427. data/vendor/bundle/ruby/3.4.0/gems/pstore-0.2.1/lib/pstore.rb +736 -0
  428. data/vendor/bundle/ruby/3.4.0/gems/pstore-0.2.1/pstore.gemspec +32 -0
  429. data/vendor/bundle/ruby/3.4.0/gems/rack-3.2.6/CHANGELOG.md +1346 -0
  430. data/vendor/bundle/ruby/3.4.0/gems/rack-3.2.6/CONTRIBUTING.md +144 -0
  431. data/vendor/bundle/ruby/3.4.0/gems/rack-3.2.6/MIT-LICENSE +20 -0
  432. data/vendor/bundle/ruby/3.4.0/gems/rack-3.2.6/README.md +384 -0
  433. data/vendor/bundle/ruby/3.4.0/gems/rack-3.2.6/SPEC.rdoc +258 -0
  434. data/vendor/bundle/ruby/3.4.0/gems/rack-3.2.6/lib/rack/auth/abstract/handler.rb +41 -0
  435. data/vendor/bundle/ruby/3.4.0/gems/rack-3.2.6/lib/rack/auth/abstract/request.rb +51 -0
  436. data/vendor/bundle/ruby/3.4.0/gems/rack-3.2.6/lib/rack/auth/basic.rb +58 -0
  437. data/vendor/bundle/ruby/3.4.0/gems/rack-3.2.6/lib/rack/bad_request.rb +8 -0
  438. data/vendor/bundle/ruby/3.4.0/gems/rack-3.2.6/lib/rack/body_proxy.rb +63 -0
  439. data/vendor/bundle/ruby/3.4.0/gems/rack-3.2.6/lib/rack/builder.rb +296 -0
  440. data/vendor/bundle/ruby/3.4.0/gems/rack-3.2.6/lib/rack/cascade.rb +67 -0
  441. data/vendor/bundle/ruby/3.4.0/gems/rack-3.2.6/lib/rack/common_logger.rb +89 -0
  442. data/vendor/bundle/ruby/3.4.0/gems/rack-3.2.6/lib/rack/conditional_get.rb +87 -0
  443. data/vendor/bundle/ruby/3.4.0/gems/rack-3.2.6/lib/rack/config.rb +22 -0
  444. data/vendor/bundle/ruby/3.4.0/gems/rack-3.2.6/lib/rack/constants.rb +68 -0
  445. data/vendor/bundle/ruby/3.4.0/gems/rack-3.2.6/lib/rack/content_length.rb +34 -0
  446. data/vendor/bundle/ruby/3.4.0/gems/rack-3.2.6/lib/rack/content_type.rb +33 -0
  447. data/vendor/bundle/ruby/3.4.0/gems/rack-3.2.6/lib/rack/deflater.rb +158 -0
  448. data/vendor/bundle/ruby/3.4.0/gems/rack-3.2.6/lib/rack/directory.rb +208 -0
  449. data/vendor/bundle/ruby/3.4.0/gems/rack-3.2.6/lib/rack/etag.rb +71 -0
  450. data/vendor/bundle/ruby/3.4.0/gems/rack-3.2.6/lib/rack/events.rb +172 -0
  451. data/vendor/bundle/ruby/3.4.0/gems/rack-3.2.6/lib/rack/files.rb +216 -0
  452. data/vendor/bundle/ruby/3.4.0/gems/rack-3.2.6/lib/rack/head.rb +25 -0
  453. data/vendor/bundle/ruby/3.4.0/gems/rack-3.2.6/lib/rack/headers.rb +238 -0
  454. data/vendor/bundle/ruby/3.4.0/gems/rack-3.2.6/lib/rack/lint.rb +964 -0
  455. data/vendor/bundle/ruby/3.4.0/gems/rack-3.2.6/lib/rack/lock.rb +29 -0
  456. data/vendor/bundle/ruby/3.4.0/gems/rack-3.2.6/lib/rack/media_type.rb +52 -0
  457. data/vendor/bundle/ruby/3.4.0/gems/rack-3.2.6/lib/rack/method_override.rb +56 -0
  458. data/vendor/bundle/ruby/3.4.0/gems/rack-3.2.6/lib/rack/mime.rb +694 -0
  459. data/vendor/bundle/ruby/3.4.0/gems/rack-3.2.6/lib/rack/mock.rb +3 -0
  460. data/vendor/bundle/ruby/3.4.0/gems/rack-3.2.6/lib/rack/mock_request.rb +161 -0
  461. data/vendor/bundle/ruby/3.4.0/gems/rack-3.2.6/lib/rack/mock_response.rb +156 -0
  462. data/vendor/bundle/ruby/3.4.0/gems/rack-3.2.6/lib/rack/multipart/generator.rb +99 -0
  463. data/vendor/bundle/ruby/3.4.0/gems/rack-3.2.6/lib/rack/multipart/parser.rb +621 -0
  464. data/vendor/bundle/ruby/3.4.0/gems/rack-3.2.6/lib/rack/multipart/uploaded_file.rb +82 -0
  465. data/vendor/bundle/ruby/3.4.0/gems/rack-3.2.6/lib/rack/multipart.rb +77 -0
  466. data/vendor/bundle/ruby/3.4.0/gems/rack-3.2.6/lib/rack/null_logger.rb +48 -0
  467. data/vendor/bundle/ruby/3.4.0/gems/rack-3.2.6/lib/rack/query_parser.rb +261 -0
  468. data/vendor/bundle/ruby/3.4.0/gems/rack-3.2.6/lib/rack/recursive.rb +66 -0
  469. data/vendor/bundle/ruby/3.4.0/gems/rack-3.2.6/lib/rack/reloader.rb +112 -0
  470. data/vendor/bundle/ruby/3.4.0/gems/rack-3.2.6/lib/rack/request.rb +790 -0
  471. data/vendor/bundle/ruby/3.4.0/gems/rack-3.2.6/lib/rack/response.rb +403 -0
  472. data/vendor/bundle/ruby/3.4.0/gems/rack-3.2.6/lib/rack/rewindable_input.rb +116 -0
  473. data/vendor/bundle/ruby/3.4.0/gems/rack-3.2.6/lib/rack/runtime.rb +35 -0
  474. data/vendor/bundle/ruby/3.4.0/gems/rack-3.2.6/lib/rack/sendfile.rb +197 -0
  475. data/vendor/bundle/ruby/3.4.0/gems/rack-3.2.6/lib/rack/show_exceptions.rb +409 -0
  476. data/vendor/bundle/ruby/3.4.0/gems/rack-3.2.6/lib/rack/show_status.rb +121 -0
  477. data/vendor/bundle/ruby/3.4.0/gems/rack-3.2.6/lib/rack/static.rb +192 -0
  478. data/vendor/bundle/ruby/3.4.0/gems/rack-3.2.6/lib/rack/tempfile_reaper.rb +33 -0
  479. data/vendor/bundle/ruby/3.4.0/gems/rack-3.2.6/lib/rack/urlmap.rb +99 -0
  480. data/vendor/bundle/ruby/3.4.0/gems/rack-3.2.6/lib/rack/utils.rb +714 -0
  481. data/vendor/bundle/ruby/3.4.0/gems/rack-3.2.6/lib/rack/version.rb +17 -0
  482. data/vendor/bundle/ruby/3.4.0/gems/rack-3.2.6/lib/rack.rb +64 -0
  483. data/vendor/bundle/ruby/3.4.0/gems/rack-session-2.1.2/lib/rack/session/abstract/id.rb +535 -0
  484. data/vendor/bundle/ruby/3.4.0/gems/rack-session-2.1.2/lib/rack/session/constants.rb +13 -0
  485. data/vendor/bundle/ruby/3.4.0/gems/rack-session-2.1.2/lib/rack/session/cookie.rb +315 -0
  486. data/vendor/bundle/ruby/3.4.0/gems/rack-session-2.1.2/lib/rack/session/encryptor.rb +415 -0
  487. data/vendor/bundle/ruby/3.4.0/gems/rack-session-2.1.2/lib/rack/session/pool.rb +82 -0
  488. data/vendor/bundle/ruby/3.4.0/gems/rack-session-2.1.2/lib/rack/session/version.rb +10 -0
  489. data/vendor/bundle/ruby/3.4.0/gems/rack-session-2.1.2/lib/rack/session.rb +12 -0
  490. data/vendor/bundle/ruby/3.4.0/gems/rack-session-2.1.2/license.md +72 -0
  491. data/vendor/bundle/ruby/3.4.0/gems/rack-session-2.1.2/readme.md +47 -0
  492. data/vendor/bundle/ruby/3.4.0/gems/rack-session-2.1.2/releases.md +31 -0
  493. data/vendor/bundle/ruby/3.4.0/gems/rack-session-2.1.2/security.md +3 -0
  494. data/vendor/bundle/ruby/3.4.0/gems/rackup-2.3.1/bin/rackup +5 -0
  495. data/vendor/bundle/ruby/3.4.0/gems/rackup-2.3.1/lib/rackup/handler/cgi.rb +61 -0
  496. data/vendor/bundle/ruby/3.4.0/gems/rackup-2.3.1/lib/rackup/handler/webrick.rb +196 -0
  497. data/vendor/bundle/ruby/3.4.0/gems/rackup-2.3.1/lib/rackup/handler.rb +113 -0
  498. data/vendor/bundle/ruby/3.4.0/gems/rackup-2.3.1/lib/rackup/lobster.rb +81 -0
  499. data/vendor/bundle/ruby/3.4.0/gems/rackup-2.3.1/lib/rackup/server.rb +462 -0
  500. data/vendor/bundle/ruby/3.4.0/gems/rackup-2.3.1/lib/rackup/stream.rb +199 -0
  501. data/vendor/bundle/ruby/3.4.0/gems/rackup-2.3.1/lib/rackup/version.rb +8 -0
  502. data/vendor/bundle/ruby/3.4.0/gems/rackup-2.3.1/lib/rackup.rb +21 -0
  503. data/vendor/bundle/ruby/3.4.0/gems/rackup-2.3.1/license.md +80 -0
  504. data/vendor/bundle/ruby/3.4.0/gems/rackup-2.3.1/readme.md +82 -0
  505. data/vendor/bundle/ruby/3.4.0/gems/rackup-2.3.1/releases.md +28 -0
  506. data/vendor/bundle/ruby/3.4.0/gems/rackup-2.3.1/security.md +3 -0
  507. data/vendor/bundle/ruby/3.4.0/gems/rake-13.4.2/History.rdoc +2454 -0
  508. data/vendor/bundle/ruby/3.4.0/gems/rake-13.4.2/MIT-LICENSE +21 -0
  509. data/vendor/bundle/ruby/3.4.0/gems/rake-13.4.2/README.rdoc +155 -0
  510. data/vendor/bundle/ruby/3.4.0/gems/rake-13.4.2/doc/command_line_usage.rdoc +171 -0
  511. data/vendor/bundle/ruby/3.4.0/gems/rake-13.4.2/doc/example/Rakefile1 +38 -0
  512. data/vendor/bundle/ruby/3.4.0/gems/rake-13.4.2/doc/example/Rakefile2 +35 -0
  513. data/vendor/bundle/ruby/3.4.0/gems/rake-13.4.2/doc/example/a.c +6 -0
  514. data/vendor/bundle/ruby/3.4.0/gems/rake-13.4.2/doc/example/b.c +6 -0
  515. data/vendor/bundle/ruby/3.4.0/gems/rake-13.4.2/doc/example/main.c +11 -0
  516. data/vendor/bundle/ruby/3.4.0/gems/rake-13.4.2/doc/glossary.rdoc +42 -0
  517. data/vendor/bundle/ruby/3.4.0/gems/rake-13.4.2/doc/jamis.rb +592 -0
  518. data/vendor/bundle/ruby/3.4.0/gems/rake-13.4.2/doc/proto_rake.rdoc +127 -0
  519. data/vendor/bundle/ruby/3.4.0/gems/rake-13.4.2/doc/rake.1 +156 -0
  520. data/vendor/bundle/ruby/3.4.0/gems/rake-13.4.2/doc/rakefile.rdoc +635 -0
  521. data/vendor/bundle/ruby/3.4.0/gems/rake-13.4.2/doc/rational.rdoc +151 -0
  522. data/vendor/bundle/ruby/3.4.0/gems/rake-13.4.2/exe/rake +27 -0
  523. data/vendor/bundle/ruby/3.4.0/gems/rake-13.4.2/lib/rake/application.rb +847 -0
  524. data/vendor/bundle/ruby/3.4.0/gems/rake-13.4.2/lib/rake/backtrace.rb +25 -0
  525. data/vendor/bundle/ruby/3.4.0/gems/rake-13.4.2/lib/rake/clean.rb +78 -0
  526. data/vendor/bundle/ruby/3.4.0/gems/rake-13.4.2/lib/rake/cloneable.rb +17 -0
  527. data/vendor/bundle/ruby/3.4.0/gems/rake-13.4.2/lib/rake/cpu_counter.rb +122 -0
  528. data/vendor/bundle/ruby/3.4.0/gems/rake-13.4.2/lib/rake/default_loader.rb +15 -0
  529. data/vendor/bundle/ruby/3.4.0/gems/rake-13.4.2/lib/rake/dsl_definition.rb +196 -0
  530. data/vendor/bundle/ruby/3.4.0/gems/rake-13.4.2/lib/rake/early_time.rb +22 -0
  531. data/vendor/bundle/ruby/3.4.0/gems/rake-13.4.2/lib/rake/ext/core.rb +26 -0
  532. data/vendor/bundle/ruby/3.4.0/gems/rake-13.4.2/lib/rake/ext/string.rb +176 -0
  533. data/vendor/bundle/ruby/3.4.0/gems/rake-13.4.2/lib/rake/file_creation_task.rb +25 -0
  534. data/vendor/bundle/ruby/3.4.0/gems/rake-13.4.2/lib/rake/file_list.rb +435 -0
  535. data/vendor/bundle/ruby/3.4.0/gems/rake-13.4.2/lib/rake/file_task.rb +58 -0
  536. data/vendor/bundle/ruby/3.4.0/gems/rake-13.4.2/lib/rake/file_utils.rb +137 -0
  537. data/vendor/bundle/ruby/3.4.0/gems/rake-13.4.2/lib/rake/file_utils_ext.rb +135 -0
  538. data/vendor/bundle/ruby/3.4.0/gems/rake-13.4.2/lib/rake/invocation_chain.rb +57 -0
  539. data/vendor/bundle/ruby/3.4.0/gems/rake-13.4.2/lib/rake/invocation_exception_mixin.rb +17 -0
  540. data/vendor/bundle/ruby/3.4.0/gems/rake-13.4.2/lib/rake/late_time.rb +18 -0
  541. data/vendor/bundle/ruby/3.4.0/gems/rake-13.4.2/lib/rake/linked_list.rb +112 -0
  542. data/vendor/bundle/ruby/3.4.0/gems/rake-13.4.2/lib/rake/loaders/makefile.rb +54 -0
  543. data/vendor/bundle/ruby/3.4.0/gems/rake-13.4.2/lib/rake/multi_task.rb +14 -0
  544. data/vendor/bundle/ruby/3.4.0/gems/rake-13.4.2/lib/rake/name_space.rb +38 -0
  545. data/vendor/bundle/ruby/3.4.0/gems/rake-13.4.2/lib/rake/options.rb +31 -0
  546. data/vendor/bundle/ruby/3.4.0/gems/rake-13.4.2/lib/rake/packagetask.rb +222 -0
  547. data/vendor/bundle/ruby/3.4.0/gems/rake-13.4.2/lib/rake/phony.rb +16 -0
  548. data/vendor/bundle/ruby/3.4.0/gems/rake-13.4.2/lib/rake/private_reader.rb +21 -0
  549. data/vendor/bundle/ruby/3.4.0/gems/rake-13.4.2/lib/rake/promise.rb +100 -0
  550. data/vendor/bundle/ruby/3.4.0/gems/rake-13.4.2/lib/rake/pseudo_status.rb +30 -0
  551. data/vendor/bundle/ruby/3.4.0/gems/rake-13.4.2/lib/rake/rake_module.rb +67 -0
  552. data/vendor/bundle/ruby/3.4.0/gems/rake-13.4.2/lib/rake/rake_test_loader.rb +27 -0
  553. data/vendor/bundle/ruby/3.4.0/gems/rake-13.4.2/lib/rake/rule_recursion_overflow_error.rb +20 -0
  554. data/vendor/bundle/ruby/3.4.0/gems/rake-13.4.2/lib/rake/scope.rb +43 -0
  555. data/vendor/bundle/ruby/3.4.0/gems/rake-13.4.2/lib/rake/task.rb +434 -0
  556. data/vendor/bundle/ruby/3.4.0/gems/rake-13.4.2/lib/rake/task_argument_error.rb +8 -0
  557. data/vendor/bundle/ruby/3.4.0/gems/rake-13.4.2/lib/rake/task_arguments.rb +113 -0
  558. data/vendor/bundle/ruby/3.4.0/gems/rake-13.4.2/lib/rake/task_manager.rb +333 -0
  559. data/vendor/bundle/ruby/3.4.0/gems/rake-13.4.2/lib/rake/tasklib.rb +12 -0
  560. data/vendor/bundle/ruby/3.4.0/gems/rake-13.4.2/lib/rake/testtask.rb +192 -0
  561. data/vendor/bundle/ruby/3.4.0/gems/rake-13.4.2/lib/rake/thread_history_display.rb +49 -0
  562. data/vendor/bundle/ruby/3.4.0/gems/rake-13.4.2/lib/rake/thread_pool.rb +157 -0
  563. data/vendor/bundle/ruby/3.4.0/gems/rake-13.4.2/lib/rake/trace_output.rb +23 -0
  564. data/vendor/bundle/ruby/3.4.0/gems/rake-13.4.2/lib/rake/version.rb +10 -0
  565. data/vendor/bundle/ruby/3.4.0/gems/rake-13.4.2/lib/rake/win32.rb +17 -0
  566. data/vendor/bundle/ruby/3.4.0/gems/rake-13.4.2/lib/rake.rb +69 -0
  567. data/vendor/bundle/ruby/3.4.0/gems/rake-13.4.2/rake.gemspec +102 -0
  568. data/vendor/bundle/ruby/3.4.0/gems/thor-1.5.0/CONTRIBUTING.md +32 -0
  569. data/vendor/bundle/ruby/3.4.0/gems/thor-1.5.0/LICENSE.md +20 -0
  570. data/vendor/bundle/ruby/3.4.0/gems/thor-1.5.0/README.md +44 -0
  571. data/vendor/bundle/ruby/3.4.0/gems/thor-1.5.0/bin/thor +6 -0
  572. data/vendor/bundle/ruby/3.4.0/gems/thor-1.5.0/lib/thor/actions/create_file.rb +105 -0
  573. data/vendor/bundle/ruby/3.4.0/gems/thor-1.5.0/lib/thor/actions/create_link.rb +61 -0
  574. data/vendor/bundle/ruby/3.4.0/gems/thor-1.5.0/lib/thor/actions/directory.rb +108 -0
  575. data/vendor/bundle/ruby/3.4.0/gems/thor-1.5.0/lib/thor/actions/empty_directory.rb +143 -0
  576. data/vendor/bundle/ruby/3.4.0/gems/thor-1.5.0/lib/thor/actions/file_manipulation.rb +407 -0
  577. data/vendor/bundle/ruby/3.4.0/gems/thor-1.5.0/lib/thor/actions/inject_into_file.rb +163 -0
  578. data/vendor/bundle/ruby/3.4.0/gems/thor-1.5.0/lib/thor/actions.rb +340 -0
  579. data/vendor/bundle/ruby/3.4.0/gems/thor-1.5.0/lib/thor/base.rb +826 -0
  580. data/vendor/bundle/ruby/3.4.0/gems/thor-1.5.0/lib/thor/command.rb +151 -0
  581. data/vendor/bundle/ruby/3.4.0/gems/thor-1.5.0/lib/thor/core_ext/hash_with_indifferent_access.rb +107 -0
  582. data/vendor/bundle/ruby/3.4.0/gems/thor-1.5.0/lib/thor/error.rb +106 -0
  583. data/vendor/bundle/ruby/3.4.0/gems/thor-1.5.0/lib/thor/group.rb +292 -0
  584. data/vendor/bundle/ruby/3.4.0/gems/thor-1.5.0/lib/thor/invocation.rb +178 -0
  585. data/vendor/bundle/ruby/3.4.0/gems/thor-1.5.0/lib/thor/line_editor/basic.rb +37 -0
  586. data/vendor/bundle/ruby/3.4.0/gems/thor-1.5.0/lib/thor/line_editor/readline.rb +88 -0
  587. data/vendor/bundle/ruby/3.4.0/gems/thor-1.5.0/lib/thor/line_editor.rb +17 -0
  588. data/vendor/bundle/ruby/3.4.0/gems/thor-1.5.0/lib/thor/nested_context.rb +29 -0
  589. data/vendor/bundle/ruby/3.4.0/gems/thor-1.5.0/lib/thor/parser/argument.rb +86 -0
  590. data/vendor/bundle/ruby/3.4.0/gems/thor-1.5.0/lib/thor/parser/arguments.rb +195 -0
  591. data/vendor/bundle/ruby/3.4.0/gems/thor-1.5.0/lib/thor/parser/option.rb +178 -0
  592. data/vendor/bundle/ruby/3.4.0/gems/thor-1.5.0/lib/thor/parser/options.rb +294 -0
  593. data/vendor/bundle/ruby/3.4.0/gems/thor-1.5.0/lib/thor/parser.rb +4 -0
  594. data/vendor/bundle/ruby/3.4.0/gems/thor-1.5.0/lib/thor/rake_compat.rb +72 -0
  595. data/vendor/bundle/ruby/3.4.0/gems/thor-1.5.0/lib/thor/runner.rb +335 -0
  596. data/vendor/bundle/ruby/3.4.0/gems/thor-1.5.0/lib/thor/shell/basic.rb +392 -0
  597. data/vendor/bundle/ruby/3.4.0/gems/thor-1.5.0/lib/thor/shell/color.rb +117 -0
  598. data/vendor/bundle/ruby/3.4.0/gems/thor-1.5.0/lib/thor/shell/column_printer.rb +29 -0
  599. data/vendor/bundle/ruby/3.4.0/gems/thor-1.5.0/lib/thor/shell/html.rb +84 -0
  600. data/vendor/bundle/ruby/3.4.0/gems/thor-1.5.0/lib/thor/shell/lcs_diff.rb +49 -0
  601. data/vendor/bundle/ruby/3.4.0/gems/thor-1.5.0/lib/thor/shell/table_printer.rb +118 -0
  602. data/vendor/bundle/ruby/3.4.0/gems/thor-1.5.0/lib/thor/shell/terminal.rb +42 -0
  603. data/vendor/bundle/ruby/3.4.0/gems/thor-1.5.0/lib/thor/shell/wrapped_printer.rb +38 -0
  604. data/vendor/bundle/ruby/3.4.0/gems/thor-1.5.0/lib/thor/shell.rb +81 -0
  605. data/vendor/bundle/ruby/3.4.0/gems/thor-1.5.0/lib/thor/util.rb +285 -0
  606. data/vendor/bundle/ruby/3.4.0/gems/thor-1.5.0/lib/thor/version.rb +3 -0
  607. data/vendor/bundle/ruby/3.4.0/gems/thor-1.5.0/lib/thor.rb +707 -0
  608. data/vendor/bundle/ruby/3.4.0/gems/thor-1.5.0/thor.gemspec +33 -0
  609. data/vendor/bundle/ruby/3.4.0/gems/timeout-0.6.1/BSDL +22 -0
  610. data/vendor/bundle/ruby/3.4.0/gems/timeout-0.6.1/COPYING +56 -0
  611. data/vendor/bundle/ruby/3.4.0/gems/timeout-0.6.1/Gemfile +10 -0
  612. data/vendor/bundle/ruby/3.4.0/gems/timeout-0.6.1/README.md +39 -0
  613. data/vendor/bundle/ruby/3.4.0/gems/timeout-0.6.1/lib/timeout.rb +314 -0
  614. data/vendor/bundle/ruby/3.4.0/gems/timeout-0.6.1/timeout.gemspec +33 -0
  615. data/vendor/bundle/ruby/3.4.0/specifications/base64-0.3.0.gemspec +23 -0
  616. data/vendor/bundle/ruby/3.4.0/specifications/cgi-0.5.2.gemspec +25 -0
  617. data/vendor/bundle/ruby/3.4.0/specifications/date-3.5.1.gemspec +25 -0
  618. data/vendor/bundle/ruby/3.4.0/specifications/emot-0.0.4.gemspec +30 -0
  619. data/vendor/bundle/ruby/3.4.0/specifications/fastimage-2.4.1.gemspec +32 -0
  620. data/vendor/bundle/ruby/3.4.0/specifications/hikidoc-0.1.1.gemspec +28 -0
  621. data/vendor/bundle/ruby/3.4.0/specifications/logger-1.7.0.gemspec +22 -0
  622. data/vendor/bundle/ruby/3.4.0/specifications/mail-2.9.1.gemspec +38 -0
  623. data/vendor/bundle/ruby/3.4.0/specifications/mini_mime-1.1.5.gemspec +30 -0
  624. data/vendor/bundle/ruby/3.4.0/specifications/net-imap-0.5.15.gemspec +28 -0
  625. data/vendor/bundle/ruby/3.4.0/specifications/net-pop-0.1.2.gemspec +26 -0
  626. data/vendor/bundle/ruby/3.4.0/specifications/net-protocol-0.2.2.gemspec +26 -0
  627. data/vendor/bundle/ruby/3.4.0/specifications/net-smtp-0.5.1.gemspec +26 -0
  628. data/vendor/bundle/ruby/3.4.0/specifications/pstore-0.2.1.gemspec +22 -0
  629. data/vendor/bundle/ruby/3.4.0/specifications/rack-3.2.6.gemspec +31 -0
  630. data/vendor/bundle/ruby/3.4.0/specifications/rack-session-2.1.2.gemspec +30 -0
  631. data/vendor/bundle/ruby/3.4.0/specifications/rackup-2.3.1.gemspec +26 -0
  632. data/vendor/bundle/ruby/3.4.0/specifications/rake-13.4.2.gemspec +26 -0
  633. data/vendor/bundle/ruby/3.4.0/specifications/thor-1.5.0.gemspec +28 -0
  634. data/vendor/bundle/ruby/3.4.0/specifications/timeout-0.6.1.gemspec +22 -0
  635. metadata +595 -20
  636. data/js/02edit.js +0 -15
  637. data/lib/tdiary/compatible.rb +0 -56
  638. data/misc/lib/fcgi_patch.rb +0 -89
  639. data/misc/paas/heroku/Gemfile.local +0 -12
  640. data/misc/paas/heroku/Gemfile.lock +0 -287
  641. data/public/index.rdf +0 -22
@@ -0,0 +1,1025 @@
1
+ # frozen_string_literal: true
2
+ # = net/pop.rb
3
+ #
4
+ # Copyright (c) 1999-2007 Yukihiro Matsumoto.
5
+ #
6
+ # Copyright (c) 1999-2007 Minero Aoki.
7
+ #
8
+ # Written & maintained by Minero Aoki <aamine@loveruby.net>.
9
+ #
10
+ # Documented by William Webber and Minero Aoki.
11
+ #
12
+ # This program is free software. You can re-distribute and/or
13
+ # modify this program under the same terms as Ruby itself,
14
+ # Ruby Distribute License.
15
+ #
16
+ # NOTE: You can find Japanese version of this document at:
17
+ # http://docs.ruby-lang.org/ja/latest/library/net=2fpop.html
18
+ #
19
+ # $Id$
20
+ #
21
+ # See Net::POP3 for documentation.
22
+ #
23
+
24
+ require 'net/protocol'
25
+ require 'digest/md5'
26
+ require 'timeout'
27
+
28
+ begin
29
+ require "openssl"
30
+ rescue LoadError
31
+ end
32
+
33
+ module Net
34
+
35
+ # Non-authentication POP3 protocol error
36
+ # (reply code "-ERR", except authentication).
37
+ class POPError < ProtocolError; end
38
+
39
+ # POP3 authentication error.
40
+ class POPAuthenticationError < ProtoAuthError; end
41
+
42
+ # Unexpected response from the server.
43
+ class POPBadResponse < POPError; end
44
+
45
+ #
46
+ # == What is This Library?
47
+ #
48
+ # This library provides functionality for retrieving
49
+ # email via POP3, the Post Office Protocol version 3. For details
50
+ # of POP3, see [RFC1939] (http://www.ietf.org/rfc/rfc1939.txt).
51
+ #
52
+ # == Examples
53
+ #
54
+ # === Retrieving Messages
55
+ #
56
+ # This example retrieves messages from the server and deletes them
57
+ # on the server.
58
+ #
59
+ # Messages are written to files named 'inbox/1', 'inbox/2', ....
60
+ # Replace 'pop.example.com' with your POP3 server address, and
61
+ # 'YourAccount' and 'YourPassword' with the appropriate account
62
+ # details.
63
+ #
64
+ # require 'net/pop'
65
+ #
66
+ # pop = Net::POP3.new('pop.example.com')
67
+ # pop.start('YourAccount', 'YourPassword') # (1)
68
+ # if pop.mails.empty?
69
+ # puts 'No mail.'
70
+ # else
71
+ # i = 0
72
+ # pop.each_mail do |m| # or "pop.mails.each ..." # (2)
73
+ # File.open("inbox/#{i}", 'w') do |f|
74
+ # f.write m.pop
75
+ # end
76
+ # m.delete
77
+ # i += 1
78
+ # end
79
+ # puts "#{pop.mails.size} mails popped."
80
+ # end
81
+ # pop.finish # (3)
82
+ #
83
+ # 1. Call Net::POP3#start and start POP session.
84
+ # 2. Access messages by using POP3#each_mail and/or POP3#mails.
85
+ # 3. Close POP session by calling POP3#finish or use the block form of #start.
86
+ #
87
+ # === Shortened Code
88
+ #
89
+ # The example above is very verbose. You can shorten the code by using
90
+ # some utility methods. First, the block form of Net::POP3.start can
91
+ # be used instead of POP3.new, POP3#start and POP3#finish.
92
+ #
93
+ # require 'net/pop'
94
+ #
95
+ # Net::POP3.start('pop.example.com', 110,
96
+ # 'YourAccount', 'YourPassword') do |pop|
97
+ # if pop.mails.empty?
98
+ # puts 'No mail.'
99
+ # else
100
+ # i = 0
101
+ # pop.each_mail do |m| # or "pop.mails.each ..."
102
+ # File.open("inbox/#{i}", 'w') do |f|
103
+ # f.write m.pop
104
+ # end
105
+ # m.delete
106
+ # i += 1
107
+ # end
108
+ # puts "#{pop.mails.size} mails popped."
109
+ # end
110
+ # end
111
+ #
112
+ # POP3#delete_all is an alternative for #each_mail and #delete.
113
+ #
114
+ # require 'net/pop'
115
+ #
116
+ # Net::POP3.start('pop.example.com', 110,
117
+ # 'YourAccount', 'YourPassword') do |pop|
118
+ # if pop.mails.empty?
119
+ # puts 'No mail.'
120
+ # else
121
+ # i = 1
122
+ # pop.delete_all do |m|
123
+ # File.open("inbox/#{i}", 'w') do |f|
124
+ # f.write m.pop
125
+ # end
126
+ # i += 1
127
+ # end
128
+ # end
129
+ # end
130
+ #
131
+ # And here is an even shorter example.
132
+ #
133
+ # require 'net/pop'
134
+ #
135
+ # i = 0
136
+ # Net::POP3.delete_all('pop.example.com', 110,
137
+ # 'YourAccount', 'YourPassword') do |m|
138
+ # File.open("inbox/#{i}", 'w') do |f|
139
+ # f.write m.pop
140
+ # end
141
+ # i += 1
142
+ # end
143
+ #
144
+ # === Memory Space Issues
145
+ #
146
+ # All the examples above get each message as one big string.
147
+ # This example avoids this.
148
+ #
149
+ # require 'net/pop'
150
+ #
151
+ # i = 1
152
+ # Net::POP3.delete_all('pop.example.com', 110,
153
+ # 'YourAccount', 'YourPassword') do |m|
154
+ # File.open("inbox/#{i}", 'w') do |f|
155
+ # m.pop do |chunk| # get a message little by little.
156
+ # f.write chunk
157
+ # end
158
+ # i += 1
159
+ # end
160
+ # end
161
+ #
162
+ # === Using APOP
163
+ #
164
+ # The net/pop library supports APOP authentication.
165
+ # To use APOP, use the Net::APOP class instead of the Net::POP3 class.
166
+ # You can use the utility method, Net::POP3.APOP(). For example:
167
+ #
168
+ # require 'net/pop'
169
+ #
170
+ # # Use APOP authentication if $isapop == true
171
+ # pop = Net::POP3.APOP($isapop).new('apop.example.com', 110)
172
+ # pop.start('YourAccount', 'YourPassword') do |pop|
173
+ # # Rest of the code is the same.
174
+ # end
175
+ #
176
+ # === Fetch Only Selected Mail Using 'UIDL' POP Command
177
+ #
178
+ # If your POP server provides UIDL functionality,
179
+ # you can grab only selected mails from the POP server.
180
+ # e.g.
181
+ #
182
+ # def need_pop?( id )
183
+ # # determine if we need pop this mail...
184
+ # end
185
+ #
186
+ # Net::POP3.start('pop.example.com', 110,
187
+ # 'Your account', 'Your password') do |pop|
188
+ # pop.mails.select { |m| need_pop?(m.unique_id) }.each do |m|
189
+ # do_something(m.pop)
190
+ # end
191
+ # end
192
+ #
193
+ # The POPMail#unique_id() method returns the unique-id of the message as a
194
+ # String. Normally the unique-id is a hash of the message.
195
+ #
196
+ class POP3 < Protocol
197
+ # version of this library
198
+ VERSION = "0.1.2"
199
+
200
+ #
201
+ # Class Parameters
202
+ #
203
+
204
+ # returns the port for POP3
205
+ def POP3.default_port
206
+ default_pop3_port()
207
+ end
208
+
209
+ # The default port for POP3 connections, port 110
210
+ def POP3.default_pop3_port
211
+ 110
212
+ end
213
+
214
+ # The default port for POP3S connections, port 995
215
+ def POP3.default_pop3s_port
216
+ 995
217
+ end
218
+
219
+ def POP3.socket_type #:nodoc: obsolete
220
+ Net::InternetMessageIO
221
+ end
222
+
223
+ #
224
+ # Utilities
225
+ #
226
+
227
+ # Returns the APOP class if +isapop+ is true; otherwise, returns
228
+ # the POP class. For example:
229
+ #
230
+ # # Example 1
231
+ # pop = Net::POP3::APOP($is_apop).new(addr, port)
232
+ #
233
+ # # Example 2
234
+ # Net::POP3::APOP($is_apop).start(addr, port) do |pop|
235
+ # ....
236
+ # end
237
+ #
238
+ def POP3.APOP(isapop)
239
+ isapop ? APOP : POP3
240
+ end
241
+
242
+ # Starts a POP3 session and iterates over each POPMail object,
243
+ # yielding it to the +block+.
244
+ # This method is equivalent to:
245
+ #
246
+ # Net::POP3.start(address, port, account, password) do |pop|
247
+ # pop.each_mail do |m|
248
+ # yield m
249
+ # end
250
+ # end
251
+ #
252
+ # This method raises a POPAuthenticationError if authentication fails.
253
+ #
254
+ # === Example
255
+ #
256
+ # Net::POP3.foreach('pop.example.com', 110,
257
+ # 'YourAccount', 'YourPassword') do |m|
258
+ # file.write m.pop
259
+ # m.delete if $DELETE
260
+ # end
261
+ #
262
+ def POP3.foreach(address, port = nil,
263
+ account = nil, password = nil,
264
+ isapop = false, &block) # :yields: message
265
+ start(address, port, account, password, isapop) {|pop|
266
+ pop.each_mail(&block)
267
+ }
268
+ end
269
+
270
+ # Starts a POP3 session and deletes all messages on the server.
271
+ # If a block is given, each POPMail object is yielded to it before
272
+ # being deleted.
273
+ #
274
+ # This method raises a POPAuthenticationError if authentication fails.
275
+ #
276
+ # === Example
277
+ #
278
+ # Net::POP3.delete_all('pop.example.com', 110,
279
+ # 'YourAccount', 'YourPassword') do |m|
280
+ # file.write m.pop
281
+ # end
282
+ #
283
+ def POP3.delete_all(address, port = nil,
284
+ account = nil, password = nil,
285
+ isapop = false, &block)
286
+ start(address, port, account, password, isapop) {|pop|
287
+ pop.delete_all(&block)
288
+ }
289
+ end
290
+
291
+ # Opens a POP3 session, attempts authentication, and quits.
292
+ #
293
+ # This method raises POPAuthenticationError if authentication fails.
294
+ #
295
+ # === Example: normal POP3
296
+ #
297
+ # Net::POP3.auth_only('pop.example.com', 110,
298
+ # 'YourAccount', 'YourPassword')
299
+ #
300
+ # === Example: APOP
301
+ #
302
+ # Net::POP3.auth_only('pop.example.com', 110,
303
+ # 'YourAccount', 'YourPassword', true)
304
+ #
305
+ def POP3.auth_only(address, port = nil,
306
+ account = nil, password = nil,
307
+ isapop = false)
308
+ new(address, port, isapop).auth_only account, password
309
+ end
310
+
311
+ # Starts a pop3 session, attempts authentication, and quits.
312
+ # This method must not be called while POP3 session is opened.
313
+ # This method raises POPAuthenticationError if authentication fails.
314
+ def auth_only(account, password)
315
+ raise IOError, 'opening previously opened POP session' if started?
316
+ start(account, password) {
317
+ ;
318
+ }
319
+ end
320
+
321
+ #
322
+ # SSL
323
+ #
324
+
325
+ @ssl_params = nil
326
+
327
+ # :call-seq:
328
+ # Net::POP.enable_ssl(params = {})
329
+ #
330
+ # Enable SSL for all new instances.
331
+ # +params+ is passed to OpenSSL::SSLContext#set_params.
332
+ def POP3.enable_ssl(*args)
333
+ @ssl_params = create_ssl_params(*args)
334
+ end
335
+
336
+ # Constructs proper parameters from arguments
337
+ def POP3.create_ssl_params(verify_or_params = {}, certs = nil)
338
+ begin
339
+ params = verify_or_params.to_hash
340
+ rescue NoMethodError
341
+ params = {}
342
+ params[:verify_mode] = verify_or_params
343
+ if certs
344
+ if File.file?(certs)
345
+ params[:ca_file] = certs
346
+ elsif File.directory?(certs)
347
+ params[:ca_path] = certs
348
+ end
349
+ end
350
+ end
351
+ return params
352
+ end
353
+
354
+ # Disable SSL for all new instances.
355
+ def POP3.disable_ssl
356
+ @ssl_params = nil
357
+ end
358
+
359
+ # returns the SSL Parameters
360
+ #
361
+ # see also POP3.enable_ssl
362
+ def POP3.ssl_params
363
+ return @ssl_params
364
+ end
365
+
366
+ # returns +true+ if POP3.ssl_params is set
367
+ def POP3.use_ssl?
368
+ return !@ssl_params.nil?
369
+ end
370
+
371
+ # returns whether verify_mode is enable from POP3.ssl_params
372
+ def POP3.verify
373
+ return @ssl_params[:verify_mode]
374
+ end
375
+
376
+ # returns the :ca_file or :ca_path from POP3.ssl_params
377
+ def POP3.certs
378
+ return @ssl_params[:ca_file] || @ssl_params[:ca_path]
379
+ end
380
+
381
+ #
382
+ # Session management
383
+ #
384
+
385
+ # Creates a new POP3 object and open the connection. Equivalent to
386
+ #
387
+ # Net::POP3.new(address, port, isapop).start(account, password)
388
+ #
389
+ # If +block+ is provided, yields the newly-opened POP3 object to it,
390
+ # and automatically closes it at the end of the session.
391
+ #
392
+ # === Example
393
+ #
394
+ # Net::POP3.start(addr, port, account, password) do |pop|
395
+ # pop.each_mail do |m|
396
+ # file.write m.pop
397
+ # m.delete
398
+ # end
399
+ # end
400
+ #
401
+ def POP3.start(address, port = nil,
402
+ account = nil, password = nil,
403
+ isapop = false, &block) # :yield: pop
404
+ new(address, port, isapop).start(account, password, &block)
405
+ end
406
+
407
+ # Creates a new POP3 object.
408
+ #
409
+ # +address+ is the hostname or ip address of your POP3 server.
410
+ #
411
+ # The optional +port+ is the port to connect to.
412
+ #
413
+ # The optional +isapop+ specifies whether this connection is going
414
+ # to use APOP authentication; it defaults to +false+.
415
+ #
416
+ # This method does *not* open the TCP connection.
417
+ def initialize(addr, port = nil, isapop = false)
418
+ @address = addr
419
+ @ssl_params = POP3.ssl_params
420
+ @port = port
421
+ @apop = isapop
422
+
423
+ @command = nil
424
+ @socket = nil
425
+ @started = false
426
+ @open_timeout = 30
427
+ @read_timeout = 60
428
+ @debug_output = nil
429
+
430
+ @mails = nil
431
+ @n_mails = nil
432
+ @n_bytes = nil
433
+ end
434
+
435
+ # Does this instance use APOP authentication?
436
+ def apop?
437
+ @apop
438
+ end
439
+
440
+ # does this instance use SSL?
441
+ def use_ssl?
442
+ return !@ssl_params.nil?
443
+ end
444
+
445
+ # :call-seq:
446
+ # Net::POP#enable_ssl(params = {})
447
+ #
448
+ # Enables SSL for this instance. Must be called before the connection is
449
+ # established to have any effect.
450
+ # +params[:port]+ is port to establish the SSL connection on; Defaults to 995.
451
+ # +params+ (except :port) is passed to OpenSSL::SSLContext#set_params.
452
+ def enable_ssl(verify_or_params = {}, certs = nil, port = nil)
453
+ begin
454
+ @ssl_params = verify_or_params.to_hash.dup
455
+ @port = @ssl_params.delete(:port) || @port
456
+ rescue NoMethodError
457
+ @ssl_params = POP3.create_ssl_params(verify_or_params, certs)
458
+ @port = port || @port
459
+ end
460
+ end
461
+
462
+ # Disable SSL for all new instances.
463
+ def disable_ssl
464
+ @ssl_params = nil
465
+ end
466
+
467
+ # Provide human-readable stringification of class state.
468
+ def inspect
469
+ +"#<#{self.class} #{@address}:#{@port} open=#{@started}>"
470
+ end
471
+
472
+ # *WARNING*: This method causes a serious security hole.
473
+ # Use this method only for debugging.
474
+ #
475
+ # Set an output stream for debugging.
476
+ #
477
+ # === Example
478
+ #
479
+ # pop = Net::POP.new(addr, port)
480
+ # pop.set_debug_output $stderr
481
+ # pop.start(account, passwd) do |pop|
482
+ # ....
483
+ # end
484
+ #
485
+ def set_debug_output(arg)
486
+ @debug_output = arg
487
+ end
488
+
489
+ # The address to connect to.
490
+ attr_reader :address
491
+
492
+ # The port number to connect to.
493
+ def port
494
+ return @port || (use_ssl? ? POP3.default_pop3s_port : POP3.default_pop3_port)
495
+ end
496
+
497
+ # Seconds to wait until a connection is opened.
498
+ # If the POP3 object cannot open a connection within this time,
499
+ # it raises a Net::OpenTimeout exception. The default value is 30 seconds.
500
+ attr_accessor :open_timeout
501
+
502
+ # Seconds to wait until reading one block (by one read(1) call).
503
+ # If the POP3 object cannot complete a read() within this time,
504
+ # it raises a Net::ReadTimeout exception. The default value is 60 seconds.
505
+ attr_reader :read_timeout
506
+
507
+ # Set the read timeout.
508
+ def read_timeout=(sec)
509
+ @command.socket.read_timeout = sec if @command
510
+ @read_timeout = sec
511
+ end
512
+
513
+ # +true+ if the POP3 session has started.
514
+ def started?
515
+ @started
516
+ end
517
+
518
+ alias active? started? #:nodoc: obsolete
519
+
520
+ # Starts a POP3 session.
521
+ #
522
+ # When called with block, gives a POP3 object to the block and
523
+ # closes the session after block call finishes.
524
+ #
525
+ # This method raises a POPAuthenticationError if authentication fails.
526
+ def start(account, password) # :yield: pop
527
+ raise IOError, 'POP session already started' if @started
528
+ if block_given?
529
+ begin
530
+ do_start account, password
531
+ return yield(self)
532
+ ensure
533
+ do_finish
534
+ end
535
+ else
536
+ do_start account, password
537
+ return self
538
+ end
539
+ end
540
+
541
+ # internal method for Net::POP3.start
542
+ def do_start(account, password) # :nodoc:
543
+ begin
544
+ s = Socket.tcp @address, port, nil, nil, connect_timeout: @open_timeout
545
+ rescue Errno::ETIMEDOUT #raise Net:OpenTimeout instead for compatibility with previous versions
546
+ raise Net::OpenTimeout, "Timeout to open TCP connection to "\
547
+ "#{@address}:#{port} (exceeds #{@open_timeout} seconds)"
548
+ end
549
+ if use_ssl?
550
+ raise 'openssl library not installed' unless defined?(OpenSSL)
551
+ context = OpenSSL::SSL::SSLContext.new
552
+ context.set_params(@ssl_params)
553
+ s = OpenSSL::SSL::SSLSocket.new(s, context)
554
+ s.hostname = @address
555
+ s.sync_close = true
556
+ ssl_socket_connect(s, @open_timeout)
557
+ if context.verify_mode != OpenSSL::SSL::VERIFY_NONE
558
+ s.post_connection_check(@address)
559
+ end
560
+ end
561
+ @socket = InternetMessageIO.new(s,
562
+ read_timeout: @read_timeout,
563
+ debug_output: @debug_output)
564
+ logging "POP session started: #{@address}:#{@port} (#{@apop ? 'APOP' : 'POP'})"
565
+ on_connect
566
+ @command = POP3Command.new(@socket)
567
+ if apop?
568
+ @command.apop account, password
569
+ else
570
+ @command.auth account, password
571
+ end
572
+ @started = true
573
+ ensure
574
+ # Authentication failed, clean up connection.
575
+ unless @started
576
+ s.close if s
577
+ @socket = nil
578
+ @command = nil
579
+ end
580
+ end
581
+ private :do_start
582
+
583
+ # Does nothing
584
+ def on_connect # :nodoc:
585
+ end
586
+ private :on_connect
587
+
588
+ # Finishes a POP3 session and closes TCP connection.
589
+ def finish
590
+ raise IOError, 'POP session not yet started' unless started?
591
+ do_finish
592
+ end
593
+
594
+ # nil's out the:
595
+ # - mails
596
+ # - number counter for mails
597
+ # - number counter for bytes
598
+ # - quits the current command, if any
599
+ def do_finish # :nodoc:
600
+ @mails = nil
601
+ @n_mails = nil
602
+ @n_bytes = nil
603
+ @command.quit if @command
604
+ ensure
605
+ @started = false
606
+ @command = nil
607
+ @socket.close if @socket
608
+ @socket = nil
609
+ end
610
+ private :do_finish
611
+
612
+ # Returns the current command.
613
+ #
614
+ # Raises IOError if there is no active socket
615
+ def command # :nodoc:
616
+ raise IOError, 'POP session not opened yet' \
617
+ if not @socket or @socket.closed?
618
+ @command
619
+ end
620
+ private :command
621
+
622
+ #
623
+ # POP protocol wrapper
624
+ #
625
+
626
+ # Returns the number of messages on the POP server.
627
+ def n_mails
628
+ return @n_mails if @n_mails
629
+ @n_mails, @n_bytes = command().stat
630
+ @n_mails
631
+ end
632
+
633
+ # Returns the total size in bytes of all the messages on the POP server.
634
+ def n_bytes
635
+ return @n_bytes if @n_bytes
636
+ @n_mails, @n_bytes = command().stat
637
+ @n_bytes
638
+ end
639
+
640
+ # Returns an array of Net::POPMail objects, representing all the
641
+ # messages on the server. This array is renewed when the session
642
+ # restarts; otherwise, it is fetched from the server the first time
643
+ # this method is called (directly or indirectly) and cached.
644
+ #
645
+ # This method raises a POPError if an error occurs.
646
+ def mails
647
+ return @mails.dup if @mails
648
+ if n_mails() == 0
649
+ # some popd raises error for LIST on the empty mailbox.
650
+ @mails = []
651
+ return []
652
+ end
653
+
654
+ @mails = command().list.map {|num, size|
655
+ POPMail.new(num, size, self, command())
656
+ }
657
+ @mails.dup
658
+ end
659
+
660
+ # Yields each message to the passed-in block in turn.
661
+ # Equivalent to:
662
+ #
663
+ # pop3.mails.each do |popmail|
664
+ # ....
665
+ # end
666
+ #
667
+ # This method raises a POPError if an error occurs.
668
+ def each_mail(&block) # :yield: message
669
+ mails().each(&block)
670
+ end
671
+
672
+ alias each each_mail
673
+
674
+ # Deletes all messages on the server.
675
+ #
676
+ # If called with a block, yields each message in turn before deleting it.
677
+ #
678
+ # === Example
679
+ #
680
+ # n = 1
681
+ # pop.delete_all do |m|
682
+ # File.open("inbox/#{n}") do |f|
683
+ # f.write m.pop
684
+ # end
685
+ # n += 1
686
+ # end
687
+ #
688
+ # This method raises a POPError if an error occurs.
689
+ #
690
+ def delete_all # :yield: message
691
+ mails().each do |m|
692
+ yield m if block_given?
693
+ m.delete unless m.deleted?
694
+ end
695
+ end
696
+
697
+ # Resets the session. This clears all "deleted" marks from messages.
698
+ #
699
+ # This method raises a POPError if an error occurs.
700
+ def reset
701
+ command().rset
702
+ mails().each do |m|
703
+ m.instance_eval {
704
+ @deleted = false
705
+ }
706
+ end
707
+ end
708
+
709
+ def set_all_uids #:nodoc: internal use only (called from POPMail#uidl)
710
+ uidl = command().uidl
711
+ @mails.each {|m| m.uid = uidl[m.number] }
712
+ end
713
+
714
+ # debugging output for +msg+
715
+ def logging(msg)
716
+ @debug_output << msg + "\n" if @debug_output
717
+ end
718
+
719
+ end # class POP3
720
+
721
+ # class aliases
722
+ POP = POP3 # :nodoc:
723
+ POPSession = POP3 # :nodoc:
724
+ POP3Session = POP3 # :nodoc:
725
+
726
+ #
727
+ # This class is equivalent to POP3, except that it uses APOP authentication.
728
+ #
729
+ class APOP < POP3
730
+ # Always returns true.
731
+ def apop?
732
+ true
733
+ end
734
+ end
735
+
736
+ # class aliases
737
+ APOPSession = APOP
738
+
739
+ #
740
+ # This class represents a message which exists on the POP server.
741
+ # Instances of this class are created by the POP3 class; they should
742
+ # not be directly created by the user.
743
+ #
744
+ class POPMail
745
+
746
+ def initialize(num, len, pop, cmd) #:nodoc:
747
+ @number = num
748
+ @length = len
749
+ @pop = pop
750
+ @command = cmd
751
+ @deleted = false
752
+ @uid = nil
753
+ end
754
+
755
+ # The sequence number of the message on the server.
756
+ attr_reader :number
757
+
758
+ # The length of the message in octets.
759
+ attr_reader :length
760
+ alias size length
761
+
762
+ # Provide human-readable stringification of class state.
763
+ def inspect
764
+ +"#<#{self.class} #{@number}#{@deleted ? ' deleted' : ''}>"
765
+ end
766
+
767
+ #
768
+ # This method fetches the message. If called with a block, the
769
+ # message is yielded to the block one chunk at a time. If called
770
+ # without a block, the message is returned as a String. The optional
771
+ # +dest+ argument will be prepended to the returned String; this
772
+ # argument is essentially obsolete.
773
+ #
774
+ # === Example without block
775
+ #
776
+ # POP3.start('pop.example.com', 110,
777
+ # 'YourAccount', 'YourPassword') do |pop|
778
+ # n = 1
779
+ # pop.mails.each do |popmail|
780
+ # File.open("inbox/#{n}", 'w') do |f|
781
+ # f.write popmail.pop
782
+ # end
783
+ # popmail.delete
784
+ # n += 1
785
+ # end
786
+ # end
787
+ #
788
+ # === Example with block
789
+ #
790
+ # POP3.start('pop.example.com', 110,
791
+ # 'YourAccount', 'YourPassword') do |pop|
792
+ # n = 1
793
+ # pop.mails.each do |popmail|
794
+ # File.open("inbox/#{n}", 'w') do |f|
795
+ # popmail.pop do |chunk| ####
796
+ # f.write chunk
797
+ # end
798
+ # end
799
+ # n += 1
800
+ # end
801
+ # end
802
+ #
803
+ # This method raises a POPError if an error occurs.
804
+ #
805
+ def pop( dest = +'', &block ) # :yield: message_chunk
806
+ if block_given?
807
+ @command.retr(@number, &block)
808
+ nil
809
+ else
810
+ @command.retr(@number) do |chunk|
811
+ dest << chunk
812
+ end
813
+ dest
814
+ end
815
+ end
816
+
817
+ alias all pop #:nodoc: obsolete
818
+ alias mail pop #:nodoc: obsolete
819
+
820
+ # Fetches the message header and +lines+ lines of body.
821
+ #
822
+ # The optional +dest+ argument is obsolete.
823
+ #
824
+ # This method raises a POPError if an error occurs.
825
+ def top(lines, dest = +'')
826
+ @command.top(@number, lines) do |chunk|
827
+ dest << chunk
828
+ end
829
+ dest
830
+ end
831
+
832
+ # Fetches the message header.
833
+ #
834
+ # The optional +dest+ argument is obsolete.
835
+ #
836
+ # This method raises a POPError if an error occurs.
837
+ def header(dest = +'')
838
+ top(0, dest)
839
+ end
840
+
841
+ # Marks a message for deletion on the server. Deletion does not
842
+ # actually occur until the end of the session; deletion may be
843
+ # cancelled for _all_ marked messages by calling POP3#reset().
844
+ #
845
+ # This method raises a POPError if an error occurs.
846
+ #
847
+ # === Example
848
+ #
849
+ # POP3.start('pop.example.com', 110,
850
+ # 'YourAccount', 'YourPassword') do |pop|
851
+ # n = 1
852
+ # pop.mails.each do |popmail|
853
+ # File.open("inbox/#{n}", 'w') do |f|
854
+ # f.write popmail.pop
855
+ # end
856
+ # popmail.delete ####
857
+ # n += 1
858
+ # end
859
+ # end
860
+ #
861
+ def delete
862
+ @command.dele @number
863
+ @deleted = true
864
+ end
865
+
866
+ alias delete! delete #:nodoc: obsolete
867
+
868
+ # True if the mail has been deleted.
869
+ def deleted?
870
+ @deleted
871
+ end
872
+
873
+ # Returns the unique-id of the message.
874
+ # Normally the unique-id is a hash string of the message.
875
+ #
876
+ # This method raises a POPError if an error occurs.
877
+ def unique_id
878
+ return @uid if @uid
879
+ @pop.set_all_uids
880
+ @uid
881
+ end
882
+
883
+ alias uidl unique_id
884
+
885
+ def uid=(uid) #:nodoc: internal use only
886
+ @uid = uid
887
+ end
888
+
889
+ end # class POPMail
890
+
891
+
892
+ class POP3Command #:nodoc: internal use only
893
+
894
+ def initialize(sock)
895
+ @socket = sock
896
+ @error_occurred = false
897
+ res = check_response(critical { recv_response() })
898
+ @apop_stamp = res.slice(/<[!-~]+@[!-~]+>/)
899
+ end
900
+
901
+ attr_reader :socket
902
+
903
+ def inspect
904
+ +"#<#{self.class} socket=#{@socket}>"
905
+ end
906
+
907
+ def auth(account, password)
908
+ check_response_auth(critical {
909
+ check_response_auth(get_response('USER %s', account))
910
+ get_response('PASS %s', password)
911
+ })
912
+ end
913
+
914
+ def apop(account, password)
915
+ raise POPAuthenticationError, 'not APOP server; cannot login' \
916
+ unless @apop_stamp
917
+ check_response_auth(critical {
918
+ get_response('APOP %s %s',
919
+ account,
920
+ Digest::MD5.hexdigest(@apop_stamp + password))
921
+ })
922
+ end
923
+
924
+ def list
925
+ critical {
926
+ getok 'LIST'
927
+ list = []
928
+ @socket.each_list_item do |line|
929
+ m = /\A(\d+)[ \t]+(\d+)/.match(line) or
930
+ raise POPBadResponse, "bad response: #{line}"
931
+ list.push [m[1].to_i, m[2].to_i]
932
+ end
933
+ return list
934
+ }
935
+ end
936
+
937
+ def stat
938
+ res = check_response(critical { get_response('STAT') })
939
+ m = /\A\+OK\s+(\d+)\s+(\d+)/.match(res) or
940
+ raise POPBadResponse, "wrong response format: #{res}"
941
+ [m[1].to_i, m[2].to_i]
942
+ end
943
+
944
+ def rset
945
+ check_response(critical { get_response('RSET') })
946
+ end
947
+
948
+ def top(num, lines = 0, &block)
949
+ critical {
950
+ getok('TOP %d %d', num, lines)
951
+ @socket.each_message_chunk(&block)
952
+ }
953
+ end
954
+
955
+ def retr(num, &block)
956
+ critical {
957
+ getok('RETR %d', num)
958
+ @socket.each_message_chunk(&block)
959
+ }
960
+ end
961
+
962
+ def dele(num)
963
+ check_response(critical { get_response('DELE %d', num) })
964
+ end
965
+
966
+ def uidl(num = nil)
967
+ if num
968
+ res = check_response(critical { get_response('UIDL %d', num) })
969
+ return res.split(/ /)[1]
970
+ else
971
+ critical {
972
+ getok('UIDL')
973
+ table = {}
974
+ @socket.each_list_item do |line|
975
+ num, uid = line.split(' ')
976
+ table[num.to_i] = uid
977
+ end
978
+ return table
979
+ }
980
+ end
981
+ end
982
+
983
+ def quit
984
+ check_response(critical { get_response('QUIT') })
985
+ end
986
+
987
+ private
988
+
989
+ def getok(fmt, *fargs)
990
+ @socket.writeline sprintf(fmt, *fargs)
991
+ check_response(recv_response())
992
+ end
993
+
994
+ def get_response(fmt, *fargs)
995
+ @socket.writeline sprintf(fmt, *fargs)
996
+ recv_response()
997
+ end
998
+
999
+ def recv_response
1000
+ @socket.readline
1001
+ end
1002
+
1003
+ def check_response(res)
1004
+ raise POPError, res unless /\A\+OK/i =~ res
1005
+ res
1006
+ end
1007
+
1008
+ def check_response_auth(res)
1009
+ raise POPAuthenticationError, res unless /\A\+OK/i =~ res
1010
+ res
1011
+ end
1012
+
1013
+ def critical
1014
+ return '+OK dummy ok response' if @error_occurred
1015
+ begin
1016
+ return yield()
1017
+ rescue Exception
1018
+ @error_occurred = true
1019
+ raise
1020
+ end
1021
+ end
1022
+
1023
+ end # class POP3Command
1024
+
1025
+ end # module Net