]> git.ipfire.org Git - thirdparty/dovecot/core.git/log
thirdparty/dovecot/core.git
9 years agoimapc: If root separator lookup fails, fail all further lookups.
Timo Sirainen [Wed, 6 Apr 2016 11:44:00 +0000 (14:44 +0300)] 
imapc: If root separator lookup fails, fail all further lookups.

We already returned a potentially wrong separator (since there's no way to
return error), so we don't want to continue and possibly make things worse.

9 years agoimapc: Added missing error handling to subscriptions list refreshing.
Timo Sirainen [Wed, 6 Apr 2016 11:43:02 +0000 (14:43 +0300)] 
imapc: Added missing error handling to subscriptions list refreshing.

9 years agoimapc: Fixed mailbox_exists() error handling.
Timo Sirainen [Wed, 6 Apr 2016 11:41:16 +0000 (14:41 +0300)] 
imapc: Fixed mailbox_exists() error handling.

9 years agoimapc: Support retrying after connect() failure.
Timo Sirainen [Wed, 6 Apr 2016 11:24:21 +0000 (14:24 +0300)] 
imapc: Support retrying after connect() failure.

9 years agoimapc: Support retrying after connect/authentication timeouts.
Timo Sirainen [Wed, 6 Apr 2016 11:17:02 +0000 (14:17 +0300)] 
imapc: Support retrying after connect/authentication timeouts.

9 years agoimapc: Support retrying for non-mailbox commands.
Timo Sirainen [Wed, 6 Apr 2016 11:16:13 +0000 (14:16 +0300)] 
imapc: Support retrying for non-mailbox commands.

9 years agoimapc: Prepare for non-mailbox command retrying: Set reconnect_command_count earlier
Timo Sirainen [Wed, 6 Apr 2016 11:12:25 +0000 (14:12 +0300)] 
imapc: Prepare for non-mailbox command retrying: Set reconnect_command_count earlier

This probably doesn't fix itself anything yet, but is needed for the
following changes.

9 years agoimapc: Fixed checking of whether same IMAP command keeps crashing server.
Timo Sirainen [Wed, 6 Apr 2016 11:09:13 +0000 (14:09 +0300)] 
imapc: Fixed checking of whether same IMAP command keeps crashing server.

reconnect_command_count was counting only the post-login commands, but we
were decreasing it also for pre-login commands. This caused it to shrink to
0 too early.

9 years agoimapc: Code cleanup - imapc_connection_reconnect() is now always called when reconnec...
Timo Sirainen [Wed, 6 Apr 2016 11:05:26 +0000 (14:05 +0300)] 
imapc: Code cleanup - imapc_connection_reconnect() is now always called when reconnect is ok.

9 years agoimapc: Code cleanup - Use a common function for checking/logging if we want to reconn...
Timo Sirainen [Wed, 6 Apr 2016 11:03:20 +0000 (14:03 +0300)] 
imapc: Code cleanup - Use a common function for checking/logging if we want to reconnect or disconnect

9 years agolib-storage: Fixed error handling for mailbox_list_iter_init_namespaces()
Timo Sirainen [Wed, 6 Apr 2016 10:52:24 +0000 (13:52 +0300)] 
lib-storage: Fixed error handling for mailbox_list_iter_init_namespaces()

If iteration for the first namespace failed, we tried to copy the error
string to error_list, which was the same first namespace's list. This caused
the error string to be freed while it was being copied, so the end result
was that the error became either an empty or garbage string.

9 years agodsync: Don't export header hashes if remote mailbox is empty.
Timo Sirainen [Wed, 6 Apr 2016 09:41:38 +0000 (12:41 +0300)] 
dsync: Don't export header hashes if remote mailbox is empty.

This avoids doing a lot of work of reading through all mails' headers and
hashing them, when the hashes aren't actually going to be used for anything.

9 years agolib-http: server: Fixed bug in request reference counting caused by earlier fix ...
Stephan Bosch [Tue, 12 Apr 2016 09:42:38 +0000 (11:42 +0200)] 
lib-http: server: Fixed bug in request reference counting caused by earlier fix (390b600a6f7fdb4ccc65950527ee30129f49a6ac).

