]> git.ipfire.org Git - thirdparty/dovecot/core.git/log
thirdparty/dovecot/core.git
8 years agolib-storage: Fix ACL in parent mailbox potentially hiding its children.
Timo Sirainen [Tue, 30 May 2017 06:18:14 +0000 (09:18 +0300)] 
lib-storage: Fix ACL in parent mailbox potentially hiding its children.

fs_get_existence_info_flag() was only being called with LAYOUT=fs and
Maildir combination, so only it was broken if the parent mailbox wasn't
visible but its children were.

8 years agolib-storage: fs_list_get_mailbox_flags() - Return mailbox files as selectable
Timo Sirainen [Tue, 30 May 2017 06:15:09 +0000 (09:15 +0300)] 
lib-storage: fs_list_get_mailbox_flags() - Return mailbox files as selectable

Avoids a second stat() later on, which would do the same anyway.

8 years agolib-storage: fs_list_get_mailbox_flags() - Don't assume directories always have children.
Timo Sirainen [Tue, 30 May 2017 06:12:05 +0000 (09:12 +0300)] 
lib-storage: fs_list_get_mailbox_flags() - Don't assume directories always have children.

This makes the directory handling code equivalent for type==UNKNOWN and
type==DIR.

8 years agolib-storage: fs_list_get_mailbox_flags() - Add comments
Timo Sirainen [Tue, 30 May 2017 06:10:55 +0000 (09:10 +0300)] 
lib-storage: fs_list_get_mailbox_flags() - Add comments

8 years agolib-storage: fs_list_get_mailbox_flags() - Reorganize code
Timo Sirainen [Tue, 30 May 2017 06:09:39 +0000 (09:09 +0300)] 
lib-storage: fs_list_get_mailbox_flags() - Reorganize code

No functional changes.

8 years agoacl: Global ACL file was parsed as if it was local ACL file
Timo Sirainen [Mon, 29 May 2017 14:58:35 +0000 (17:58 +0300)] 
acl: Global ACL file was parsed as if it was local ACL file

This caused some of the ACL handling not work exactly as expected.

8 years agolib-storage: Make mailbox_list_iter_init_autocreate() static again
Timo Sirainen [Mon, 29 May 2017 14:26:52 +0000 (17:26 +0300)] 
lib-storage: Make mailbox_list_iter_init_autocreate() static again

It's no longer needed elsewhere.

8 years agolib-storage: Fix mailbox_list_index=yes + ACLs + auto=subscribe mailboxes
Timo Sirainen [Mon, 29 May 2017 14:20:48 +0000 (17:20 +0300)] 
lib-storage: Fix mailbox_list_index=yes + ACLs + auto=subscribe mailboxes

If the auto=subscribe mailbox didn't have a lookup ACL, it shouldn't have
been listed. This didn't work properly, because ACL plugin initialized the
autocreate_ctx only for the index iterator, while the autoboxes were
listed using the backend iterator. Fixed by not creating index iterator at
all when doing a passthrough iteration.

8 years agolib-storage: Cleanup - Don't use ctx in iter_use_index()
Timo Sirainen [Mon, 29 May 2017 13:44:44 +0000 (16:44 +0300)] 
lib-storage: Cleanup - Don't use ctx in iter_use_index()

Shrinks the following change.

8 years agolib-storage: Add \NoInferiors flag to autocreated mailboxes with mbox
Timo Sirainen [Mon, 29 May 2017 12:52:15 +0000 (15:52 +0300)] 
lib-storage: Add \NoInferiors flag to autocreated mailboxes with mbox

Once the mailboxes get autocreated, the \NoInferiors flag is added anyway.

8 years agolib-storage: Don't list duplicate autocreated mailboxes' parents
Timo Sirainen [Mon, 29 May 2017 12:30:36 +0000 (15:30 +0300)] 
lib-storage: Don't list duplicate autocreated mailboxes' parents

8 years agoacl: Skip auto=create|subscribe mailboxes that don't have lookup-right
Timo Sirainen [Mon, 29 May 2017 10:53:17 +0000 (13:53 +0300)] 
acl: Skip auto=create|subscribe mailboxes that don't have lookup-right

