]> git.ipfire.org Git - thirdparty/dovecot/core.git/log
thirdparty/dovecot/core.git
9 years agostats: When logging UPDATE-SESSION stats, log also the session ID.
Timo Sirainen [Wed, 18 Nov 2015 16:54:51 +0000 (18:54 +0200)] 
stats: When logging UPDATE-SESSION stats, log also the session ID.

9 years agolib-storage: Create ioloop context for users even if log prefix changing is disabled.
Timo Sirainen [Wed, 18 Nov 2015 16:10:46 +0000 (18:10 +0200)] 
lib-storage: Create ioloop context for users even if log prefix changing is disabled.
This fixes stats plugin to work with lmtp, imap-urlauth and doveadm-server.

9 years agolib-master: master_service_is_master_stopped() now returns FALSE if running standalone.
Timo Sirainen [Wed, 18 Nov 2015 15:45:35 +0000 (17:45 +0200)] 
lib-master: master_service_is_master_stopped() now returns FALSE if running standalone.
The only caller of this function was stats plugin to see if it should send
stats updates. So this fixes dovecot-lda, doveadm and other standalone tools
to send stats updates.

9 years agolib-master: Fixed timeout leak at deinit when we couldn't connect to ipc-server
Timo Sirainen [Wed, 18 Nov 2015 12:15:32 +0000 (14:15 +0200)] 
lib-master: Fixed timeout leak at deinit when we couldn't connect to ipc-server

9 years agopop3: When creating session lock file, prefer to write it to the index root dir.
Timo Sirainen [Wed, 18 Nov 2015 11:12:23 +0000 (13:12 +0200)] 
pop3: When creating session lock file, prefer to write it to the index root dir.
This is especially important for mail storage backends that don't have a mail
root directory.

9 years agopop3: Send "OK Logged in" before reading mailbox.
Timo Sirainen [Wed, 18 Nov 2015 11:08:57 +0000 (13:08 +0200)] 
pop3: Send "OK Logged in" before reading mailbox.
This way if the reading takes a long time, the client still sees that the
login itself was successful. This is especially useful to avoid unnecessary
errors logged by proxies.

9 years agoimap: Disconnection log message incorrectly logged "input/output" even if only "input...
Timo Sirainen [Wed, 18 Nov 2015 10:40:42 +0000 (12:40 +0200)] 
imap: Disconnection log message incorrectly logged "input/output" even if only "input" was set.

9 years agoimap: When disconnected during FETCH, include the last byte counts in disconnection...
Timo Sirainen [Wed, 18 Nov 2015 10:39:13 +0000 (12:39 +0200)] 
imap: When disconnected during FETCH, include the last byte counts in disconnection log message.

9 years agolib-fs: Improved fs-metawrap's fs_stat() error message.
Timo Sirainen [Tue, 17 Nov 2015 17:02:13 +0000 (19:02 +0200)] 
lib-fs: Improved fs-metawrap's fs_stat() error message.

9 years agolib-fs: Fixed fs_stat() for fs-metawrap
Timo Sirainen [Tue, 17 Nov 2015 17:01:29 +0000 (19:01 +0200)] 
lib-fs: Fixed fs_stat() for fs-metawrap

9 years ago*-login: Added postlogin_socket=path passdb extra field.
Timo Sirainen [Tue, 17 Nov 2015 15:26:56 +0000 (17:26 +0200)] 
*-login: Added postlogin_socket=path passdb extra field.
By default e.g. "imap" or "pop3" is the post-login socket, but this can
override it. This could be used for example for per-user debugging (e.g.
setting executable to be run via strace or valgrind).

9 years agolib-master: master_auth_request_full() now supports per-request path.
Timo Sirainen [Tue, 17 Nov 2015 15:23:31 +0000 (17:23 +0200)] 
lib-master: master_auth_request_full() now supports per-request path.

