Subject: [imapext] IMAP COMPRESS=DEFLATE Support

From: Jayantheesh S B <[email-masked]>
Date: Tue, 10 Mar 2015 21:08:19 +0000

All,

I am facing an issue with IMAP COMPRESS=DEFLATE feature. After COMPRESS DEFLATE command,
deflate stream is opened and sent the NAMESPACE request to server.  Request is sent successfully, but response was not received.

After Socket read timeout, it's coming out from the Read block. Currently I am using java.util.zip.* package for creating the deflate stream.
Please share if you face any similar issues, during the implementation.  Kindly throw some light on this issue.

Log Snippet:
03-10 17:42:31.482 18173 18182 D MailTransport: *** IMAP open demo.isode.com:143

03-10 17:42:32.072 18173 18182 D MailTransport: >>> 1 CAPABILITY
03-10 17:42:32.392 18173 18182 D Email   : <<< #null# ["CAPABILITY", "IMAP4rev1", "UIDPLUS", "LITERAL+", "UNSELECT", "NAMESPACE", "SORT", "BINARY", "MULTIAPPEND", "THREAD=ORDEREDSUBJECT", "THREAD=REFERENCES", "ESEARCH", "LIST-EXTENDED", "IDLE", "URLAUTH", "CATENATE", "CONDSTORE", "QRESYNC", "ENABLE", "STARTTLS", "ACL", "RIGHTS=kxet", "QUOTA", "COMPRESS=DEFLATE", "SASL-IR", "WITHIN", "CONTEXT=SEARCH", "SEARCHRES", "SPECIAL-USE", "MOVE", "AUTH=SCRAM-SHA-1", "AUTH=DIGEST-MD5", "AUTH=CRAM-MD5", "AUTH=PLAIN"]
03-10 17:42:32.472 18173 18182 D Email   : <<< #1# ["OK", "CAPABILITY Completed"]

03-10 17:42:32.492 18173 18182 D MailTransport: >>> 2 AUTHENTICATE DIGEST-MD5
............................

03-10 17:42:33.222 18173 18182 D MailTransport: >>> 3 COMPRESS DEFLATE
03-10 17:42:33.352 18173 18182 D Email   : <<< #3# ["OK", "Compression active"]

03-10 17:42:33.392 18173 18182 D MailTransport: >>> 4 NAMESPACE
03-10 17:42:33.412 18173 18182 D IMAPSocketOutputStream: RawBytes >>78 9C
03-10 17:42:33.422 18173 18182 D IMAPSocketOutputStream: RawBytes >>120
03-10 17:42:33.462 18173 18182 D IMAPSocketOutputStream: RawBytes >>-100

03-10 17:42:33.532 18173 18182 D ImapResponseParser: parseResponse
03-10 17:42:33.552 18173 18182 D IMAPSocketInputStream: read

Regards,
Jay

---

From: Arnt Gulbrandsen <[email-masked]>
Date: Tue, 10 Mar 2015 22:16:14 +0100

Check that you send z_sync_flush at the end of your command. If you don't, 
the server won't read your CRLF.

Arnt

---

From: Brandon Long <[email-masked]>
Date: Wed, 18 Mar 2015 13:18:23 -0700

Note that until Java 7, java.util.zip didn't have Z_FLUSH as an option, the
usual work-around was to use the java impl of zlib, jzlib.

Brandon

On Tue, Mar 10, 2015 at 2:16 PM, Arnt Gulbrandsen <[email-masked]>
wrote:

> _______________________________________________
> imapext mailing list
> [email-masked]
> https://www.ietf.org/mailman/listinfo/imapext
>

---

From: Jayantheesh S B <[email-masked]>
Date: Thu, 19 Mar 2015 19:10:47 +0000

Thanks Brandon & Arnt.

From: Brandon Long [mailto:[email-masked]]
Sent: Wednesday, March 18, 2015 4:18 PM
To: Arnt Gulbrandsen
Cc: [email-masked]
Subject: Re: [imapext] IMAP COMPRESS=DEFLATE Support

Note that until Java 7, java.util.zip didn't have Z_FLUSH as an option, the usual work-around was to use the java impl of zlib, jzlib.

Brandon

On Tue, Mar 10, 2015 at 2:16 PM, Arnt Gulbrandsen <[email-masked]<mailto:[email-masked]>> wrote:
Check that you send z_sync_flush at the end of your command. If you don't, the server won't read your CRLF.

Arnt

_______________________________________________
imapext mailing list
[email-masked]<mailto:[email-masked]>
https://www.ietf.org/mailman/listinfo/imapext