| Commit message (Collapse) | Author | Age | Files |
... | |
|
|
|
|
|
|
|
| |
This is useful for synchronizing multiple remote servers against
different namespaces belonging to the same local IMAP server (using a
different InterIMAP instance for each local namespace ↔ remote
synchronization, for instance with the newy provided systemd template
unit file).
|
|
|
|
|
|
| |
Rather than two pipe(2). Also, use SOCK_CLOEXEC to save a fcntl() call
when setting the close-on-exec flag on the socket (even though Perl will
likely call fcntl() anyway).
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
SQLite processes every INTEGER values as a 8-byte signed integer, so we
need to manually do the conversion from/to uint64_t client-side if we
don't want to overflow or receive floats.
https://www.sqlite.org/datatype3.html#storage_classes_and_datatypes
http://jakegoulding.com/blog/2011/02/06/sqlite-64-bit-integers/
We could also do the same trick for local/remote UIDs, UIDVALITY and
UIDNEXT values to slim the database down at the expense of pre/post-
processing. (Values of SQLite's INTEGER class are 1, 2, 3, 4, 6, or 8
bytes signed integers depending on the manitudes, so we could save some
space for values ≥2³¹.) But that seems a little overkill.
|
|
|
|
|
|
|
|
| |
Setting the 'foreign_keys' PRAGMA during a multi-statement transaction
(when SQLite is not in autocommit mode) is a no-op.
https://www.sqlite.org/pragma.html#pragma_foreign_keys
https://www.sqlite.org/foreignkeys.html#fk_enable
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Following recommendation from
https://www.imapwiki.org/ClientImplementation/MailboxList#Hierarchy_separators
Instead, use null characters internally, and substitute them with the
local and remote hierarchy delimiters (which thus no longer need to
match) for IMAP commands. This require a database schema upgrade to
alter the mailbox name column type from TEXT to BLOB. We're using
SQLite's user_version PRAGMA to keep track of schema version; beware
that `.dump` doesn't export its value!
In logging messages, local and remote mailbox names are shown as is
(with their respective delimiters) while database mailbox names are
shown by replacing null characters with the *local* hierarchy delimiter.
Moreover for mailbox names specified on the command line or the
configuration file (with the "list-mailbox" option) the *local*
hierarchy delimiter should be used.
|
|
|
|
| |
Also, accept comma-separated values for --target.
|
|
|
|
|
|
| |
This never happens for a single LIST command, but may happen if
mailboxes from different namespaces are being listed. The workaround
here is to run a new interimap instance for each namespace.
|
|
|
|
|
| |
This is useful for defining names containing control characters (incl.
\0 for unspecified hierarchy delimiter).
|
|
|
|
| |
Also, write which --target to use in --delete command suggestions.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Not 1*ATOM-CHAR / string. Also accept LIST responses mailbox names
containing '%', '*', or ']'.
From RFC 3501:
astring = 1*ASTRING-CHAR / string
ASTRING-CHAR = ATOM-CHAR / resp-specials
list = "LIST" SP mailbox SP list-mailbox
list-mailbox = 1*list-char / string
list-char = ATOM-CHAR / list-wildcards / resp-specials
list-wildcards = "%" / "*"
resp-specials = "]"
|
|
|
|
|
| |
Compression asside, this saves 3 bytes and one round-trip on servers not
supporting non-synchronizing literals, and 4 bytes otherwise.
|
|
|
|
|
| |
The were returned as escaped quoted specials, like "\\", not as a single
character (backslash in this case).
|
| |
|
| |
|
| |
|
| |
|
| |
|
|
|
|
|
|
|
| |
Also, change "SSL_protocols" default value from "!SSLv2 !SSLv3" to
"!SSLv2 !SSLv3 !TLSv1 !TLSv1.1". I.e., only enable TLSv1.2 and later,
which is the default in Debian's OpenSSL as of 1.1.1-2, cf.
https://tracker.debian.org/news/998835/accepted-openssl-111-2-source-into-unstable/ .
|
| |
|
| |
|
| |
|
| |
|
| |
|
| |
|
| |
|
| |
|
| |
|
| |
|
| |
|
| |
|
| |
|
| |
|
| |
|
| |
|
| |
|
| |
|
| |
|
| |
|
| |
|
| |
|
| |
|
| |
|
| |
|
| |
|
| |
|
| |
|
| |
|
| |
|
| |
|
| |
|