The earlier change erroneously dropped two lines that unreferenced the request object after calling the callback.

9 years agolib-master: Fixed assert-crash when HAProxy aborts connections.
Timo Sirainen [Tue, 12 Apr 2016 07:49:50 +0000 (10:49 +0300)] 
lib-master: Fixed assert-crash when HAProxy aborts connections.

close() was called before io_remove(), which resulted in:

Panic: epoll_ctl(del, 14) failed: Bad file descriptor

9 years agodict-ldap: Compiler warning fix
Timo Sirainen [Mon, 11 Apr 2016 09:24:59 +0000 (12:24 +0300)] 
dict-ldap: Compiler warning fix

9 years agolib-dict: Add ldap driver
Aki Tuomi [Mon, 11 Apr 2016 06:40:22 +0000 (09:40 +0300)] 
lib-dict: Add ldap driver

9 years agoconfigure: Add lib-ldap
Aki Tuomi [Mon, 11 Apr 2016 06:38:27 +0000 (09:38 +0300)] 
configure: Add lib-ldap

9 years agolib-ldap: Add lib-ldap implementation
Aki Tuomi [Mon, 11 Apr 2016 06:37:39 +0000 (09:37 +0300)] 
lib-ldap: Add lib-ldap implementation

9 years agolib-master: Fixed memory leaks when failing to read settings.
Timo Sirainen [Sun, 10 Apr 2016 11:57:48 +0000 (14:57 +0300)] 
lib-master: Fixed memory leaks when failing to read settings.

9 years agovirtual plugin: struct mail_vfuncs.close() wasn't implemented.
Timo Sirainen [Thu, 7 Apr 2016 14:50:28 +0000 (17:50 +0300)] 
virtual plugin: struct mail_vfuncs.close() wasn't implemented.

This wasn't a problem normally, because the core code wouldn't try to call
this. It became a problem only after other plugins were trying to call it.

9 years agolib-master: Preserve LOG_STDERR_TIMESTAMP environment through doveconf exec.
Timo Sirainen [Thu, 7 Apr 2016 13:35:28 +0000 (16:35 +0300)] 
lib-master: Preserve LOG_STDERR_TIMESTAMP environment through doveconf exec.

This should be needed only for standalone programs, so don't bother trying
to preserve it otherwise.

9 years agolmtp: Use separate session ID suffixes for each RCPT TO delivery.
Timo Sirainen [Tue, 5 Apr 2016 17:14:15 +0000 (20:14 +0300)] 
lmtp: Use separate session ID suffixes for each RCPT TO delivery.

Otherwise each delivery will use the same session ID when talking to stats
process, which results in errors like:

Error: stats: FIFO input error: CONNECT: Duplicate session ID ME3ZHCi+A1dUDQAAvAUe3g for user foobar service lmtp
Warning: stats: Couldn't find session ID: ME3ZHCi+A1dUDQAAvAUe3g

(There was a DISCONNECT for the session ID between these two log lines.)

9 years agolib-storage: Changed separator between session_id_prefix and unique part to be ':'
Timo Sirainen [Tue, 5 Apr 2016 17:10:53 +0000 (20:10 +0300)] 
lib-storage: Changed separator between session_id_prefix and unique part to be ':'

Although '-' wasn't used by default either, it's much more likely that
custom session IDs might contain it. ':' is hopefully less likely to be used.
This allows log parsers that actually want to find out the original session's
all log lines to cut out everything after the initial ':'.

9 years agolmtp: Changed default LMTP proxy timeout to 125 seconds.
Timo Sirainen [Wed, 6 Apr 2016 19:43:52 +0000 (22:43 +0300)] 
lmtp: Changed default LMTP proxy timeout to 125 seconds.

The main problem with LMTP proxy timing out too early is that it causes
duplicates if the backend actually finishes the mail delivery.

The 30 seconds is bad, because there are various timeouts in backend set
to 30 seconds also. 125 seconds is hopefully large enough to hit most of
the 2 minute timeouts and we'll have a few extra seconds left to see the
failure.