9 years agolib-master: Added extensible master_auth_request_full() call.
Timo Sirainen [Tue, 17 Nov 2015 15:11:05 +0000 (17:11 +0200)] 
lib-master: Added extensible master_auth_request_full() call.
Only the API was changed, no changes to functionality.

9 years agolib-fs: Added asserts to fs_set_metadata() to make sure key and value are non-NULL
Timo Sirainen [Tue, 17 Nov 2015 14:30:16 +0000 (16:30 +0200)] 
lib-fs: Added asserts to fs_set_metadata() to make sure key and value are non-NULL
Otherwise the bug would be noticed only much later when trying to
dereference NULL pointer.

9 years agofts: Added fts_library_init() and _deinit()
Teemu Huovila [Tue, 17 Nov 2015 09:51:45 +0000 (11:51 +0200)] 
fts: Added fts_library_init() and _deinit()
Replaces calling three different functions on init and deinit.

9 years agolib-fts: Added fts_language_register() to register more languages in plugins.
Teemu Huovila [Tue, 17 Nov 2015 09:50:16 +0000 (11:50 +0200)] 
lib-fts: Added fts_language_register() to register more languages in plugins.

9 years agodovecot-config: Added LIBFTS.
Teemu Huovila [Tue, 17 Nov 2015 09:46:49 +0000 (11:46 +0200)] 
dovecot-config: Added LIBFTS.

9 years agolib-fts: Explicitly state encoding used for stemming.
Teemu Huovila [Tue, 17 Nov 2015 09:45:44 +0000 (11:45 +0200)] 
lib-fts: Explicitly state encoding used for stemming.

9 years agolib-fts: Removed TODO comment.
Teemu Huovila [Tue, 17 Nov 2015 09:45:24 +0000 (11:45 +0200)] 
lib-fts: Removed TODO comment.
The call to uni_utf8_get_char_n() already does easy cases first.
Adding more special code paths is not necessary.

9 years agolib-fts: Minor code cleanup - Rename some internal functions.
Teemu Huovila [Tue, 17 Nov 2015 09:44:53 +0000 (11:44 +0200)] 
lib-fts: Minor code cleanup - Rename some internal functions.
Maybe the names are more logical this way.

9 years agolib-fts: Add Norwegian.
Teemu Huovila [Tue, 17 Nov 2015 09:44:19 +0000 (11:44 +0200)] 
lib-fts: Add Norwegian.
Norwegian has two main dialects, Bokmal(nb) and Nynorsk(nn). They
are detected separately by libexttextcat, but the stemmer only
knows Norwegian. Thus they are treated as a single language,
Norwegian (no). This might also make more sense in everyday
use of mixed writing style Norwegian.

Caveat: The default normalizer filter does not modify U+00F8
(Latin Small Letter O with Stroke). In some configurations it
might be desirable to rewrite it to e.g. o. Same goes for the
upper case version. This can be done by passing a modified "id"
setting to the normalizer filter.

9 years agolib-fts: Add comment to language names.
Teemu Huovila [Tue, 17 Nov 2015 09:43:58 +0000 (11:43 +0200)] 
lib-fts: Add comment to language names.
Languages are defined by their ISO 639-1 code, which is a two letters.
It is possible, that some languages with only a three letter code, ie.
a ISO 639-2 code, could be added in the future.

9 years agolib-fts: Add Swedish (sv) to supported languages.
Teemu Huovila [Tue, 17 Nov 2015 09:43:28 +0000 (11:43 +0200)] 
lib-fts: Add Swedish (sv) to supported languages.

9 years agolib-fts: Add l' contraction to French unit test.
Teemu Huovila [Tue, 17 Nov 2015 09:42:59 +0000 (11:42 +0200)] 
lib-fts: Add l' contraction to French unit test.

9 years agopop3-migration: Fixed memory leak in unit test.
Timo Sirainen [Mon, 16 Nov 2015 12:47:18 +0000 (14:47 +0200)] 
pop3-migration: Fixed memory leak in unit test.

