summaryrefslogtreecommitdiff
path: root/src/leap/mail/imap/server.py
AgeCommit message (Collapse)Author
2015-05-14[feat] adapt to new events api on commonIvan Alejandro
- Related: #6359
2015-04-28[feature] implement substring body fetchKali Kaneko
Current twisted implementation correctly parses partial fetches using substrings by use of angle brackets (see section 6.4.5 of imap rfc), but no use is made of the requested substring in the spew_body method. this commit minimally implements conformance to the substring request, although further boundary checks should be made (ie, checking whether the starting octet is beyond the end of the text). Resolves: #6841 Releases: 0.4.0
2015-03-23[bug] fix wrong case in the boundary passed in BODYSTRUCTUREKali Kaneko
By removing this call to lower(), we avoid a bug in which the BODYSTRUCTURE response returns a boundary all in lower case. Should send patch upstream to twisted. Related: #6773
2015-03-23[bug] add extra CRLF to avoid bad mime parsing in ThunderbirdKali Kaneko
Thunderbird (as of 37.0b1) will display a blank body (with no attachments) if some conditions are met: * disk synchronization is disabled * mime_part_on_demand = true * msg size is bigger than the parts_on_demand threshold (30000 by default). Comparing the logs with a well behaved imap server (dovecot, on this case), it's easy to see that twisted implementation is lacking an extra line separator at the end of each group of headers that is rendered in response to each of the `BODY.PEEK[X.MIME]` command that the mime_parts_on_demand will issue after getting the BODYSTRUCTURE. This change patches the spew_body command on the body server. We still would have to see if this is a bad behaviour in the thunderbird side. The most similar bug I've found is: https://bugzilla.mozilla.org/show_bug.cgi?id=149771 Which apparently was happening with exchange server. We should send the patch to upstream twisted as well. Note that this fix is not enough: the following commit, about fixing the case of the boundary passed in the BODYSTRUCTURE response is also needed to fix the bug (since a bad parsing happens all the same). Resolves: #6773, #5010 Documentation: #6773 Releases: 0.4.0
2015-02-20notify MUA on closing connectionKali Kaneko
2015-02-11save drafts: search by msg-idKali Kaneko
2015-02-11lots of little fixes after meskio's reviewKali Kaneko
mostly having to do with poor, missing or outdated documentation, naming of confusing things and reordering of code blocks for improved readability.
2015-02-11rename confusing attribute for accountKali Kaneko
2015-02-11imap: implement setting of message flagsKali Kaneko
2015-02-11imap: complete FETCH implementationKali Kaneko
2015-02-11patch cbSelect to accept deferreds for count*Kali Kaneko
2015-02-11Complete IMAP implementation, update testsKali Kaneko
2015-02-11adapt to soledad 0.7 async APIKali Kaneko
2014-02-26Implement non-synchronizing literals (rfc2088) Closes: #5190Kali Kaneko
This also paves the way to MULTIAPPEND IMAP Extension (rfc3502) Related to: Feature #5182
2014-02-17Remove notify_new callbacks from fetch and copy.Kali Kaneko
This fixes a bug with qtreactor that was making the 'OK foo copied' not being delivered. This or something similar will probably have to be re-added, because on the current state the destination folder will not receive the notification if it's selected *before* the copy operation has finished. But in this way we have a clean slate that is working properly. The bottleneck in the copy/append operations seems to have moved to the select operation now.
2014-02-17defer fetch to threadKali Kaneko
also, dispatch query for all headers to its own method.
2014-02-17call notify in reactorKali Kaneko
2014-02-17long-due update to unittests!Kali Kaneko
So we're safe under the green lights before further rewriting. :)
2014-02-17temporarily nuke out the fetch_heders diversionKali Kaneko
2014-02-02fix missing content after in-memory addKali Kaneko
because THE KEYS WILL BE STRINGS AFTER ADDED TO SOLEDAD Can I remember that? * Fix copy from local folders * Fix copy when we already have a copy of the message in the inbox, marked as deleted. * Fix also bad deferred.succeed in add_msg when it already exist.
2014-01-30Fix copy and deletion problemsKali Kaneko
* reorganize and simplify STORE command processing * add the notification after the processing of the whole sequence
2014-01-30docstring fixesKali Kaneko
Also some fixes for None comparisons.
2014-01-28handle last_uid property in memory storeKali Kaneko
2014-01-28Unset new flag after successful writeKali Kaneko
2014-01-28move server to its own fileKali Kaneko
2013-12-26Split the near-2k loc file into more handy modules.Kali Kaneko
...aaaand not a single fuck was given that day!
2013-12-26inlineCallbacks all the things!Kali Kaneko
2013-12-26Move flags and other metadata to a separate doc.Kali Kaneko
This change will allow for quicker access times, and smaller syncs since the fields that change more often will fall in a pretty small document. For the big raw message, we only need to sync once. Also, implemented multipart interface for messages. This will need additional migration helper in --repair-mailboxes.
2013-12-26defer costly operationsKali Kaneko
2013-12-24Fix parsing of IMAP folder names (#4830).drebs
2013-12-20Limit the size of the returned messages from IMAP to MUA to 100Tomás Touceda
2013-12-20fix wrong object callKali Kaneko
2013-12-20safety catch against wrong last_uidKali Kaneko
2013-12-20use soledad_writer for puts alsoKali Kaneko
2013-12-19deferToThread unsetting recent flagKali Kaneko
2013-12-13count_foo uses expanded u1db count method.Kali Kaneko
Other fixes in the commit: * Correct the semantic for the recent flag (reset) * Minor unicode fixes. * Use a field for tracking the last_uid In general, this tries to squash all the quick and naive methods that were relying on evaluating all the message objects before returning a result. Further work is still needed, planned also for 0.5 release. get_by_index needs to be indexed too.
2013-12-11consume messages eagerlyKali Kaneko
2013-11-28use messageproducer to write messages to soledadKali Kaneko
2013-11-26fix adding msg with empty flagsKali Kaneko
2013-11-26Fix fetch iteration on empty folderKali Kaneko
2013-11-13fix mail UID indexing for non-sequential uidsKali Kaneko
2013-11-11remove printKali Kaneko
2013-11-01notify MUA of new mail as it gets added to mailboxKali Kaneko
2013-10-31Refactor out get_email_charset to leap.commonTomás Touceda
2013-10-23pep8 fix: line too long.Ivan Alejandro
2013-10-23Remove commented imports.Ivan Alejandro
2013-10-23Add encoding exception catch to avoid crashes.Ivan Alejandro
2013-10-23Move charset parser to a utils module.Ivan Alejandro
2013-10-21Default to UTF-8 when there is not charset parsed from the mail contentsTomás Touceda
2013-10-03Improve charset handling for emailTomás Touceda