9 years agodoveadm sync: -R parameter shouldn't switch to "doveadm backup -R" behavior.
Timo Sirainen [Wed, 6 Apr 2016 19:12:54 +0000 (22:12 +0300)] 
doveadm sync: -R parameter shouldn't switch to "doveadm backup -R" behavior.

Just ignore the -R parameter for doveadm sync, unless -1 parameter is also
used. Alternatively we could also fail the command, but maybe that's
unnecessary extra work.

9 years agodoveadm: Reverted 7a3b52b8f - doveadm sync -1 -R is useful.
Timo Sirainen [Wed, 6 Apr 2016 19:08:14 +0000 (22:08 +0300)] 
doveadm: Reverted 7a3b52b8f - doveadm sync -1 -R is useful.

9 years agodict-redis: When timeout was reached, we didn't actually stop but just continued...
Timo Sirainen [Wed, 6 Apr 2016 17:19:04 +0000 (20:19 +0300)] 
dict-redis: When timeout was reached, we didn't actually stop but just continued waiting.

9 years agodoveadm-http: Fix mismatch in authorization
Aki Tuomi [Mon, 4 Apr 2016 18:05:44 +0000 (21:05 +0300)] 
doveadm-http: Fix mismatch in authorization

The code advertizes X-Dovecot-API in WWW-Authenticate header, but
expects X-Doveadm-API in Authorization header. This change makes
it expect X-Dovecot-API.

9 years agoimapc: If we get disconnected during SELECT/EXAMINE, retry it once.
Timo Sirainen [Tue, 5 Apr 2016 16:59:18 +0000 (19:59 +0300)] 
imapc: If we get disconnected during SELECT/EXAMINE, retry it once.

This seems to be happening especially with dsync migrations from IMAP
servers with small timeouts. The initial dsync run opens imapc connection
early to do a LIST + SELECT the first mailbox, but then dsync may spend a
while creating all the local mailboxes before it continues using the imapc
connection.

9 years agofts-tika: Don't crash on 500 errors (caused by 146f6f85d)
Timo Sirainen [Tue, 5 Apr 2016 13:26:08 +0000 (16:26 +0300)] 
fts-tika: Don't crash on 500 errors (caused by 146f6f85d)

http_req=NULL here set by http_client_request_send_payload(). Even if it
wasn't, the payload wouldn't be there.

9 years agodoveadm-proxy: Change to work with doveadm ver2
Aki Tuomi [Tue, 5 Apr 2016 09:05:15 +0000 (12:05 +0300)] 
doveadm-proxy: Change to work with doveadm ver2

9 years agolib-storage: FS layout assert-crashed when trying to list with invalid UTF8 pattern
Timo Sirainen [Mon, 4 Apr 2016 09:22:06 +0000 (12:22 +0300)] 
lib-storage: FS layout assert-crashed when trying to list with invalid UTF8 pattern

9 years agolib: Updated fdpass.h comments.
Timo Sirainen [Mon, 4 Apr 2016 08:11:13 +0000 (11:11 +0300)] 
lib: Updated fdpass.h comments.

9 years agoistream-unix: Fixed handling of EOF from fd_read() (ret==0).
Stephan Bosch [Sun, 3 Apr 2016 20:54:17 +0000 (22:54 +0200)] 
istream-unix: Fixed handling of EOF from fd_read() (ret==0).

This situation was ignored.

9 years agoquota: Fix NetBSD build.
Teemu Huovila [Thu, 31 Mar 2016 13:35:06 +0000 (16:35 +0300)] 
quota: Fix NetBSD build.

9 years agodoveadm-mail: Honor -u flag on v1 commands
Aki Tuomi [Thu, 31 Mar 2016 09:41:25 +0000 (12:41 +0300)] 
doveadm-mail: Honor -u flag on v1 commands

9 years agodoveadm-server: Register builtin dict drivers always at init
Timo Sirainen [Wed, 30 Mar 2016 13:24:56 +0000 (16:24 +0300)] 
doveadm-server: Register builtin dict drivers always at init

This was already done for doveadm. Fixes using doveadm dict commands via
doveadm-server.

9 years agodoveadm-mail: Initialize missing cmd context username
Aki Tuomi [Wed, 30 Mar 2016 10:14:40 +0000 (13:14 +0300)] 
doveadm-mail: Initialize missing cmd context username

Fixes assert-crash in doveadm_mail_single_user()

9 years agolib-storage: Fixed memory leak when iterating attributes.
Timo Sirainen [Wed, 30 Mar 2016 07:51:50 +0000 (10:51 +0300)] 
lib-storage: Fixed memory leak when iterating attributes.

9 years agodoveadm-mail: Don't lose rip/lip/lport/rport in passdb lookups for doveadm TCP connec...
Aki Tuomi [Wed, 30 Mar 2016 07:34:06 +0000 (10:34 +0300)] 
doveadm-mail: Don't lose rip/lip/lport/rport in passdb lookups for doveadm TCP connections

9 years agodirector: Avoid a potential assert-crash after removing a director from ring.
Timo Sirainen [Wed, 30 Mar 2016 05:24:51 +0000 (08:24 +0300)] 
director: Avoid a potential assert-crash after removing a director from ring.

This should fix the crash:
Panic: director: file director-connection.c: line 1926 (director_connection_init_out): assertion failed: (!host->removed)

Also moved the last_network_failure timestamp reset a bit later, since
there's no need to reset the timestamp if we're not actually connecting
to the server.

9 years agodoveadm: Fixed reading USER environment for v1 commands.
Timo Sirainen [Tue, 29 Mar 2016 18:17:22 +0000 (21:17 +0300)] 
doveadm: Fixed reading USER environment for v1 commands.

9 years agoimapc: Don't try to FETCH uncommitted mails, because it would attempt to FETCH uid=0
Timo Sirainen [Tue, 29 Mar 2016 17:38:19 +0000 (20:38 +0300)] 
imapc: Don't try to FETCH uncommitted mails, because it would attempt to FETCH uid=0

9 years agoauth: Disable auth caching for passwd-file
Timo Sirainen [Tue, 29 Mar 2016 12:17:29 +0000 (15:17 +0300)] 
auth: Disable auth caching for passwd-file

Its caching is usually unnecessary, because the passwd-files are efficiently
in memory already. It's also problematic, because extra_fields can contain
%variables, which can be lookup-dependent. So for example if %{lport} is used
in extra_fields, it would need to be included in the cache key. But because
different variables can be used by different users' extra_fields, there's
really no good way to include all of it in the cache key.

9 years agodoveadm-batch: Fixed error message for an unknown subcommand.
Timo Sirainen [Tue, 29 Mar 2016 12:04:01 +0000 (15:04 +0300)] 
doveadm-batch: Fixed error message for an unknown subcommand.

9 years agodoveadm: Fixed adding username header to commands iterating through multiple users.
Timo Sirainen [Tue, 29 Mar 2016 11:57:20 +0000 (14:57 +0300)] 
doveadm: Fixed adding username header to commands iterating through multiple users.

9 years agodoveadm-server: v2 mail commands weren't doing a userdb lookup.
Timo Sirainen [Tue, 29 Mar 2016 11:17:01 +0000 (14:17 +0300)] 
doveadm-server: v2 mail commands weren't doing a userdb lookup.

9 years agodoveadm-server: Fixed running multi-word commands.
Timo Sirainen [Tue, 29 Mar 2016 11:10:10 +0000 (14:10 +0300)] 
doveadm-server: Fixed running multi-word commands.

The problem with for example "mailbox status" command is that:
 - doveadm cli: argv[0] = "mailbox", argv[1] = "status"
 - doveadm-server: argv[0] = "mailbox status"

So with doveadm cli we'll now instead just skip over words until argv[0]
is the last word of the command ("status").

9 years agodoveadm: Code cleanup - always use const char *const[] type for argv.
Timo Sirainen [Tue, 29 Mar 2016 11:06:43 +0000 (14:06 +0300)] 
doveadm: Code cleanup - always use const char *const[] type for argv.

Needed to fix compiler warnings in the following patch.

9 years agologin-proxy: When logging failures, include the client info prefix.
Timo Sirainen [Tue, 29 Mar 2016 09:15:05 +0000 (12:15 +0300)] 
login-proxy: When logging failures, include the client info prefix.

9 years agologin-*: When logging about client certificate validity, include the client info...
Timo Sirainen [Tue, 29 Mar 2016 08:28:55 +0000 (11:28 +0300)] 
login-*: When logging about client certificate validity, include the client info prefix.

9 years agoauth: If user is unknown and there are more passdbs/userdb, log about it.
Timo Sirainen [Thu, 24 Mar 2016 18:01:00 +0000 (03:01 +0900)] 
auth: If user is unknown and there are more passdbs/userdb, log about it.

9 years agolib-http: client: Fixed request timeout handling during pipelining.
Stephan Bosch [Thu, 24 Mar 2016 17:48:55 +0000 (02:48 +0900)] 
lib-http: client: Fixed request timeout handling during pipelining.

The timeout was not managed correctly. If an earlier request finished, it
would not restart the timeout for the next pending request.

Also, filling the pipeline caused the timout to be reset inappropriately,
postponing its expiry.

9 years agolib-http: client: Fixed handling of stalled connections that emerge when the client...
Stephan Bosch [Thu, 24 Mar 2016 17:47:28 +0000 (02:47 +0900)] 
lib-http: client: Fixed handling of stalled connections that emerge when the client ioloop hasn't run for a long time.

Inside the peer's request handler routine, the connections are verified
after the ioloop continues. If they turn out to be broken, they
self-destruct while the handler routine is active, leading to problems.

Solved by referencing the connection and retrying the connection statistics
loop when a connection is lost in the process.

9 years agoSet postmaster_address=%d by default because imap now loads lda settings and it must...
Timo Sirainen [Thu, 24 Mar 2016 15:45:54 +0000 (00:45 +0900)] 
Set postmaster_address=%d by default because imap now loads lda settings and it must be non-empty.

We don't want imap to suddenly start failing because of the c15e8f33c
change. This isn't a perfect solution either, but should be ok enough.

9 years agodirector: Make sure freeing a user doesn't leak a timeout.
Timo Sirainen [Thu, 24 Mar 2016 01:07:15 +0000 (10:07 +0900)] 
director: Make sure freeing a user doesn't leak a timeout.

9 years agodirector: Fixed memory leak when killing a user.
Timo Sirainen [Thu, 24 Mar 2016 01:01:17 +0000 (10:01 +0900)] 
director: Fixed memory leak when killing a user.

9 years agodirector: Make sure a long-delayed kill reply for user doesn't mess up the state.
Timo Sirainen [Thu, 24 Mar 2016 01:00:00 +0000 (10:00 +0900)] 
director: Make sure a long-delayed kill reply for user doesn't mess up the state.

This should fix assert-crash:

director: Panic: file director.c: line 690 (director_user_kill_finish_delayed_to): assertion failed: (ctx->user->kill_state == USER_KILL_STATE_DELAY)

9 years agodirector: Small improvements to director-test.sh
Timo Sirainen [Thu, 24 Mar 2016 00:43:43 +0000 (09:43 +0900)] 
director: Small improvements to director-test.sh

Test with a bigger director ring. Include microseconds in log timestamps to
make debugging easier. Changed the name of the info_log_path.

9 years agodirector: Don't re-send SYNC unnecessarily often.
Timo Sirainen [Thu, 24 Mar 2016 00:42:50 +0000 (09:42 +0900)] 
director: Don't re-send SYNC unnecessarily often.

9 years agodirector: Fixed user weakness getting stuck if multiple directors set user weak simul...
Timo Sirainen [Thu, 24 Mar 2016 00:36:14 +0000 (09:36 +0900)] 
director: Fixed user weakness getting stuck if multiple directors set user weak simultaneously

9 years agopop3-login: XCLIENT / XOIP no longer return -ERR for untrusted IP ranges.
Timo Sirainen [Wed, 23 Mar 2016 14:33:49 +0000 (23:33 +0900)] 
pop3-login: XCLIENT / XOIP no longer return -ERR for untrusted IP ranges.

The command is simply ignored, similarly to imap-login ID.

9 years agodoveadm: Move getenv to correct place
Aki Tuomi [Wed, 23 Mar 2016 07:01:31 +0000 (09:01 +0200)] 
doveadm: Move getenv to correct place

All getenv()s must be done after master_service_init() or the pointer will be
corrupted with Linux and other OSes without setproctitle().

9 years agoimap: Made LDA settings accessible from plugins.
Stephan Bosch [Tue, 22 Mar 2016 00:16:26 +0000 (01:16 +0100)] 
imap: Made LDA settings accessible from plugins.

This way, plugins can also send mail.

9 years agodoveadm-server: Fixed initializing username for mail commands.
Aki Tuomi [Tue, 22 Mar 2016 07:19:45 +0000 (09:19 +0200)] 
doveadm-server: Fixed initializing username for mail commands.

9 years agodoveadm: Getting user from USER environment wasn't done in the right place.
Timo Sirainen [Wed, 23 Mar 2016 01:08:06 +0000 (10:08 +0900)] 
doveadm: Getting user from USER environment wasn't done in the right place.

doveadm_mail_cmdline_init() is also called when parsing commands from
doveadm-server. The USER environment is supposed to be read only from
doveadm command line.

9 years agolazy-expunge: Fixed crash if lazy_expunge-namespace was not found.
Timo Sirainen [Mon, 21 Mar 2016 13:10:08 +0000 (22:10 +0900)] 
lazy-expunge: Fixed crash if lazy_expunge-namespace was not found.

9 years agolib: Avoid assert-crash in istream-concat at close.
Timo Sirainen [Mon, 21 Mar 2016 12:51:49 +0000 (21:51 +0900)] 
lib: Avoid assert-crash in istream-concat at close.

If stream was seeked to EOF, cur_input=NULL and closing the stream would cause
i_stream_concat_skip() to crash. Fixed this by making sure cur_input is never NULL.
This also adds a check to not allow seeking past EOF, but this shouldn't happen anyway.

9 years agolib: Small code cleanup to istream-concat - don't use a magic UINT_MAX value as error...
Timo Sirainen [Mon, 21 Mar 2016 12:46:47 +0000 (21:46 +0900)] 
lib: Small code cleanup to istream-concat - don't use a magic UINT_MAX value as error code

9 years agolib-storage: Support autoexpunging from wildcards mailbox names.
Timo Sirainen [Fri, 11 Mar 2016 04:44:41 +0000 (17:44 +1300)] 
lib-storage: Support autoexpunging from wildcards mailbox names.
For example:

mailbox Trash {
  autoexpunge = 30d
}
mailbox Trash/* {
  autoexpunge = 30d
}

9 years agodoveadm: Fix typos in error messages
Michael M Slusarz [Fri, 4 Mar 2016 02:55:03 +0000 (19:55 -0700)] 
doveadm: Fix typos in error messages

9 years agolazy-expunge: If lazy_expunge is set to namespace root, save all mails to the root...
Timo Sirainen [Fri, 11 Mar 2016 05:01:33 +0000 (18:01 +1300)] 
lazy-expunge: If lazy_expunge is set to namespace root, save all mails to the root mailbox.

So the difference is:

namespace {
  prefix = expunged/
  ..
}
plugin {
  # Move expunged mails to expunged/INBOX, expunged/Trash, etc. mailboxes
  lazy_expunge = expunged/
  # Move all expunged mails to "expunged" mailbox, which is the namespace root.
  lazy_expunge = expunged
}

9 years agolazy-expunge: Code cleanup - move destination mailbox name generation to its own...
Timo Sirainen [Fri, 11 Mar 2016 04:57:41 +0000 (17:57 +1300)] 
lazy-expunge: Code cleanup - move destination mailbox name generation to its own function

9 years agolib-fts: Fix unit tests for lib-fts.
Teemu Huovila [Wed, 16 Mar 2016 07:27:04 +0000 (09:27 +0200)] 
lib-fts: Fix unit tests for lib-fts.

9 years agodoveadm sync: Don't allow -R parameter.
Timo Sirainen [Wed, 16 Mar 2016 05:34:32 +0000 (16:34 +1100)] 
doveadm sync: Don't allow -R parameter.

-R implicitly enabled doveadm backup mode, which wasn't supposed to happen.

9 years agoplugins: fts-expunge-log - subtraction from and dumping of a flattened log
Phil Carmody [Mon, 29 Feb 2016 17:29:14 +0000 (19:29 +0200)] 
plugins: fts-expunge-log - subtraction from and dumping of a flattened log

This permits you to read a whole expunge log, remove records from the
in-memory copy of it, and write it back out to file.

NOTE: Inefficiently implemented. The hash is effectively rebuilt, this
time backed by a file, a record at a time, which implies O(n^2)
possibilities.

Signed-off-by: Phil Carmody <phil@dovecot.fi>
9 years agolib-http: client: Improved test-http-payload to test partial reading of response...
Stephan Bosch [Sat, 12 Mar 2016 00:56:55 +0000 (01:56 +0100)] 
lib-http: client: Improved test-http-payload to test partial reading of response payload.

9 years agolib-http: server: Improved test-http-payload to test partial reading of request payload.
Stephan Bosch [Thu, 3 Mar 2016 21:29:44 +0000 (22:29 +0100)] 
lib-http: server: Improved test-http-payload to test partial reading of request payload.

9 years agolib-http: server: Fixed handling of partially read request payload.
Stephan Bosch [Thu, 3 Mar 2016 21:28:47 +0000 (22:28 +0100)] 
lib-http: server: Fixed handling of partially read request payload.

This would sometimes cause the server to hang.

9 years agolib-fts: Limit maximum length of addresses found.
Teemu Huovila [Tue, 15 Mar 2016 08:48:31 +0000 (10:48 +0200)] 
lib-fts: Limit maximum length of addresses found.

The address tokenizer now takes a "maxlen" parameter, which
defaults to 254 bytes.

Previously addresses, or something looking like it, could
be of any length. This could cause trouble in fts backends.

9 years agolib-fts: Lift helper function out of generic tokenizer.
Teemu Huovila [Tue, 15 Mar 2016 08:47:20 +0000 (10:47 +0200)] 
lib-fts: Lift helper function out of generic tokenizer.

9 years agovirtual plugin: Fixed off-by-one in virtual_max_open_mailboxes check.
Timo Sirainen [Tue, 15 Mar 2016 23:55:01 +0000 (10:55 +1100)] 
virtual plugin: Fixed off-by-one in virtual_max_open_mailboxes check.

9 years agovirtual plugin: Don't assert-crash if backend mailbox is recreated while virtual...
Timo Sirainen [Tue, 15 Mar 2016 23:33:26 +0000 (10:33 +1100)] 
virtual plugin: Don't assert-crash if backend mailbox is recreated while virtual mailbox is open.

9 years agovirtual plugin: Handle backend mailbox deletion on backend open/sync
Timo Sirainen [Tue, 15 Mar 2016 23:23:52 +0000 (10:23 +1100)] 
virtual plugin: Handle backend mailbox deletion on backend open/sync

9 years agovirtual plugin: Code cleanup - remove confusing bbox_index_opened
Timo Sirainen [Tue, 15 Mar 2016 23:17:45 +0000 (10:17 +1100)] 
virtual plugin: Code cleanup - remove confusing bbox_index_opened

It was originally added because mailbox_open() was always called and we
wanted to know if the mailbox was open before it. But this code was already
removed.

9 years agovirtual plugin: If we detect backend box to be deleted, mark it permanently deleted.
Timo Sirainen [Tue, 15 Mar 2016 23:04:32 +0000 (10:04 +1100)] 
virtual plugin: If we detect backend box to be deleted, mark it permanently deleted.

9 years agodbox: Fixed pop3.order caching for mails without no specified order.
Timo Sirainen [Tue, 15 Mar 2016 22:30:20 +0000 (09:30 +1100)] 
dbox: Fixed pop3.order caching for mails without no specified order.

9 years agodoveadm-auth: Added missing code forgotten from commit 208754367
Timo Sirainen [Fri, 11 Mar 2016 06:03:34 +0000 (19:03 +1300)] 
doveadm-auth: Added missing code forgotten from commit 208754367

9 years agoauth: Code cleanup - avoid using void *context
Timo Sirainen [Fri, 11 Mar 2016 05:43:57 +0000 (18:43 +1300)] 
auth: Code cleanup - avoid using void *context

auth_request_callback_t always uses struct auth_client/master_connection*
in the context - no need to try to be too generic here.

9 years agodoveadm-auth: If auth_debug setting is enabled, send "debug" field to auth lookups.
Timo Sirainen [Fri, 11 Mar 2016 05:37:43 +0000 (18:37 +1300)] 
doveadm-auth: If auth_debug setting is enabled, send "debug" field to auth lookups.

The idea is that you could enable auth_debug for specific requests with e.g.:

doveadm -o auth_debug=yes user user@example.com

9 years agoauth: If auth request contains "debug" field, enable auth_debug=yes for the request.
Timo Sirainen [Fri, 11 Mar 2016 05:37:04 +0000 (18:37 +1300)] 
auth: If auth request contains "debug" field, enable auth_debug=yes for the request.

9 years agolib-fs: Fixed fs-sis to work again
Timo Sirainen [Thu, 10 Mar 2016 01:59:46 +0000 (14:59 +1300)] 
lib-fs: Fixed fs-sis to work again

9 years agodoveadm who: Don't require mask parameter.
Timo Sirainen [Fri, 4 Mar 2016 14:40:23 +0000 (16:40 +0200)] 
doveadm who: Don't require mask parameter.

9 years agoconfig: Escape regexps properly in settings-get.pl to avoid warnings with new Perl
Timo Sirainen [Fri, 4 Mar 2016 11:12:59 +0000 (13:12 +0200)] 
config: Escape regexps properly in settings-get.pl to avoid warnings with new Perl

9 years agofts: Added "doveadm fts tokenize" command.
Timo Sirainen [Thu, 3 Mar 2016 14:10:51 +0000 (16:10 +0200)] 
fts: Added "doveadm fts tokenize" command.

9 years agodoveadm-http: Fixed crash when no authentication was configured.
Aki Tuomi [Thu, 3 Mar 2016 09:53:05 +0000 (11:53 +0200)] 
doveadm-http: Fixed crash when no authentication was configured.

9 years agolib-index: After MAIL_INDEX_OPEN_FLAG_SAVEONLY access cache's read_buf wasn't always...
Timo Sirainen [Wed, 2 Mar 2016 22:15:30 +0000 (00:15 +0200)] 
lib-index: After MAIL_INDEX_OPEN_FLAG_SAVEONLY access cache's read_buf wasn't always reset.

This could have caused at least errors like:

Corrupted index cache file .../dovecot.index.cache: File too small

I'm not sure if it might have also returned stale data sometimes.

Easy way to reproduce this bug was:
imaptest copy=100 copybox=Trash &
imaptest box=Trash append=0

9 years agolib-index: Minor code cleanup - removed duplicate function prototype.
Timo Sirainen [Tue, 1 Mar 2016 20:11:05 +0000 (22:11 +0200)] 
lib-index: Minor code cleanup - removed duplicate function prototype.

9 years agodoveadm: Don't treat doveadm_api_key differently when it's unset vs set to empty.
Timo Sirainen [Wed, 2 Mar 2016 18:32:25 +0000 (20:32 +0200)] 
doveadm: Don't treat doveadm_api_key differently when it's unset vs set to empty.

9 years agodoveadm-http: Minor logging improvement - indicate error source
Aki Tuomi [Wed, 2 Mar 2016 15:45:18 +0000 (17:45 +0200)] 
doveadm-http: Minor logging improvement - indicate error source