9 years agolib-mail: Fixed istream-header-filter when callback excluded multiple headers.
Timo Sirainen [Mon, 16 Nov 2015 12:46:40 +0000 (14:46 +0200)] 
lib-mail: Fixed istream-header-filter when callback excluded multiple headers.
This only affected pop3-migration plugin.

9 years agodovecot.m4: Run valgrind with --trace-children=yes
Timo Sirainen [Mon, 16 Nov 2015 12:16:00 +0000 (14:16 +0200)] 
dovecot.m4: Run valgrind with --trace-children=yes
Some of the unit tests are run via shell and we want to check the unit tests
instead of just the shell.

9 years agoAdded Valgrind suppressions file for ignoring any bash memory leaks.
Timo Sirainen [Mon, 16 Nov 2015 12:15:02 +0000 (14:15 +0200)] 
Added Valgrind suppressions file for ignoring any bash memory leaks.
Some of the unit tests are run via shell.

9 years agodovecot.m4: Added --leak-check=full to valgrind
Timo Sirainen [Mon, 16 Nov 2015 10:40:22 +0000 (12:40 +0200)] 
dovecot.m4: Added --leak-check=full to valgrind

9 years agovarious - remove 8-bit characters from literal strings in test cases
Phil Carmody [Mon, 16 Nov 2015 10:29:51 +0000 (12:29 +0200)] 
various - remove 8-bit characters from literal strings in test cases
C has a portable way of expressing characters not in the basic character
set, namely \xNN escaping. Otherwise, the interpretation of the raw utf-8
is implentation dependent. This has the benefit of making some tests'
expected output more obvious, such as "=c3=a4" matching "\xC3\xA4", even
if it hinders the readability of some natural-language-based tests.

Signed-off-by: Phil Carmody <phil@dovecot.fi>
9 years agolib: fix memory leak of iterator in str_table_deinit()
Phil Carmody [Mon, 16 Nov 2015 10:29:21 +0000 (12:29 +0200)] 
lib: fix memory leak of iterator in str_table_deinit()
The deinit function uses an iterator, but never cleared it up. Found by
Valgrind.

Signed-off-by: Phil Carmody <phil@dovecot.fi>
9 years agolib: make test-istream-failure-at not leak memory
Phil Carmody [Mon, 16 Nov 2015 10:29:09 +0000 (12:29 +0200)] 
lib: make test-istream-failure-at not leak memory
This permits Valgrind to run without complaint.

Signed-off-by: Phil Carmody <phil@dovecot.fi>
9 years agolib: fix memory leaks in failure-at streams
Phil Carmody [Mon, 16 Nov 2015 10:27:03 +0000 (12:27 +0200)] 
lib: fix memory leaks in failure-at streams
The parent wasn't getting unref'ed, and would hang around for ever.

Signed-off-by: Phil Carmody <phil@dovecot.fi>
9 years agolib-master: stop tests from leaking memory
Phil Carmody [Mon, 16 Nov 2015 10:26:50 +0000 (12:26 +0200)] 
lib-master: stop tests from leaking memory
This permits Valgrind to run without complaint.

Signed-off-by: Phil Carmody <phil@dovecot.fi>
9 years agolib-http: free resources used in the tests
Phil Carmody [Mon, 16 Nov 2015 10:26:32 +0000 (12:26 +0200)] 
lib-http: free resources used in the tests
Signed-off-by: Phil Carmody <phil@dovecot.fi>
9 years agolib-http: ref/unref input stream in http message parser
Phil Carmody [Mon, 16 Nov 2015 10:26:06 +0000 (12:26 +0200)] 
lib-http: ref/unref input stream in http message parser
To prevent assidental disappearance of the stream while it's in use.
Also, the caller can create and forget - we'll do the cleanup later.

Signed-off-by: Phil Carmody <phil@dovecot.fi>
9 years agoimapc: Treat literal8 input the same as regular literal.
Timo Sirainen [Mon, 16 Nov 2015 10:24:53 +0000 (12:24 +0200)] 
imapc: Treat literal8 input the same as regular literal.
This is mainly for migrating away from broken servers (a patched Cyrus) that
send literal8 if a (corrupted) message contains NULs.