Removing them entirely from the boxes and box_sets arrays in the list
context treats them as if they weren't configured at all. This way they
don't need any other special code.

8 years agolib-storage: Add mailbox-list-iter-private.h with autocreate context structs
Timo Sirainen [Mon, 29 May 2017 10:52:42 +0000 (13:52 +0300)] 
lib-storage: Add mailbox-list-iter-private.h with autocreate context structs

Needed for the following ACL change.

8 years agolib-storage: Log an info message when dovecot.index.pvt UIDVALIDITY changes
Timo Sirainen [Wed, 24 May 2017 08:50:08 +0000 (11:50 +0300)] 
lib-storage: Log an info message when dovecot.index.pvt UIDVALIDITY changes

8 years agolib-storage: When initializing dovecot.index.pvt, don't reset it.
Timo Sirainen [Wed, 24 May 2017 08:47:54 +0000 (11:47 +0300)] 
lib-storage: When initializing dovecot.index.pvt, don't reset it.

This avoids unnecessary errors about index being reset when it was already
empty.

8 years agolib-storage: Cleanup - Remove pointless if-check
Timo Sirainen [Wed, 24 May 2017 08:41:29 +0000 (11:41 +0300)] 
lib-storage: Cleanup - Remove pointless if-check

8 years agolib-http: client: Only drop queued requests when a DNS lookup fails; not also the...
Stephan Bosch [Wed, 24 May 2017 18:19:11 +0000 (20:19 +0200)] 
lib-http: client: Only drop queued requests when a DNS lookup fails; not also the ones that are already in progress.

8 years agolib-http: client: When a request is destroyed prematurely during payload input, consi...
Stephan Bosch [Wed, 24 May 2017 19:59:32 +0000 (21:59 +0200)] 
lib-http: client: When a request is destroyed prematurely during payload input, consider the payload stream destroyed and act accordingly.

The application may hold a reference to the payload stream still, and it may be difficult to prevent that.
This causes lib-http to keep waiting for the payload to be destroyed.
When nothing else is going on, the current ioloop may then become empty, which caused the familiar assert failure.

8 years agolib-http: client: Explicitly destroy the response payload timeout stream when the...
Stephan Bosch [Wed, 24 May 2017 17:08:43 +0000 (19:08 +0200)] 
lib-http: client: Explicitly destroy the response payload timeout stream when the request is destroyed while receiving payload.

This way, the timeout is stopped.
This caused ioloop panics.

8 years agoquota: Fix infinite loop when parsing quota parameters
Timo Sirainen [Wed, 24 May 2017 15:27:10 +0000 (18:27 +0300)] 
quota: Fix infinite loop when parsing quota parameters

Broken by previous quota changes.

8 years agolib-storage: Fix crash in test-mail-storage
Timo Sirainen [Wed, 24 May 2017 20:49:43 +0000 (23:49 +0300)] 
lib-storage: Fix crash in test-mail-storage

8 years agolib-storage: Fix memory leak in test-mail-storage
Timo Sirainen [Wed, 24 May 2017 19:31:59 +0000 (22:31 +0300)] 
lib-storage: Fix memory leak in test-mail-storage

8 years agolib-storage: Add unit test for set/get/push/pop storage error operations
Timo Sirainen [Wed, 24 May 2017 18:56:03 +0000 (21:56 +0300)] 
lib-storage: Add unit test for set/get/push/pop storage error operations

8 years agolib-storage: Fix mail_storage_set_critical() when input parameter is an old internal...
Timo Sirainen [Wed, 24 May 2017 18:29:49 +0000 (21:29 +0300)] 
lib-storage: Fix mail_storage_set_critical() when input parameter is an old internal error

This could have caused garbage in the error string.

8 years agolib-storage: Fix mail_storage_last_error_push/pop() to work with internal errors
Timo Sirainen [Wed, 24 May 2017 16:16:03 +0000 (19:16 +0300)] 
lib-storage: Fix mail_storage_last_error_push/pop() to work with internal errors

