]> git.ipfire.org Git - thirdparty/dovecot/core.git/log
thirdparty/dovecot/core.git
9 years agolib: Fixed compiling unit test in systems where NULL isn't of type void*
Timo Sirainen [Fri, 27 Nov 2015 12:42:43 +0000 (14:42 +0200)] 
lib: Fixed compiling unit test in systems where NULL isn't of type void*
For example Solaris.

9 years agoauth: Fixed test-auth-request-var-expand unit test on big endian CPUs
Timo Sirainen [Fri, 27 Nov 2015 12:39:32 +0000 (14:39 +0200)] 
auth: Fixed test-auth-request-var-expand unit test on big endian CPUs

9 years agoCompiler warning fix for 32bit systems
Timo Sirainen [Fri, 27 Nov 2015 12:24:23 +0000 (14:24 +0200)] 
Compiler warning fix for 32bit systems

9 years agolib-storage: Don't add first_saved to mailbox list index unless autoexpunge is set.
Timo Sirainen [Fri, 27 Nov 2015 12:11:57 +0000 (14:11 +0200)] 
lib-storage: Don't add first_saved to mailbox list index unless autoexpunge is set.

9 years agoimap: Free mail_user only after client is disconnected.
Timo Sirainen [Fri, 27 Nov 2015 12:01:14 +0000 (14:01 +0200)] 
imap: Free mail_user only after client is disconnected.

9 years agoAdded mailbox { autoexpunge } setting.
Timo Sirainen [Fri, 27 Nov 2015 11:59:22 +0000 (13:59 +0200)] 
Added mailbox { autoexpunge } setting.
This can be used to automatically expunge mails from specified mailboxes
after they're old enough. The expunges are done when the user is being
deinitialized. mailbox_list_index=yes should be enabled to have the best
performance with this setting.

Example:

namespace inbox {
  mailbox Spam {
    auto = create
    special_use = \Junk
    autoexpunge = 30d
  }
}

9 years agoimap: SETMETADATA didn't set ostream output handler back
Timo Sirainen [Fri, 27 Nov 2015 11:06:01 +0000 (13:06 +0200)] 
imap: SETMETADATA didn't set ostream output handler back
This caused hangs afterwards when receiving long replies (e.g. FETCH).

9 years agoquota-clone: Avoid assert-crash when quota recalculation is triggered.
Timo Sirainen [Thu, 26 Nov 2015 13:42:35 +0000 (15:42 +0200)] 
quota-clone: Avoid assert-crash when quota recalculation is triggered.
Quota recalculation opened all mailboxes and got us back to
quota_clone_flush(), which caused another dict transaction to be opened,
which caused a crash with some dict backends.

9 years agolib-fts: Move ICU transliterator creation to fts-icu.h
Teemu Huovila [Wed, 25 Nov 2015 13:09:52 +0000 (15:09 +0200)] 
lib-fts: Move ICU transliterator creation to fts-icu.h
This allows others to use transliterators without so much code duplication.
The transliterator still has to be destroyed by the user, with utrans_close().

9 years agolib-fts: Fix compilation for systems without libicu.
Teemu Huovila [Wed, 25 Nov 2015 13:09:52 +0000 (15:09 +0200)] 
lib-fts: Fix compilation for systems without libicu.
The earlier patch, 194e3622d5e6, did not consider both library dependencies.

9 years agoimap: When logging command disconnection info, log the oldest command's info (not...
Timo Sirainen [Tue, 24 Nov 2015 11:42:58 +0000 (13:42 +0200)] 
imap: When logging command disconnection info, log the oldest command's info (not newest)

9 years agoimap: Added extra assert checks to make sure command states are consistent.
Timo Sirainen [Tue, 24 Nov 2015 11:41:58 +0000 (13:41 +0200)] 
imap: Added extra assert checks to make sure command states are consistent.

9 years agoimap: IDLE may have called client_continue_pending_input() unnecessarily.
Timo Sirainen [Tue, 24 Nov 2015 11:40:12 +0000 (13:40 +0200)] 
imap: IDLE may have called client_continue_pending_input() unnecessarily.

9 years agoimap: Fixed crash at FETCH deinit caused by b638e19d3bd4
Timo Sirainen [Tue, 24 Nov 2015 10:56:35 +0000 (12:56 +0200)] 
imap: Fixed crash at FETCH deinit caused by b638e19d3bd4
imap_fetch_free() would have been called twice, which caused problems.

9 years agoimap: Fixed hanging if a pipelined IMAP command was waiting for previous command...
Timo Sirainen [Tue, 24 Nov 2015 09:50:15 +0000 (11:50 +0200)] 
imap: Fixed hanging if a pipelined IMAP command was waiting for previous command to sync.
..And the previous command was waiting for the next command to finish before
it would start syncing. For example FETCH+LOGOUT pipelined.

9 years agodirector: Fixed backend selection when multiple tags were used.
Timo Sirainen [Tue, 24 Nov 2015 09:15:47 +0000 (11:15 +0200)] 
director: Fixed backend selection when multiple tags were used.
The previous algorithm was causing an uneven load for backends.