9 years agoimap: When client disconnects during a running command, log the command wait state.
Timo Sirainen [Thu, 12 Nov 2015 16:27:54 +0000 (18:27 +0200)] 
imap: When client disconnects during a running command, log the command wait state.

9 years agoimap: If IDLE or FETCH notices a disconnection, log the running command statistics.
Timo Sirainen [Thu, 12 Nov 2015 10:28:58 +0000 (12:28 +0200)] 
imap: If IDLE or FETCH notices a disconnection, log the running command statistics.

9 years agoimap: When client disconnects during a running command, log the IO input/output wait...
Timo Sirainen [Thu, 12 Nov 2015 10:17:04 +0000 (12:17 +0200)] 
imap: When client disconnects during a running command, log the IO input/output wait status.
This is mainly useful for debugging to make sure that the hang isn't
happening because of a bug (missing io) in Dovecot.

9 years agolib: Added io_loop_find_fd_conditions()
Timo Sirainen [Thu, 12 Nov 2015 10:14:20 +0000 (12:14 +0200)] 
lib: Added io_loop_find_fd_conditions()

9 years agoquota: When recalculating quota, don't try to access nonexistent autocreate-mailboxes.
Timo Sirainen [Thu, 12 Nov 2015 09:29:29 +0000 (11:29 +0200)] 
quota: When recalculating quota, don't try to access nonexistent autocreate-mailboxes.
There's no need to physically create them, since they're empty anyway.

9 years agologin proxy: If writing to ostream fails, log the ostream's error string.
Timo Sirainen [Wed, 11 Nov 2015 15:40:23 +0000 (17:40 +0200)] 
login proxy: If writing to ostream fails, log the ostream's error string.
Although for now it's always just based on the errno anyway.

9 years agologin proxy: Include some extra information in disconnect log lines.
Timo Sirainen [Wed, 11 Nov 2015 15:35:10 +0000 (17:35 +0200)] 
login proxy: Include some extra information in disconnect log lines.

9 years agoauth: Added hardcoded 5 second timeout to LDAP connect()
Timo Sirainen [Wed, 11 Nov 2015 11:15:30 +0000 (13:15 +0200)] 
auth: Added hardcoded 5 second timeout to LDAP connect()
Although it doesn't look like the timeout is exactly 5 seconds always due to
OpenSSL's internal workings, but this should be good enough.

9 years agopush-notification: Removed unused code.
Timo Sirainen [Tue, 10 Nov 2015 08:00:11 +0000 (10:00 +0200)] 
push-notification: Removed unused code.

9 years agovirtual: Include mailbox name in "Backend mailbox added by another session." error.
Timo Sirainen [Mon, 9 Nov 2015 12:49:26 +0000 (14:49 +0200)] 
virtual: Include mailbox name in "Backend mailbox added by another session." error.

9 years agoauth: Don't crash when trying to use CRYPT scheme when crypt() doesn't support DES
Timo Sirainen [Mon, 9 Nov 2015 12:11:12 +0000 (14:11 +0200)] 
auth: Don't crash when trying to use CRYPT scheme when crypt() doesn't support DES

9 years agolib-storage: Support %{userdb:*} variables in mail_home and mail_chroot settings.
Timo Sirainen [Mon, 9 Nov 2015 11:16:50 +0000 (13:16 +0200)] 
lib-storage: Support %{userdb:*} variables in mail_home and mail_chroot settings.

9 years agolib: Removed unnecessary includes from bits.h
Timo Sirainen [Mon, 9 Nov 2015 11:02:56 +0000 (13:02 +0200)] 
lib: Removed unnecessary includes from bits.h
All of them are already in lib.h, and bits.h gets included from lib.h.
This also solves a compiling problem for systems where stdint.h doesn't
exist.