8 years agolib-master: Replace listeners with /dev/null in SIGQUIT instead of closing
Timo Sirainen [Wed, 24 May 2017 14:19:36 +0000 (17:19 +0300)] 
lib-master: Replace listeners with /dev/null in SIGQUIT instead of closing

This should be somewhat safer.

8 years agoWhitespace cleanup
Sergey Kitov [Fri, 19 May 2017 08:00:22 +0000 (11:00 +0300)] 
Whitespace cleanup

8 years agoDict backend parameters reading changed to use common parsing function
Sergey Kitov [Fri, 19 May 2017 07:58:52 +0000 (10:58 +0300)] 
Dict backend parameters reading changed to use common parsing function

8 years agofs backend parameter parsing changed to use common function
Sergey Kitov [Fri, 19 May 2017 07:57:02 +0000 (10:57 +0300)] 
fs backend parameter parsing changed to use common function

8 years agoimapc backend parameter parsing changed to use common function
Sergey Kitov [Fri, 19 May 2017 07:52:46 +0000 (10:52 +0300)] 
imapc backend parameter parsing changed to use common function

8 years agomaildir backend parameter parsing changed to use common function
Sergey Kitov [Fri, 19 May 2017 07:49:01 +0000 (10:49 +0300)] 
maildir backend parameter parsing changed to use common function

8 years agoquota root default init changed to use common param parse function
Sergey Kitov [Fri, 19 May 2017 07:46:27 +0000 (10:46 +0300)] 
quota root default init changed to use common param parse function

8 years agocommon quota parameter parsing function implemented
Sergey Kitov [Thu, 18 May 2017 10:30:25 +0000 (13:30 +0300)] 
common quota parameter parsing function implemented

8 years agoimap: Fix unhibernation after earlier change
Timo Sirainen [Mon, 22 May 2017 14:56:15 +0000 (17:56 +0300)] 
imap: Fix unhibernation after earlier change

8 years agolib-index: Fix crash in mail_transaction_log_view_set_all() error handling
Timo Sirainen [Mon, 22 May 2017 07:13:21 +0000 (10:13 +0300)] 
lib-index: Fix crash in mail_transaction_log_view_set_all() error handling

8 years agolib-index: Fix start_offset > sync_offset error handling for in-memory indexes
Timo Sirainen [Mon, 22 May 2017 07:11:30 +0000 (10:11 +0300)] 
lib-index: Fix start_offset > sync_offset error handling for in-memory indexes

8 years agoconfig: When showing an "Unknown setting" error, show the full section path
Timo Sirainen [Sat, 20 May 2017 15:13:45 +0000 (18:13 +0300)] 
config: When showing an "Unknown setting" error, show the full section path

For example with:

service foo {
  inet_listener bar {
    key = value
  }
}

Instead of showing just:

Unknown setting: key

Show the entire path:

Unknown setting: service { inet_listener { key

Any filters won't be shown, because they don't affect the result.

8 years agoimap: Move struct client_sync_context to imap-sync-private.h and add imap_ prefix
Timo Sirainen [Fri, 19 May 2017 14:44:30 +0000 (17:44 +0300)] 
imap: Move struct client_sync_context to imap-sync-private.h and add imap_ prefix

8 years agoimap: Allow plugins to replace existing FETCH handlers
Timo Sirainen [Fri, 19 May 2017 13:34:29 +0000 (16:34 +0300)] 
imap: Allow plugins to replace existing FETCH handlers

They can use imap_fetch_handler_lookup() to get the old init() function.
Then they can imap_fetch_handler_unregister() the existing handler and
register a new handler, which can do its own work and call the old init()
if needed.

8 years agolib-index: Improve "start_offset > current sync_offset" error message.
Timo Sirainen [Wed, 17 May 2017 13:47:43 +0000 (16:47 +0300)] 
lib-index: Improve "start_offset > current sync_offset" error message.

Try to make it clear what is the root cause of it.

8 years agolib-index: mail_transaction_log_file_get_highest_modseq_at() - return error string
Timo Sirainen [Wed, 17 May 2017 13:28:58 +0000 (16:28 +0300)] 
lib-index: mail_transaction_log_file_get_highest_modseq_at() - return error string

This can help figuring out why some error happened when more context is
provided in the caller's error messages.

8 years agolib-index: Add missing error logging for mail_index_view_sync_begin()
Timo Sirainen [Wed, 17 May 2017 13:21:54 +0000 (16:21 +0300)] 
lib-index: Add missing error logging for mail_index_view_sync_begin()

8 years agolib-index: mail_transaction_log_file_map() - return reason/error string
Timo Sirainen [Wed, 17 May 2017 10:33:44 +0000 (13:33 +0300)] 
lib-index: mail_transaction_log_file_map() - return reason/error string

This can help figuring out why some error happened when more context is
provided in the caller's error messages.

8 years agolib-index: mail_transaction_log_view_set_all() - don't entirely ignore corrupted...
Timo Sirainen [Wed, 17 May 2017 10:31:09 +0000 (13:31 +0300)] 
lib-index: mail_transaction_log_view_set_all() - don't entirely ignore corrupted logs

Ignore them only if it's followed by an index reset.

8 years agolib-storage: Don't crash if cache is thought broken for a newly saved mail
Timo Sirainen [Fri, 19 May 2017 08:05:22 +0000 (11:05 +0300)] 
lib-storage: Don't crash if cache is thought broken for a newly saved mail

It's a bug that it happens, but the resulting crash is confusing.
Although arguably this new error could be i_panic() instead.

Fixes:
Panic: file mail-index-transaction-update.c: line 1018 (mail_index_update_ext): assertion failed: (seq > 0 && (seq <= mail_index_view_get_messages_count(t->view) || seq <= t->last_new_seq))

8 years agoimap NOTIFY: Flush any pending notifications on NOOP
Timo Sirainen [Wed, 17 May 2017 16:02:06 +0000 (19:02 +0300)] 
imap NOTIFY: Flush any pending notifications on NOOP

This is mainly to allow testing NOTIFY easily with imaptest scripts.
This is cheap anyway, because mailbox_list_notify_flush() doesn't do any
syscalls when there's no work.

8 years agolib-storage: Implement mailbox_list_notify_flush()
Timo Sirainen [Wed, 17 May 2017 16:01:57 +0000 (19:01 +0300)] 
lib-storage: Implement mailbox_list_notify_flush()

This flushes any pending notifications. For now it only checks if there's
a pending notification waiting for a timeout. It could also stat() the
files to make sure, but that's probably unnecessary.

8 years agolib-storage: Explicitly name function pointers in mailbox lists
Timo Sirainen [Wed, 17 May 2017 15:13:09 +0000 (18:13 +0300)] 
lib-storage: Explicitly name function pointers in mailbox lists

This allows adding more fields to struct mailbox_list_vfuncs without
compiler warnings.

8 years agolib-storage: Always update highestmodseq in mailbox list index
Timo Sirainen [Wed, 17 May 2017 14:49:25 +0000 (17:49 +0300)] 
lib-storage: Always update highestmodseq in mailbox list index

This is required for mailbox-list-notify API to work correctly. For
example IMAP NOTIFY session with CONDSTORE enabled could be listening for
FlagChanges, but another session without CONDSTORE enabled could be updating
flags in a mailbox that has never been opened with CONDSTORE enabled.
NOTIFY wouldn't see this change, unless it was always written to
dovecot.list.index.

8 years agolib-storage: Fix mailbox list index notifications when modseqs aren't enabled.
Timo Sirainen [Wed, 17 May 2017 14:14:05 +0000 (17:14 +0300)] 
lib-storage: Fix mailbox list index notifications when modseqs aren't enabled.

No notifications were sent if highest_modseqs weren't updated in mailbox
list index.

8 years agoimap: login reply should be sent sooner
Josef 'Jeff' Sipek [Wed, 17 May 2017 08:40:53 +0000 (11:40 +0300)] 
imap: login reply should be sent sooner

8 years agolib-storage: Fix mailbox list index records without guid having invalid flags
Timo Sirainen [Thu, 18 May 2017 20:13:38 +0000 (23:13 +0300)] 
lib-storage: Fix mailbox list index records without guid having invalid flags

With LAYOUT=index the mailbox is found with its GUID. If it doesn't exist,
the mailbox has to be either \NonExistent or \NoSelect. It probably doesn't
make much difference which one, so we'll fix them by adding \NoSelect.

With other layouts the GUID is allowed to be empty, because it can be looked
up from the actual mailbox.

8 years agolib-storage: Fix mailbox list index records with name_id=0
Timo Sirainen [Thu, 18 May 2017 20:06:20 +0000 (23:06 +0300)] 
lib-storage: Fix mailbox list index records with name_id=0

name_id=0 isn't valid, so it needs to be changed and writen to the disk.
The write-to-disk part wasn't working.

8 years agolib: istream-concat - enforce cur_input==input[cur_idx] invariant
Phil Carmody [Wed, 30 Mar 2016 06:33:02 +0000 (09:33 +0300)] 
lib: istream-concat - enforce cur_input==input[cur_idx] invariant

Since the over-seek patch, this is now an invariant, so ensure it's
always true.

Signed-off-by: Phil Carmody <phil@dovecot.fi>
8 years agolib: istream-concat - make cur_input always match input[cur_idx]
Phil Carmody [Wed, 30 Mar 2016 06:29:51 +0000 (09:29 +0300)] 
lib: istream-concat - make cur_input always match input[cur_idx]

We're deliberately not stepping into the NULL stream, don't let the
cur_idx indicate that we have moved into it, that's confusing.

Signed-off-by: Phil Carmody <phil@dovecot.fi>
8 years agoimapc: Make sure a valid UIDVALIDITY is returned by SELECT
Timo Sirainen [Thu, 18 May 2017 18:10:33 +0000 (21:10 +0300)] 
imapc: Make sure a valid UIDVALIDITY is returned by SELECT

Fixes errors such as:
Error: Synchronization corrupted index header (in-memory index): uidvalidity=0, but next_uid=9

8 years agoimapc: Fix assert-crash if server doesn't send EXISTS reply to SELECT
Timo Sirainen [Thu, 18 May 2017 18:08:23 +0000 (21:08 +0300)] 
imapc: Fix assert-crash if server doesn't send EXISTS reply to SELECT

Fixes:
Panic: file imapc-sync.c: line 477 (imapc_sync_index): assertion failed: (mbox->sync_fetch_first_uid == 1)

8 years agolib-imap-client: Change server IP only on connect() failures
Timo Sirainen [Thu, 18 May 2017 17:18:24 +0000 (20:18 +0300)] 
lib-imap-client: Change server IP only on connect() failures

Also log an warning-level message about it. This is mainly useful to see
that a slow connection could be caused by a connect() timeout. Since more
IPs are still available, it's not yet an error.

8 years agoimapc: Fix infinite reconnection when server keeps sending corrupted state
Timo Sirainen [Thu, 18 May 2017 16:42:03 +0000 (19:42 +0300)] 
imapc: Fix infinite reconnection when server keeps sending corrupted state

When corrupted state was found, imapc_client_mailbox_reconnect() is called
to reconnect. This call skipped the normal "is it safe to reconnect?"
checks causing potentially infinite reconnections.

8 years agolib-imap: imap_parser_unref() should always set parser=NULL
Timo Sirainen [Thu, 18 May 2017 16:40:04 +0000 (19:40 +0300)] 
lib-imap: imap_parser_unref() should always set parser=NULL

Not just when the last reference is cleared. This is how *_unref()s should
work everywhere in Dovecot. This fixes a bug in lib-imap-client where a
parser could have been accessed after it was already freed.

8 years agoimapc: Avoid resending duplicate FETCH when reconnecting during the initial sync
Timo Sirainen [Thu, 18 May 2017 15:09:56 +0000 (18:09 +0300)] 
imapc: Avoid resending duplicate FETCH when reconnecting during the initial sync

8 years agoimapc: If initial SELECT fails, don't resend it twice on reconnect.
Timo Sirainen [Thu, 18 May 2017 15:01:27 +0000 (18:01 +0300)] 
imapc: If initial SELECT fails, don't resend it twice on reconnect.

8 years agolib-imap-client: Avoid infinite reconnection loops when retrying command fails
Timo Sirainen [Thu, 18 May 2017 14:36:27 +0000 (17:36 +0300)] 
lib-imap-client: Avoid infinite reconnection loops when retrying command fails

reconnect_command_count wasn't calculated correctly, because the SELECT and
potentially other following sync commands weren't included in it.

8 years agolib: Fix memory leak in test-istream-concat
Timo Sirainen [Fri, 19 May 2017 06:45:28 +0000 (09:45 +0300)] 
lib: Fix memory leak in test-istream-concat

8 years agolib: Add dovecot_build_info variable containing Dovecot build information.
Timo Sirainen [Thu, 18 May 2017 09:32:12 +0000 (12:32 +0300)] 
lib: Add dovecot_build_info variable containing Dovecot build information.

By default this includes the version, including the git hash. The idea is
that this version information would be available in all the core dumps.

The DOVECOT_BUILD_INFO can be overridden by compiling with:

DOVECOT_BUILD_INFO='"build info"' make

8 years agolib: Fix crash when seeking istream-concat to EOF and trying to read it
Timo Sirainen [Thu, 18 May 2017 19:18:15 +0000 (22:18 +0300)] 
lib: Fix crash when seeking istream-concat to EOF and trying to read it

8 years agolib-http: Changed test-http-server to actually use the http-server API.
Stephan Bosch [Fri, 12 May 2017 02:25:08 +0000 (04:25 +0200)] 
lib-http: Changed test-http-server to actually use the http-server API.

This currently serves as a simple demonstration of how to structure an HTTP server.

8 years agolib-http: server: Fixed detection of idle connection.
Stephan Bosch [Fri, 12 May 2017 02:23:10 +0000 (04:23 +0200)] 
lib-http: server: Fixed detection of idle connection.

This fixes the debug message; the behavior was otherwise correct.

8 years agovirtual: Match any metadata condition
Aki Tuomi [Thu, 18 May 2017 11:59:51 +0000 (14:59 +0300)] 
virtual: Match any metadata condition

The old code ignored succesful earlier matches for
patterns, and stopped looking on first non-matching
metadata pattern. Now it breaks on error or on first
matching pattern.

8 years agolib-storage: Apply mailbox_list_iter_autocreate_filter on mailbox_list_index_iter_next
Aki Tuomi [Wed, 17 May 2017 12:20:35 +0000 (15:20 +0300)] 
lib-storage: Apply mailbox_list_iter_autocreate_filter on mailbox_list_index_iter_next

It skips mailbox_list_iter_next, so it needs to be applied here as well.

8 years agolib-storage: Rename autocreate_iter_existing to mailbox_list_iter_autocreate_filter
Aki Tuomi [Wed, 17 May 2017 12:19:44 +0000 (15:19 +0300)] 
lib-storage: Rename autocreate_iter_existing to mailbox_list_iter_autocreate_filter

It makes next commit possible

8 years agolib-storage: Do not drop autocreate boxes when listing them
Aki Tuomi [Wed, 17 May 2017 09:16:31 +0000 (12:16 +0300)] 
lib-storage: Do not drop autocreate boxes when listing them

Otherwise we skip folders, because array_delete() is removing boxes while they're being iterated.

8 years agodovecot --build-options: Add missing linefeed
Timo Sirainen [Thu, 18 May 2017 10:03:45 +0000 (13:03 +0300)] 
dovecot --build-options: Add missing linefeed

8 years agodirector: Add old host's up/down and vhost count parameters to director_flush_socket
Timo Sirainen [Thu, 18 May 2017 08:57:38 +0000 (11:57 +0300)] 
director: Add old host's up/down and vhost count parameters to director_flush_socket

The "down" status allows the script to determine whether it should try to
perform any work on the old host. The vhost count may be unnecessary, but
might be useful for some purpose.

8 years agofts: Do not attempt to deinitialize backend if it's not set
Aki Tuomi [Wed, 17 May 2017 09:26:42 +0000 (12:26 +0300)] 
fts: Do not attempt to deinitialize backend if it's not set

If FTS backend initialization fails or does not happen,
flist->backend might end up being NULL, and attempt to
deinitialize NULL won't end well.

8 years agolib: include inttypes.h to get PRIu64 & friends
Josef 'Jeff' Sipek [Wed, 17 May 2017 07:35:03 +0000 (10:35 +0300)] 
lib: include inttypes.h to get PRIu64 & friends

Including it in lib.h allows all of the Dovecot code (as well as any
external plugins) to just use these macros without worrying about what
system headers to include.

8 years agodsync: Try to commit transactions every dsync_commit_msgs_interval messages
Timo Sirainen [Sun, 30 Apr 2017 09:31:48 +0000 (12:31 +0300)] 
dsync: Try to commit transactions every dsync_commit_msgs_interval messages

This was first attempted to be implemented by
ec0cc8fa647794e44a1afaa448f495a713048dc4, but it was later partially
reverted by 5973d496b16721af6d2c1fa90b016aacddf13554. This current
commit should fix its problems.

8 years agoauth: If passdb/userdb ldap has blocking=yes, auth master shouldn't connect to ldap
Timo Sirainen [Tue, 16 May 2017 14:53:23 +0000 (17:53 +0300)] 
auth: If passdb/userdb ldap has blocking=yes, auth master shouldn't connect to ldap

8 years agoutil: script: Increased the major protocol version due to earlier changes.
Stephan Bosch [Mon, 8 May 2017 10:49:39 +0000 (12:49 +0200)] 
util: script: Increased the major protocol version due to earlier changes.

8 years agoutil: script: Amended protocol with the ability to convey a set of environment variab...
Stephan Bosch [Tue, 9 May 2017 11:33:23 +0000 (13:33 +0200)] 
util: script: Amended protocol with the ability to convey a set of environment variables that are passed to the script.

The acceptable environment variables are selected using the -e parameter; others are ignored silently.

8 years agoutil: script: Amended the protocol to pass arguments escaped to prevent problems...
Stephan Bosch [Mon, 8 May 2017 10:48:08 +0000 (12:48 +0200)] 
util: script: Amended the protocol to pass arguments escaped to prevent problems with newlines.

Newlines are used as argument delimiters in the protocol, which will cause problems.

8 years agolib-program-client: local: Fixed use of unterminated string array of environment...
Stephan Bosch [Tue, 9 May 2017 11:43:39 +0000 (13:43 +0200)] 
lib-program-client: local: Fixed use of unterminated string array of environment variables in exec_child().

8 years agolib-program-client: Made the test suite ignore the protocol version.
Stephan Bosch [Tue, 9 May 2017 12:22:06 +0000 (14:22 +0200)] 
lib-program-client: Made the test suite ignore the protocol version.

8 years agomail-crypt-plugin: Set copy-hook only if save_version > 0
Aki Tuomi [Mon, 15 May 2017 12:35:37 +0000 (15:35 +0300)] 
mail-crypt-plugin: Set copy-hook only if save_version > 0

Otherwise we might use it in read-only mode, too.

8 years agodoveadm mailbox status: Add "firstsaved" field.
Timo Sirainen [Wed, 10 May 2017 09:44:25 +0000 (12:44 +0300)] 
doveadm mailbox status: Add "firstsaved" field.

8 years agoimapc: Try to merge STOREs together as much as possible when syncing
Timo Sirainen [Thu, 4 May 2017 16:59:41 +0000 (19:59 +0300)] 
imapc: Try to merge STOREs together as much as possible when syncing

8 years agolib-storage: Avoid unnecessary UIDNEXT lookups after saving a mail
Timo Sirainen [Fri, 5 May 2017 12:20:05 +0000 (15:20 +0300)] 
lib-storage: Avoid unnecessary UIDNEXT lookups after saving a mail

The vsize checking code was expecting that this would always be a cheap
operation, but with imapc code it could trigger a remote STATUS (UIDNEXT)
call. Do this only when we've checked that this mailbox is updating vsize
header at all.

8 years agoimapc-quota: Avoid sending unnecessarily many GETQUOTA[ROOT] commands
Timo Sirainen [Fri, 12 May 2017 12:42:31 +0000 (15:42 +0300)] 
imapc-quota: Avoid sending unnecessarily many GETQUOTA[ROOT] commands

The last_refresh == ioloop_timeval check didn't work, because the refresh
itself updated ioloop_timeval. This caused a single quota lookup to issue
multiple GETQUOTA[ROOT] commands to imapc.

8 years agolib-storage: add a mail user pre-deinit vfunc
Josef 'Jeff' Sipek [Fri, 12 May 2017 09:44:27 +0000 (12:44 +0300)] 
lib-storage: add a mail user pre-deinit vfunc

This allows plugins to perform checks right before the deinit call.

8 years agolib-storage: Add missing ATTR_FORMAT to mail_set_mail_cache_corrupted()
Timo Sirainen [Fri, 12 May 2017 08:13:09 +0000 (11:13 +0300)] 
lib-storage: Add missing ATTR_FORMAT to mail_set_mail_cache_corrupted()

8 years agoAdded doc/man/doveadm-save.1 to .gitignore.
Stephan Bosch [Fri, 12 May 2017 00:37:22 +0000 (02:37 +0200)] 
Added doc/man/doveadm-save.1 to .gitignore.

8 years agodoc: Add manpage for doveadm-save
Aki Tuomi [Thu, 11 May 2017 06:24:57 +0000 (09:24 +0300)] 
doc: Add manpage for doveadm-save

8 years agolib-storage: Use new mail_cache_set_seq_corrupted_reason
Aki Tuomi [Tue, 9 May 2017 11:01:07 +0000 (14:01 +0300)] 
lib-storage: Use new mail_cache_set_seq_corrupted_reason

8 years agolib-index: Add mail_cache_set_seq_corrupted_reason
Aki Tuomi [Tue, 9 May 2017 11:00:38 +0000 (14:00 +0300)] 
lib-index: Add mail_cache_set_seq_corrupted_reason

Marks a seq in cache corrupted, and removes
that instead of the whole cache.

8 years agolib-index: Add mail_cache_expunge_count
Aki Tuomi [Tue, 9 May 2017 11:29:04 +0000 (14:29 +0300)] 
lib-index: Add mail_cache_expunge_count

It can be called to correctly handle cache counters
when records are removed.

8 years agossl-proxy-openssl: Fix comparison to stricly boolean
Aki Tuomi [Wed, 10 May 2017 09:40:27 +0000 (12:40 +0300)] 
ssl-proxy-openssl: Fix comparison to stricly boolean

8 years ago{lib,lib-fts}: fix builds with BSD make
Josef 'Jeff' Sipek [Tue, 9 May 2017 09:51:49 +0000 (12:51 +0300)] 
{lib,lib-fts}: fix builds with BSD make

Without this change, BSD make doesn't know how to make a couple of the
generated files because the BUILT_SOURCES file names don't match exactly
the left hand sides of the rules.  (GNU make somehow manages to match the
rule even though it is not an exact match.)

8 years agolib: use full path to unicode data script
Josef 'Jeff' Sipek [Tue, 9 May 2017 09:43:46 +0000 (12:43 +0300)] 
lib: use full path to unicode data script

This is a step toward fixing builds where object dir != source dir.

8 years agolib-fts: use full path to word-properties script
Josef 'Jeff' Sipek [Tue, 9 May 2017 09:42:48 +0000 (12:42 +0300)] 
lib-fts: use full path to word-properties script

This is a step toward fixing builds where object dir != source dir.

8 years agolib-fts: download data files into srcdir
Josef 'Jeff' Sipek [Tue, 9 May 2017 09:36:40 +0000 (12:36 +0300)] 
lib-fts: download data files into srcdir

This is a step toward fixing builds where object dir != source dir.