Backport #8415
closed
Net::IMAP#capability_response raises "Net::IMAP::ResponseParseError: unexpected token CRLF" for common CAPABILITY
Added by peter@sanebox.com (Peter Kovacs) over 11 years ago.
Updated over 11 years ago.
Description
Unfortunately Apple's iCloud IMAP service returns a non-conforming CAPABILITY response which causes this parse error to be raised:
"* CAPABILITY st11p00mm-iscream009 1Q49 XAPPLEPUSHSERVICE IMAP4 IMAP4rev1 SASL-IR AUTH=ATOKEN AUTH=PLAIN \r\n"
To reproduce:
require 'net/imap'
imap = Net::IMAP.new( 'imap.mail.me.com', 993, true )
imap.capability
To fix:
--- lib/ruby/2.0.0/net/imap.rb~ 2013-05-17 07:12:04.000000000 -0400
+++ lib/ruby/2.0.0/net/imap.rb 2013-05-17 07:13:05.000000000 -0400
@@ -2954,6 +2954,7 @@
break
when T_SPACE
shift_token
This bug also applies to 1.8.7
- Status changed from Open to Assigned
- Assignee set to shugo (Shugo Maeda)
- Status changed from Assigned to Closed
- % Done changed from 0 to 100
This issue was solved with changeset r41091.
Peter, thank you for reporting this issue.
Your contribution to Ruby is greatly appreciated.
May Ruby be with you.
-
lib/net/imap.rb (capability_response): should ignore trailing
spaces. Thanks, Peter Kovacs. [ruby-core:55024] [Bug #8415]
-
test/net/imap/test_imap_response_parser.rb: related test.
- Tracker changed from Bug to Backport
- Project changed from Ruby master to Backport200
- Category deleted (
lib)
- Status changed from Closed to Assigned
- Assignee changed from shugo (Shugo Maeda) to nagachika (Tomoyuki Chikanaga)
- Status changed from Assigned to Closed
This issue was solved with changeset r41188.
Peter, thank you for reporting this issue.
Your contribution to Ruby is greatly appreciated.
May Ruby be with you.
merge revision(s) 41091: [Backport #8415]
* lib/net/imap.rb (capability_response): should ignore trailing
spaces. Thanks, Peter Kovacs. [ruby-core:55024] [Bug #8415]
* test/net/imap/test_imap_response_parser.rb: related test.
- Project changed from Backport200 to Backport193
- Status changed from Closed to Assigned
- Assignee changed from nagachika (Tomoyuki Chikanaga) to usa (Usaku NAKAMURA)
This is needed also in 1.9.3?
I move this ticket to Backport93 just for memorandum.
- Status changed from Assigned to Closed
This issue was solved with changeset r41647.
Peter, thank you for reporting this issue.
Your contribution to Ruby is greatly appreciated.
May Ruby be with you.
merge revision(s) 41091: [Backport #8415]
* lib/net/imap.rb (capability_response): should ignore trailing
spaces. Thanks, Peter Kovacs. [ruby-core:55024] [Bug #8415]
* test/net/imap/test_imap_response_parser.rb: related test.
Also available in: Atom
PDF
Like0
Like0Like0Like0Like0Like0Like0