9 years agoreplicator: Send initial status notification to master before listing all users
Timo Sirainen [Mon, 9 Nov 2015 07:31:48 +0000 (09:31 +0200)] 
replicator: Send initial status notification to master before listing all users
To avoid master process from killing us after 30 seconds if the user listing
takes longer than that.

9 years agoauth: Fixed crash when using %{passdb:} or %{userdb:} functions when escape_func...
Timo Sirainen [Thu, 5 Nov 2015 09:41:52 +0000 (11:41 +0200)] 
auth: Fixed crash when using %{passdb:} or %{userdb:} functions when escape_func was NULL
Patch by Michael Slusarz.

9 years agolib: test-istream-crlf - fix expected output strings, add more coverage
Phil Carmody [Wed, 4 Nov 2015 09:39:58 +0000 (11:39 +0200)] 
lib: test-istream-crlf - fix expected output strings, add more coverage
Fix an out-by-one which was missing trailing carriage returns in _lf mode.

Debug: input = [19]:``...........N.N....R''
Debug: output= [19]:``...........N.N....R''
Debug: data  = [18]:``...........N.N....''
test-istream-crlf.c:78: Assert(#20) failed: size == str_len(output)

Add some randomised tests to get better coverage of all possibilities.

Signed-off-by: Phil Carmody <phil@dovecot.fi>
9 years agopush-notification: Fix linking against notify plugin
Michael M Slusarz [Wed, 28 Oct 2015 03:54:26 +0000 (21:54 -0600)] 
push-notification: Fix linking against notify plugin

9 years agoimap: Fixed crash in NOTIFY when there were watched namespaces that didn't support...
Timo Sirainen [Thu, 29 Oct 2015 13:29:24 +0000 (15:29 +0200)] 
imap: Fixed crash in NOTIFY when there were watched namespaces that didn't support NOTIFY.

9 years agodsync: Fixed handling of deleted directories.
Timo Sirainen [Thu, 29 Oct 2015 13:06:16 +0000 (15:06 +0200)] 
dsync: Fixed handling of deleted directories.
We may still know about the directory node even if it doesn't exist, and we
still want to delete it.

9 years agoauth: Avoid a crash by not trying to save empty delayed credentials.
Timo Sirainen [Thu, 29 Oct 2015 12:09:52 +0000 (14:09 +0200)] 
auth: Avoid a crash by not trying to save empty delayed credentials.

9 years agoacl: acl_object_list_*() now duplicates rights at init to avoid them changing during...
Timo Sirainen [Thu, 29 Oct 2015 10:55:20 +0000 (12:55 +0200)] 
acl: acl_object_list_*() now duplicates rights at init to avoid them changing during listing.
Depending on the calling code the acl_object could have been refreshed
during the listing and caused bugs/crashes.

This fixes a crash at least in mailbox deletion during attribute deletion
where iter->idx was higher (2) than the number of rights at the time (0).

9 years agoauth: Typofix for error message.
Timo Sirainen [Wed, 28 Oct 2015 10:28:12 +0000 (12:28 +0200)] 
auth: Typofix for error message.

9 years agoauth: nopassword field is specific to a single passdb, remove before next passdb...
Timo Sirainen [Wed, 28 Oct 2015 10:25:08 +0000 (12:25 +0200)] 
auth: nopassword field is specific to a single passdb, remove before next passdb is processed

9 years agolib-mail, fts: Put application/xhtml+xml MIME parts through html parser as well.
Timo Sirainen [Tue, 27 Oct 2015 21:56:48 +0000 (23:56 +0200)] 
lib-mail, fts: Put application/xhtml+xml MIME parts through html parser as well.

9 years agoacl: If mailbox is autocreated, assume it already exists and don't require "create...
Timo Sirainen [Mon, 26 Oct 2015 15:20:49 +0000 (17:20 +0200)] 
acl: If mailbox is autocreated, assume it already exists and don't require "create" ACL

9 years agoacl: Fixed handling mailbox deletion when only "delete" right was available.
Timo Sirainen [Mon, 26 Oct 2015 14:28:51 +0000 (16:28 +0200)] 
acl: Fixed handling mailbox deletion when only "delete" right was available.
So especially when there were no "lookup" or "read" rights.

9 years agoauth: Fixed userdb changing username via auth-worker
Timo Sirainen [Fri, 23 Oct 2015 12:21:15 +0000 (15:21 +0300)] 
auth: Fixed userdb changing username via auth-worker

9 years agonotify plugin: Don't access already freed memory.
Timo Sirainen [Thu, 22 Oct 2015 13:59:01 +0000 (16:59 +0300)] 
notify plugin: Don't access already freed memory.
In the same changeset I even added a comment just above that it shouldn't be
accessed..

9 years agoquota-dict: Added "no-unset" parameter.
Timo Sirainen [Thu, 22 Oct 2015 10:55:27 +0000 (13:55 +0300)] 
quota-dict: Added "no-unset" parameter.

9 years agoLAYOUT=index: Fixed error handling in mailbox creation race condition.
Timo Sirainen [Wed, 21 Oct 2015 16:12:45 +0000 (19:12 +0300)] 
LAYOUT=index: Fixed error handling in mailbox creation race condition.
If two processes create the same mailbox, the other one ends up being
deleted on failure. However, if the deletion itself also failed the state
becomes a big ambiguous. We don't want to return MAIL_ERROR_EXISTS in that
case, because the caller may try to open the mailbox with the inconsistent
state and fail. So we'll instead return the original mailbox_delete() error
to the caller.

9 years agologin proxy: Separate admin kicks, director kicks and shutdowns in log messages.
Timo Sirainen [Wed, 21 Oct 2015 12:50:31 +0000 (15:50 +0300)] 
login proxy: Separate admin kicks, director kicks and shutdowns in log messages.

9 years agossl_options: Added support for no_ticket
Timo Sirainen [Wed, 21 Oct 2015 10:32:58 +0000 (13:32 +0300)] 
ssl_options: Added support for no_ticket

9 years agodoveadm fs: Log also the exact reason for "file doesn't exist"
Timo Sirainen [Tue, 20 Oct 2015 18:23:03 +0000 (21:23 +0300)] 
doveadm fs: Log also the exact reason for "file doesn't exist"

9 years agodict: Show number of clients in process title
Timo Sirainen [Tue, 20 Oct 2015 17:15:20 +0000 (20:15 +0300)] 
dict: Show number of clients in process title

9 years agolib-index: tail_offset wasn't updated as often as it should have been.
Timo Sirainen [Tue, 20 Oct 2015 15:43:32 +0000 (18:43 +0300)] 
lib-index: tail_offset wasn't updated as often as it should have been.
ctx->last_tail_offset was being increased for every non-external transaction
and at the end we checked if head was larger than it. This logic didn't
really make any sense, since non-external transactions specifically were
supposed to update the tail_offset.

9 years agolib-imap-storage: Mark METADATA transactions as external.
Timo Sirainen [Tue, 20 Oct 2015 15:22:53 +0000 (18:22 +0300)] 
lib-imap-storage: Mark METADATA transactions as external.
We never write the metadata values to any storage backend, so they also
don't need to be explicitly synced.

9 years agomysql: Added connect/read/write_timeout settings. Default to 30s read/write_timeout.
Timo Sirainen [Tue, 20 Oct 2015 14:07:20 +0000 (17:07 +0300)] 
mysql: Added connect/read/write_timeout settings. Default to 30s read/write_timeout.

9 years agomysql: Fixed client_flags parameter
Timo Sirainen [Tue, 20 Oct 2015 13:57:34 +0000 (16:57 +0300)] 
mysql: Fixed client_flags parameter

9 years agomysql: Use the correct way of setting a connect timeout.
Timo Sirainen [Tue, 20 Oct 2015 13:56:23 +0000 (16:56 +0300)] 
mysql: Use the correct way of setting a connect timeout.
I'm not sure if this didn't exist earlier, or if I just somehow missed it.

9 years agodsync: Added DSYNC_BRAIN_FLAG_NO_NOTIFY to enable MAILBOX_TRANSACTION_FLAG_NO_NOTIFY
Timo Sirainen [Tue, 20 Oct 2015 12:29:07 +0000 (15:29 +0300)] 
dsync: Added DSYNC_BRAIN_FLAG_NO_NOTIFY to enable MAILBOX_TRANSACTION_FLAG_NO_NOTIFY
It's arguable that this should be enabled by default, but people might like
to keep mail_log notifications for dsync.

9 years agolib-storage/notify: Added MAILBOX_TRANSACTION_FLAG_NO_NOTIFY
Timo Sirainen [Tue, 20 Oct 2015 12:27:42 +0000 (15:27 +0300)] 
lib-storage/notify: Added MAILBOX_TRANSACTION_FLAG_NO_NOTIFY
This flag could potentially apply for other things as well, not just notify
plugin. In general anything that could do external notifications shouldn't
do anything for transactions with this flag.

9 years agodict-sql: Fixed async iteration with MySQL and SQLite
Timo Sirainen [Tue, 20 Oct 2015 10:12:24 +0000 (13:12 +0300)] 
dict-sql: Fixed async iteration with MySQL and SQLite

9 years agolib-charset: Added UTF-7 iconv() unit test
Timo Sirainen [Mon, 19 Oct 2015 21:25:14 +0000 (00:25 +0300)] 
lib-charset: Added UTF-7 iconv() unit test
Possibly crashes on FreeBSD? Not verified yet. But a good test in any case.

9 years agolib-charset: Run iconv unit tests by giving iconv() new data 1 byte at a time.
Timo Sirainen [Mon, 19 Oct 2015 21:23:56 +0000 (00:23 +0300)] 
lib-charset: Run iconv unit tests by giving iconv() new data 1 byte at a time.

9 years agoimapc: Set storage's error to "internal error" if we detect mailbox state corruption.
Timo Sirainen [Mon, 19 Oct 2015 11:29:10 +0000 (14:29 +0300)] 
imapc: Set storage's error to "internal error" if we detect mailbox state corruption.
This fixes "unknown internal error" in at least syncing code when an
expunged message reappears.

9 years agolib: net_gethostbyname() now supports [ipv6] style bracketed addresses.
Timo Sirainen [Mon, 19 Oct 2015 11:05:26 +0000 (14:05 +0300)] 
lib: net_gethostbyname() now supports [ipv6] style bracketed addresses.

9 years agodirector: Fix to previous change - mail_host_dup() wasn't strdup()ing hostname.
Timo Sirainen [Mon, 19 Oct 2015 11:04:46 +0000 (14:04 +0300)] 
director: Fix to previous change - mail_host_dup() wasn't strdup()ing hostname.
This could have caused a crash at deinit.

9 years agodirector: Remember backends' hostnames and send them in login reply.
Timo Sirainen [Mon, 19 Oct 2015 10:49:54 +0000 (13:49 +0300)] 
director: Remember backends' hostnames and send them in login reply.
This allows login processes to verify the remote server's hostname in SSL
certificate.

9 years agodirector: Small code cleanup - make it easier to add parameters to HOST
Timo Sirainen [Mon, 19 Oct 2015 10:40:52 +0000 (13:40 +0300)] 
director: Small code cleanup - make it easier to add parameters to HOST

9 years agoman: Changed "pattern" to "string" in doveamd-search-query(7)
Timo Sirainen [Mon, 19 Oct 2015 10:37:25 +0000 (13:37 +0300)] 
man: Changed "pattern" to "string" in doveamd-search-query(7)

9 years agolib-mail: fix html2text parser
Phil Carmody [Thu, 15 Oct 2015 11:44:03 +0000 (14:44 +0300)] 
lib-mail: fix html2text parser
Silly typo. Fixes bug reported on dovecot list by Akash on Oct 14.

Signed-off-by: Phil Carmody <phil@dovecot.fi>
9 years agodsync: If rename algorithm seems go to an infinite loop, log an error and stop.
Timo Sirainen [Wed, 14 Oct 2015 14:34:23 +0000 (17:34 +0300)] 
dsync: If rename algorithm seems go to an infinite loop, log an error and stop.
Ideally we would of course fix the algorithm (especially to not require this
kind of looping).

9 years agoimap/pop3-login: If LOGIN/USER is used with plaintext auth disabled, remember the...
Timo Sirainen [Wed, 14 Oct 2015 14:28:11 +0000 (17:28 +0300)] 
imap/pop3-login: If LOGIN/USER is used with plaintext auth disabled, remember the username for logging.
It's still useful to see the username that was sent in the logout message.
This won't work for AUTHENTICATE PLAIN, but hopefully the clients that use
it understand the LOGINDISABLED capability better.

9 years agocassandra: Added read/write/delete_fallback_consistency settings.
Timo Sirainen [Wed, 14 Oct 2015 11:06:35 +0000 (14:06 +0300)] 
cassandra: Added read/write/delete_fallback_consistency settings.
The fallback is attempted if the primary consistency can't be satisfied.
One useful use case for this is to have:

write_consistency=each-quorum
write_fallback_consistency=local-quorum

Which means that during regular operation all writes go to all data centers
before they are finished, but if one of the data centers go down we'll
switch to just waiting for local data center writes to finish.

9 years agodict-sql: dict_lookup_async() didn't call callback on query build failures.
Timo Sirainen [Wed, 14 Oct 2015 10:32:02 +0000 (13:32 +0300)] 
dict-sql: dict_lookup_async() didn't call callback on query build failures.

9 years agolib-storage: Support latest cache fields in struct mailbox_metadata.precache_fields
Timo Sirainen [Tue, 13 Oct 2015 18:57:29 +0000 (21:57 +0300)] 
lib-storage: Support latest cache fields in struct mailbox_metadata.precache_fields

9 years agoimap: APPEND crashed if invalid keyword was given as parameter.
Timo Sirainen [Tue, 13 Oct 2015 18:40:33 +0000 (21:40 +0300)] 
imap: APPEND crashed if invalid keyword was given as parameter.

9 years agoauth ldap: If tls_* settings are used, pass them to LDAP library even if tls=no
Timo Sirainen [Tue, 13 Oct 2015 18:21:48 +0000 (21:21 +0300)] 
auth ldap: If tls_* settings are used, pass them to LDAP library even if tls=no
Most importantly this allows using the settings for ldaps URLs. And they
hopefully won't hurt anything if neither STARTTLS nor ldaps are used.

9 years agolib: uri_parser_init() wasn't using pool parameter for anything.
Timo Sirainen [Tue, 13 Oct 2015 17:41:36 +0000 (20:41 +0300)] 
lib: uri_parser_init() wasn't using pool parameter for anything.
Now everything is allocated from it instead of from data stack.

9 years agodict-sql: Added support for value_type field, which deprecates value_hexblob.
Timo Sirainen [Tue, 13 Oct 2015 17:40:38 +0000 (20:40 +0300)] 
dict-sql: Added support for value_type field, which deprecates value_hexblob.
value_type=string|hexblob|uint are supported now.

9 years agocassandra: Added support for returning "int" type values.
Timo Sirainen [Tue, 13 Oct 2015 17:39:50 +0000 (20:39 +0300)] 
cassandra: Added support for returning "int" type values.
It looks like we need to explicitly convert all types to strings.

9 years agoauth: passwd-file now stat()s the file max once per second.
Timo Sirainen [Tue, 13 Oct 2015 10:44:48 +0000 (13:44 +0300)] 
auth: passwd-file now stat()s the file max once per second.
It's quite unnecessary to do it more often.

9 years agofs-dict: Implemented hex-encoding for values.
Timo Sirainen [Mon, 12 Oct 2015 14:12:17 +0000 (17:12 +0300)] 
fs-dict: Implemented hex-encoding for values.