This change breaks compatibility with older director servers that were using
tags because of the different selection algorithm. The new director code
refuses to run within a cluster with old directors if tags are used.

9 years agodirector: Code cleanup - renamed hosts_unsorted to vhosts_unsorted
Timo Sirainen [Mon, 23 Nov 2015 17:47:08 +0000 (19:47 +0200)] 
director: Code cleanup - renamed hosts_unsorted to vhosts_unsorted

9 years agodirector: Code cleanup - rename tag to tag_name in mail_host_*() parameters.
Timo Sirainen [Mon, 23 Nov 2015 17:44:50 +0000 (19:44 +0200)] 
director: Code cleanup - rename tag to tag_name in mail_host_*() parameters.
In preparation for the following changes.

9 years agodirector: Code cleanup - access host->tag via mail_host_get_tag()
Timo Sirainen [Mon, 23 Nov 2015 17:41:38 +0000 (19:41 +0200)] 
director: Code cleanup - access host->tag via mail_host_get_tag()
In preparation for the following changes.

9 years agodirector: Code cleanup - make most mail_host_*() list parameters unnecessary.
Timo Sirainen [Mon, 23 Nov 2015 17:38:31 +0000 (19:38 +0200)] 
director: Code cleanup - make most mail_host_*() list parameters unnecessary.

9 years agodirector: With director_consistent_hashing=yes hosts_hash wasn't always calculated...
Timo Sirainen [Mon, 23 Nov 2015 17:35:03 +0000 (19:35 +0200)] 
director: With director_consistent_hashing=yes hosts_hash wasn't always calculated right.
If different servers had added hosts in different order, the hosts_hash
would have become different, which caused errors and resyncs.

9 years agolib-fts: Fix compilation for systems without libstemmer.
Teemu Huovila [Wed, 18 Nov 2015 14:33:26 +0000 (16:33 +0200)] 
lib-fts: Fix compilation for systems without libstemmer.

9 years agofts: Remove default filters and tokenizers.
Teemu Huovila [Wed, 18 Nov 2015 14:33:26 +0000 (16:33 +0200)] 
fts: Remove default filters and tokenizers.
There aren't any specially good defaults that work for all the languages,
so it's better to just enforce explicit settings.

9 years agofs-posix: Added mode=auto parameter to copy mode from parent directory if setgid...
Timo Sirainen [Thu, 19 Nov 2015 15:43:47 +0000 (17:43 +0200)] 
fs-posix: Added mode=auto parameter to copy mode from parent directory if setgid-bit is set

9 years agofs-posix: Code cleanup - don't store dir_mode permanently.
Timo Sirainen [Thu, 19 Nov 2015 15:19:19 +0000 (17:19 +0200)] 
fs-posix: Code cleanup - don't store dir_mode permanently.
Cleanup in preparation for mode=auto.

9 years agolib-fts: Silence clang warnings.
Teemu Huovila [Thu, 19 Nov 2015 15:39:46 +0000 (17:39 +0200)] 
lib-fts: Silence clang warnings.

9 years agofts plugin: Install fts-storage.h
Timo Sirainen [Thu, 19 Nov 2015 12:47:27 +0000 (14:47 +0200)] 
fts plugin: Install fts-storage.h

9 years agolib-fs: Added fs_stats_get_read/write_usecs()
Timo Sirainen [Thu, 19 Nov 2015 12:46:54 +0000 (14:46 +0200)] 
lib-fs: Added fs_stats_get_read/write_usecs()
These can be easily used to sum up all the timings for read and write
categories.

9 years agoindexer-worker: Use provided session-id only as a prefix for a unique session ID.
Timo Sirainen [Wed, 18 Nov 2015 19:06:17 +0000 (21:06 +0200)] 
indexer-worker: Use provided session-id only as a prefix for a unique session ID.
Fixes stats process's "Duplicate session ID" errors when LMTP delivers to
multiple recipients.

9 years agolib-storage: Added mail_storage_service_input.session_id_prefix
Timo Sirainen [Wed, 18 Nov 2015 19:03:41 +0000 (21:03 +0200)] 
lib-storage: Added mail_storage_service_input.session_id_prefix
This should make it easier to pass through the original session_id to worker
process sessions. Especially if these sessions are somewhat short-lived it
can be useful to assign them a unique session ID while still being able to
match it to the parent's session ID.

9 years agostats: Improved logging on invalid CONNECT input.
Timo Sirainen [Wed, 18 Nov 2015 18:50:55 +0000 (20:50 +0200)] 
stats: Improved logging on invalid CONNECT input.

9 years agostats: Forced sending of UPDATE-SESSION every 5 minutes wasn't working.
Timo Sirainen [Wed, 18 Nov 2015 17:15:36 +0000 (19:15 +0200)] 
stats: Forced sending of UPDATE-SESSION every 5 minutes wasn't working.
This caused stats process to forget about idling (imap) sessions if they
didn't do anything for over 15 minutes.

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.