net-imap 0.4.6 → 0.4.7

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.

Potentially problematic release.


This version of net-imap might be problematic. Click here for more details.

checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: e9a3148dcf057ea22dbb67a976576ca59060038a8352fc1a71f3ec4cd928289b
4
- data.tar.gz: 38e9bbc72d9d90bad28b24f47305d6376c6b17e41233af747bfd3cae27cdfc2e
3
+ metadata.gz: ac68288133676e52f1e07e714debeb5b5f07f79f1990efe3f1342f0a643a4df1
4
+ data.tar.gz: 2588adb3518535fc451a06396133cbcf948d097dc26366486f698296a16bc0a6
5
5
  SHA512:
6
- metadata.gz: f5f9f4ade6c25741a402ea78c81928ab455c9b8c6bff5998ae884d567257cb823a16195aa148abc7d9215aa9d0bdce3632904e0f921f061174b04ccdfd4abf9c
7
- data.tar.gz: 683fe61b95035387e6f651565174f6499a0f68e712287e904318f05e23fc24f195035a4c29eaeedbeb42a24401e7f2884f8e75af359d623daf098da402f8aaea
6
+ metadata.gz: 31726eb30d3e24ce39a6cc5ad6ea5fbf13f9fd43f0f621d32b9e9f50b0fbcee5b240d163b384efa03df19257c9772f333e02c96a11e7f40b5a01899879838b6d
7
+ data.tar.gz: 83ba9341159c2916f673f378b449d5743daa3f68ec7490c9e03b6b619dd1fe455a8a5fe50dc8afc4e138b66c941e696d345dbf88058ffbe99e4b2ae3f44f4d74
@@ -978,7 +978,7 @@ module Net
978
978
  # env-bcc = "(" 1*address ")" / nil
979
979
  def nlist__address
980
980
  return if NIL?
981
- lpar; list = [address]; list << address until rpar?
981
+ lpar; list = [address]; list << address until (quirky_SP?; rpar?)
982
982
  list
983
983
  end
984
984
 
@@ -989,6 +989,12 @@ module Net
989
989
  alias env_cc nlist__address
990
990
  alias env_bcc nlist__address
991
991
 
992
+ # Used when servers erroneously send an extra SP.
993
+ #
994
+ # As of 2023-11-28, Outlook.com (still) sends SP
995
+ # between +address+ in <tt>env-*</tt> lists.
996
+ alias quirky_SP? SP?
997
+
992
998
  # date-time = DQUOTE date-day-fixed "-" date-month "-" date-year
993
999
  # SP time SP zone DQUOTE
994
1000
  alias date_time quoted
@@ -1452,34 +1458,15 @@ module Net
1452
1458
  # mailbox-data = obsolete-search-response / ...
1453
1459
  # obsolete-search-response = "SEARCH" *(SP nz-number)
1454
1460
  def mailbox_data__search
1455
- token = match(T_ATOM)
1456
- name = token.value.upcase
1457
- token = lookahead
1458
- if token.symbol == T_SPACE
1459
- shift_token
1460
- data = []
1461
- while true
1462
- token = lookahead
1463
- case token.symbol
1464
- when T_CRLF
1465
- break
1466
- when T_SPACE
1467
- shift_token
1468
- when T_NUMBER
1469
- data.push(number)
1470
- when T_LPAR
1471
- # TODO: include the MODSEQ value in a response
1472
- shift_token
1473
- match(T_ATOM)
1474
- match(T_SPACE)
1475
- match(T_NUMBER)
1476
- match(T_RPAR)
1477
- end
1478
- end
1479
- else
1480
- data = []
1461
+ name = label_in("SEARCH", "SORT")
1462
+ data = []
1463
+ while _ = SP? && nz_number? do data << _ end
1464
+ if lpar?
1465
+ label("MODSEQ"); SP!
1466
+ mod_sequence_value
1467
+ rpar
1481
1468
  end
1482
- return UntaggedResponse.new(name, data, @str)
1469
+ UntaggedResponse.new(name, data, @str)
1483
1470
  end
1484
1471
  alias sort_data mailbox_data__search
1485
1472
 
data/lib/net/imap.rb CHANGED
@@ -690,7 +690,7 @@ module Net
690
690
  # * {IMAP URLAUTH Authorization Mechanism Registry}[https://www.iana.org/assignments/urlauth-authorization-mechanism-registry/urlauth-authorization-mechanism-registry.xhtml]
691
691
  #
692
692
  class IMAP < Protocol
693
- VERSION = "0.4.6"
693
+ VERSION = "0.4.7"
694
694
 
695
695
  # Aliases for supported capabilities, to be used with the #enable command.
696
696
  ENABLE_ALIASES = {
data/net-imap.gemspec CHANGED
@@ -21,6 +21,7 @@ Gem::Specification.new do |spec|
21
21
 
22
22
  spec.metadata["homepage_uri"] = spec.homepage
23
23
  spec.metadata["source_code_uri"] = spec.homepage
24
+ spec.metadata["changelog_uri"] = spec.homepage + "/releases"
24
25
 
25
26
  # Specify which files should be added to the gem when it is released.
26
27
  # The `git ls-files -z` loads the files in the RubyGem that have been added into git.
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: net-imap
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.4.6
4
+ version: 0.4.7
5
5
  platform: ruby
6
6
  authors:
7
7
  - Shugo Maeda
@@ -9,7 +9,7 @@ authors:
9
9
  autorequire:
10
10
  bindir: exe
11
11
  cert_chain: []
12
- date: 2023-11-21 00:00:00.000000000 Z
12
+ date: 2023-11-29 00:00:00.000000000 Z
13
13
  dependencies:
14
14
  - !ruby/object:Gem::Dependency
15
15
  name: net-protocol
@@ -133,6 +133,7 @@ licenses:
133
133
  metadata:
134
134
  homepage_uri: https://github.com/ruby/net-imap
135
135
  source_code_uri: https://github.com/ruby/net-imap
136
+ changelog_uri: https://github.com/ruby/net-imap/releases
136
137
  post_install_message:
137
138
  rdoc_options: []
138
139
  require_paths: