14995d3b1e547f84ec55314d53a9f0bbd1110b0d |
|
07-Feb-2018 |
Timo Sirainen <timo.sirainen@dovecot.fi> |
doveadm: client: Set IO only after enabling SSL
io_add_istream() needs to be used with the SSL istream, otherwise it can
cause hangs. |
bcb4e51a409d94ae670de96afb8483a4f7855294 |
|
01-Jan-2018 |
Stephan Bosch <stephan.bosch@dovecot.fi> |
Updated copyright notices to include the year 2018. |
08853ba590a1be942d7a7b0db29789af991d3d0c |
|
22-Dec-2017 |
Timo Sirainen <timo.sirainen@dovecot.fi> |
doveadm: Fix potential crash or reading garbage from doveadm-server
The connection's input buffer may have been reallocated or otherwise moved
while checking for log input. |
b8f02c99e2bcb558b92a2d8038d3b6462f6b5835 |
|
15-Nov-2017 |
Timo Sirainen <timo.sirainen@dovecot.fi> |
doveadm: client - Cleanup: Simplify the input loop |
4a913ff77a6c9a294fb4ed74b41827edb74a2852 |
|
15-Nov-2017 |
Timo Sirainen <timo.sirainen@dovecot.fi> |
doveadm: client - Cleanup: Remove unnecessary stream_errno check |
73d53974179a6aa6037d2fd686c16b8613646160 |
|
15-Nov-2017 |
Timo Sirainen <timo.sirainen@dovecot.fi> |
doveadm: client - Cleanup: Remove unnecessary code indentation |
9f869f9ab6552b75f18f576eb45229e2c698eb59 |
|
15-Nov-2017 |
Timo Sirainen <timo.sirainen@dovecot.fi> |
doveadm: client - Cleanup: Handle input NULL first |
20638158a97ccd6750081f6da058d11adcfe3001 |
|
15-Nov-2017 |
Timo Sirainen <timo.sirainen@dovecot.fi> |
doveadm: client - Cleanup: Set authenticate_sent in a more proper location |
fd91d0e92ee8b5f8119019eb277d323528f4e031 |
|
15-Nov-2017 |
Timo Sirainen <timo.sirainen@dovecot.fi> |
doveadm: client - Cleanup: Don't check authenticate_sent twice |
b52b16e9b2064e1fe047e1af0df29356bedca3a3 |
|
15-Nov-2017 |
Timo Sirainen <timo.sirainen@dovecot.fi> |
doveadm: client - Read any pipelined replies after authentication reply
This practically shouldn't happen. |
1a492d1e242f4061683f8a82a379c9e9591fa6fc |
|
15-Nov-2017 |
Timo Sirainen <timo.sirainen@dovecot.fi> |
doveadm: client - Cleanup: Read server input only once in the input handler |
8a6710d679d728bc96090f1a587f3abd9bed2d91 |
|
15-Nov-2017 |
Timo Sirainen <timo.sirainen@dovecot.fi> |
doveadm: client - Fail if server sends more than one VERSION reply in handshake |
f7292478c87abb38442503423140477d776b5b6c |
|
09-Nov-2017 |
Timo Sirainen <timo.sirainen@dovecot.fi> |
doveadm: client - Fix connecting to UNIX sockets that don't need authentication
Trying to access doveadm UNIX socket that didn't require authentication
failed with:
Error: doveadm server sent invalid handshake: ... |
d85b09627498574495d8174c744c8171f6e9b3b4 |
|
09-Nov-2017 |
Timo Sirainen <timo.sirainen@dovecot.fi> |
doveadm: client - Cleanup: Rename handshaked to authenticate_sent
This better describes what it does. |
1b7459fda7de40f963e64da1886af68ad05fd10d |
|
02-Nov-2017 |
Timo Sirainen <timo.sirainen@dovecot.fi> |
doveadm: Send hostname without ":port" as TLS SNI name for outgoing SSL connections. |
97b6a92d57561694a18635561fcd80b5d1342617 |
|
01-Nov-2017 |
Timo Sirainen <timo.sirainen@dovecot.fi> |
doveadm: Ignore errors also on outgoing SSL connection ostreams
Setting the errors as ignored on the plain ostream was done too late, so ssl
ostream didn't inherit the error handling flag. |
a2583397219ebbb877fcf84107f0ca7f56362760 |
|
30-Oct-2017 |
Timo Sirainen <timo.sirainen@dovecot.fi> |
lib-mail: ostream-dot - Require o_stream_finish() to write the trailer
Similar to ostream-zlib. |
187fbf157d5c42f9f06ce52884fefbb4f66c070d |
|
13-Oct-2017 |
Timo Sirainen <timo.sirainen@dovecot.fi> |
doveadm proxy: Don't crash if remote doesn't support log proxying |
f85250d819357094d456fbdde390ade0fcabe0b7 |
|
10-Oct-2017 |
Aki Tuomi <aki.tuomi@dovecot.fi> |
doveadm: Return after destroying connection
Prevents NULL deferences, found by coverity. |
59d3aed7ae78e2c67a130c5c5adc1084fa6d382b |
|
09-Oct-2017 |
Timo Sirainen <timo.sirainen@dovecot.fi> |
doveadm: Add remote(host) prefix to all proxied logs |
c9dd53f7180a78668cbc1e6eb34d5b1722beccb9 |
|
05-Oct-2017 |
Aki Tuomi <aki.tuomi@dovecot.fi> |
doveadm: Deliver remote logs over doveadm socket |
ce700412721a0526fd69a93d99013d19487e4029 |
|
05-Oct-2017 |
Aki Tuomi <aki.tuomi@dovecot.fi> |
doveadm: Refactor server/client code to support versioning properly
This way we can distinguish between old and new server side |
f78d021f39c408623816fcbadf9f5f0db345aac1 |
|
05-Oct-2017 |
Aki Tuomi <aki.tuomi@dovecot.fi> |
doveadm-server: Refactor connection handshake and authentication
Simplifies next change |
a943ed0f901e312445fd393249b91932797bba79 |
|
03-Oct-2017 |
Josef 'Jeff' Sipek <jeff.sipek@dovecot.fi> |
global: use i_close_fd{,_path}() instead of open-coding them |
be5773cb4d6edae8a5d9f300c3c7375cdd33826e |
|
19-Sep-2017 |
Josef 'Jeff' Sipek <jeff.sipek@dovecot.fi> |
global: start relying on [io]_stream_destroy(NULL) being a no-op
Cleanup performed with the following semantic patch:
@@
expression E;
@@
- if (E != NULL) {
- i_stream_destroy(&E);
- }
+ i_stream_destroy(&E);
@@
expression E;
@@
- if (E != NULL) {
- o_stream_destroy(&E);
- }
+ o_stream_destroy(&E); |
0d1b8b6bec79746c5d89d57dd8c1688946bd9237 |
|
19-Sep-2017 |
Josef 'Jeff' Sipek <jeff.sipek@dovecot.fi> |
global: start relying on timeout_remove(NULL) being a no-op
Cleanup performed with the following semantic patch:
@@
expression E;
@@
- if (E != NULL) {
- timeout_remove(&E);
- }
+ timeout_remove(&E); |
5f1d689131a75c39f064cbd4202373e7edf78f18 |
|
19-Sep-2017 |
Josef 'Jeff' Sipek <jeff.sipek@dovecot.fi> |
global: start relying on io_remove{,_closed}(NULL) being a no-op
Cleanup performed with the following semantic patch:
@@
expression E;
@@
- if (E != NULL) {
- io_remove(&E);
- }
+ io_remove(&E);
@@
expression E;
@@
- if (E != NULL) {
- io_remove_closed(&E);
- }
+ io_remove_closed(&E); |
89387c6f098be5a8589c30109d9744ef7c5c336c |
|
22-Mar-2017 |
Aki Tuomi <aki.tuomi@dovecot.fi> |
doveadm: Send and receive exit codes correctly
The old code would assume TEMPFAIL for almost everything. |
b3c095d1fb0bb86695d92c2045eb09e985623934 |
|
22-Feb-2017 |
Aki Tuomi <aki.tuomi@dovecot.fi> |
global: Fix ssl_set usage
Remove verify_remote_cert, as it's always TRUE now.
Set allow_invalid_cert to TRUE if verification is
not required. |
2454dfa32c93c20a8522c6ed42fe057baaac9f9a |
|
01-Jan-2017 |
Stephan Bosch <stephan.bosch@dovecot.fi> |
Updated copyright notices to include the year 2017. |
efe78d3ba24fc866af1c79b9223dc0809ba26cad |
|
24-Dec-2016 |
Stephan Bosch <stephan.bosch@dovecot.fi> |
global: Replaced all instances of memset(p, 0, sizeof(*p)) with the new i_zero() macro.
Used the following script:
C_FILES=`git ls-files *.c`
H_FILES=`git ls-files *.h`
for F in "$C_FILES $H_FILES"; do
echo "$F"
perl -p -i -e 's/safe_memset\(&\(?([^,]*)\)?,\s*0,\s*sizeof\(\g1\)\)/i_zero_safe(&$1)/g' $F
perl -p -i -e 's/safe_memset\(([^,]*),\s*0,\s*sizeof\(\*\g1\)\)/i_zero_safe($1)/g' $F
perl -p -i -e 's/memset\(&\(?([^,]*)\)?,\s*0,\s*sizeof\(\g1\)\)/i_zero(&$1)/g' $F
perl -p -i -e 's/memset\(([^,]*),\s*0,\s*sizeof\(\*\g1\)\)/i_zero($1)/g' $F
done |
4e7bbab858a56397bcf95bf5941edf98954e034f |
|
08-Aug-2016 |
Timo Sirainen <timo.sirainen@dovecot.fi> |
doveadm: Fixed hanging when printing output from different server connections. |
bab7538be66486773ce10356bdd385f66c9cb0bf |
|
08-Aug-2016 |
Timo Sirainen <timo.sirainen@dovecot.fi> |
doveadm: Avoid recursively calling server input callback
Probably doesn't fix anything, but it could cause confusing backtraces at
least. |
be25bbb904b96f4c44602b2f96cf2d30f037fc93 |
|
08-Aug-2016 |
Timo Sirainen <timo.sirainen@dovecot.fi> |
doveadm-server: Fixed potential hang when reading replies to multiple commands |
483f53880bdfb62f4757f17881bc35f8a2129805 |
|
08-Aug-2016 |
Timo Sirainen <timo.sirainen@dovecot.fi> |
doveadm: Revert earlier NUL-printing change 793b024bf.
It changes the output in ways that are a bit difficult to fix. Also the
the important part where NULs printing is useful is in a message body,
which should work even without this change. So for now just revert it. |
793b024bf9ed2755c692926b6cab2e89abeca424 |
|
08-Aug-2016 |
Timo Sirainen <timo.sirainen@dovecot.fi> |
doveadm: When printing input from doveadm-server, don't truncate at NUL. |
9ca065aa3c125f63ac68939b109ea6ec36e5917d |
|
08-Aug-2016 |
Aki Tuomi <aki.tuomi@dovecot.fi> |
doveadm: Streamline tabunescape |
c5924dd8f129d6d5ba77e33d25e83a3700deafb1 |
|
06-Jul-2016 |
Timo Sirainen <timo.sirainen@dovecot.fi> |
global: Removed redundant corking in ostream flush callbacks. |
095481fee84040436ce2dccca472c9bb1df4d5bb |
|
16-Jun-2016 |
Timo Sirainen <timo.sirainen@dovecot.fi> |
lib-ssl-iostream: Changed require_valid_cert -> allow_invalid_cert
We should default to being safe. |
0dffa25d211be541ee3c953b23566a1a990789df |
|
06-Jun-2016 |
Timo Sirainen <timo.sirainen@dovecot.fi> |
global: unsigned int:1 -> bool:1
perl -i -pe 's/unsigned int ([^,:;]+):1;/bool $1:1;/' **/*.[ch] |
e93184a9055c2530366dfe617e07199603c399dd |
|
06-Jun-2016 |
Martti Rannanjärvi <martti.rannanjarvi@dovecot.fi> |
lib: remove autoclose parameter from [io]_stream_create_fd
Use [io]_stream_create_fd_autoclose() for autoclose. |
378e6cb162b355d6f103526505bc00b9a78962e7 |
|
30-May-2016 |
Timo Sirainen <timo.sirainen@dovecot.fi> |
o_stream_send_istream() API changed again
The new API enforces the caller to correctly handle all the possible
situations. It also makes in unambiguous whether to wait for input or
output stream. |
d04f3e064ceb2ba1d734182937a7115739ebadbe |
|
18-May-2016 |
Timo Sirainen <timo.sirainen@dovecot.fi> |
global: Simplify code with the new o_stream_send_istream() API |
02c335c23bf5fa225a467c19f2c063fb0dc7b8c3 |
|
12-Jan-2016 |
Timo Sirainen <timo.sirainen@dovecot.fi> |
global: freshen copyright
git ls-files | xargs perl -p -i -e 's/(\d+)-201[0-5]/$1-2016/g;s/ (201[0-5]) Dovecot/ $1-2016 Dovecot/' |
009217abb57a24a4076092e8e4e165545747839e |
|
29-Aug-2015 |
Stephan Bosch <stephan@rename-it.nl> |
Changed type of internet port values to in_port_t everywhere.
Created special SET_IN_PORT setting type for internet port values.
Created net_str2port() for parsing internet port values.
Removed several atoi() invocations in the process. |
c4d1ceab4458cf894d83d5634059bc1fc7c680ba |
|
30-Jun-2015 |
Timo Sirainen <tss@iki.fi> |
doveadm: Added doveadm_username to specify the username for authentication.
The default is still "doveadm" and the server side doesn't currently support
anything except "doveadm". |
90f953632098557bed44dde527bf84533c4222cb |
|
09-May-2015 |
Timo Sirainen <tss@iki.fi> |
doveadm-server: Fixed potential crash if doveadm client disconnected
Found by Coverity |
32c779d5d0b3dabc697408e6b5d9d2e652180b33 |
|
15-Feb-2015 |
Timo Sirainen <tss@iki.fi> |
doveadm: Added support for mail commands to read an input stream (from stdin)
This is done by calling doveadm_mail_get_input() from the command's init()
function. Currently it reads the entire input into a seekable istream with
hardcoded 5 minute timeout. The input stream sending works also through
doveadm proxying.
This could probably be used by dsync at some point to support proxying over
doveadm proxies, but that would require some more work. Especially a flag
for commands to specify that they allow non-blocking input streams. |
7cb128dc4cae2a03a742f63ba7afee23c78e3af0 |
|
05-Jan-2015 |
Phil Carmody <phil@dovecot.fi> |
global: freshen copyright
Robomatically:
git ls-files | xargs perl -p -i -e 's/(\d+)-201[0-4]/$1-2015/g;s/ (201[0-4]) Dovecot/ $1-2015 Dovecot/'
Happy 2015 everyone!
Signed-off-by: Phil Carmody <phil@dovecot.fi> |
a8c5a86d183db25a57bf193c06b41e092ec2e151 |
|
04-Feb-2014 |
Timo Sirainen <tss@iki.fi> |
Updated copyright notices to include year 2014. |
98bdd7c244be24484c98f6927fc5108173bd9694 |
|
06-Aug-2013 |
Timo Sirainen <tss@iki.fi> |
doveadm: If server connection gets disconnected, log the reason. |
956b8eea7ae479a38b25175447fc8eac2df30480 |
|
06-Aug-2013 |
Timo Sirainen <tss@iki.fi> |
doveadm: If we get disconnected from server, log the reason. |
8ad7aa4ddf9e37fc1aefdf84f90071f49fc2619c |
|
13-Jun-2013 |
Timo Sirainen <tss@iki.fi> |
doveadm: Pass through the exit code from doveadm-server to client. |
b4d850a0ffd519c1c745557568daf7d48e18c820 |
|
04-Apr-2013 |
Timo Sirainen <tss@iki.fi> |
lib-ssl-iostream: Simplified certificate validation. Also give better error messages. |
3b4bd183cc469f70eb91d82a7f01f60ffc24ca5b |
|
04-Apr-2013 |
Timo Sirainen <tss@iki.fi> |
lib-ssl-iostream: Added support for TLS SNI, which caused some API changes. |
9709107819ba60d41f737279dd070b40d46b4120 |
|
04-Apr-2013 |
Timo Sirainen <tss@iki.fi> |
lib-ssl-iostream: If handshake callback fails, close the iostreams immediately.
This way the callback itself doesn't have to do it. Also fixes errors caused
by it, since they didn't close the ostream. |
ac645fe16c0619771c0a961db91df16485513c52 |
|
04-Apr-2013 |
Timo Sirainen <tss@iki.fi> |
lib-ssl-iostream: ssl_iostream_set_handshake_callback() API changed.
The callback can now return the error message to caller instead of having to
log it itself. |
ba1c847d0af4afe4787ed470d0c818e948e184e2 |
|
04-Apr-2013 |
Timo Sirainen <tss@iki.fi> |
lib-ssl-iostream: API changes to return error strings if init() functions fail.
This also fixed a couple of broken error handlings. |
8c5d1951a2e5bced3bfcb7fc6c2fac8d4bf47341 |
|
25-Feb-2013 |
Timo Sirainen <tss@iki.fi> |
dsync: Added tcps (TCP+SSL) target. |
07ce366ac19bc96be354d26a04305de300c6fe3e |
|
25-Feb-2013 |
Timo Sirainen <tss@iki.fi> |
dsync: Use iostreams instead of fd when receiving connection from doveadm-server. |
0a9cb42cbb135e3200cbfbb657820304cca8ecb8 |
|
24-Feb-2013 |
Timo Sirainen <tss@iki.fi> |
dsync: Added tcp:host[:port] target for syncing via doveadm-server. |
10a245789f3b0637dfb8fbd12c6bf5eab2a2b18e |
|
24-Feb-2013 |
Timo Sirainen <tss@iki.fi> |
doveadm: If doveadm-server sends broken input, disconnect. |
250a06cde50c4004ac1cc72279b75a229a7f90f5 |
|
24-Feb-2013 |
Timo Sirainen <tss@iki.fi> |
doveadm: When connecting to doveadm socket without :port, use doveadm_port setting. |
5a580c3a38ced62d4bcc95b8ac7c4f2935b5d294 |
|
02-Feb-2013 |
Timo Sirainen <tss@iki.fi> |
Oops :) Update copyrights to 2013 without breaking all .c files. |
cca4ba2a504d70a9fe9fee37f8433997359de52c |
|
02-Feb-2013 |
Timo Sirainen <tss@iki.fi> |
Updated copyright notices to include year 2013. |
f5d8b6d7374afa210a391777652603c44ac935d4 |
|
14-Jan-2013 |
Timo Sirainen <tss@iki.fi> |
Several fixes to handling "istream input line too long" conditions. |
ceae307cf6506c655039fc64d93dfc5e071d86ac |
|
27-Nov-2012 |
Timo Sirainen <tss@iki.fi> |
doveadm: Don't disconnect from server too early while there are still commands. |
bdd36cfdba3ff66d25570a9ff568d69e1eb543cf |
|
03-Oct-2012 |
Timo Sirainen <tss@iki.fi> |
Renamed network.[ch] to net.[ch].
The function prefixes already started with net_ instead of network_.
And icecap wants to use network.h for other purpose. :) |
da5bcae5bb5a4216fabdaaba3b9b786967944996 |
|
02-Oct-2012 |
Timo Sirainen <tss@iki.fi> |
doveadm: Fixed printing large input from doveadm-server. |
e34d170f8f0e084bd94bfbc1a7085ece67e508df |
|
25-Jun-2012 |
Timo Sirainen <tss@iki.fi> |
Make sure we check all the functions' return values. Minor API changes to simplify this.
Checked using a patched clang that adds attribute(warn_unused_result) to all
functions. This commit fixes several error handling mistakes. |
e2a88d59c0d47d63ce1ad5b1fd95e487124a3fd4 |
|
24-Jun-2012 |
Timo Sirainen <tss@iki.fi> |
Added o_stream_nsend*() and related functions to make delayed error handling safer.
Once o_stream_nsend*() is called, o_stream_nfinish() must be called before
stream is destroyed to finish checking if there were any errors. If
something failed and the stream is just wanted to be closed,
o_stream_ignore_last_errors() can be called.
For streams where errors don't really make any difference (network sockets)
you can call o_stream_set_no_error_handling() immediately after creating the
stream. |
7d359c1719bf6ff228a96c66d27f5cfa239cb31d |
|
07-Mar-2012 |
Timo Sirainen <tss@iki.fi> |
doveadm: Handle -NOUSER replies from doveadm-server. |
5f5870385cff47efd2f58e7892f251cf13761528 |
|
12-Feb-2012 |
Timo Sirainen <tss@iki.fi> |
Updated copyright notices to include year 2012. |
30eb745a4fb4a16dde979cd8db7ab18f5f0c0e2e |
|
22-Sep-2011 |
Timo Sirainen <tss@iki.fi> |
doveadm server: Previous non-authentication fix broken authentication. |
8c2f2e90b746c6d50ffa92a2083cd1bbe5c6c2db |
|
19-Sep-2011 |
Timo Sirainen <tss@iki.fi> |
doveadm: Fixed sending commands to doveadm server when it didn't require authentication. |
3c6807cf4170fc8eaead49267b1d12a5d91400eb |
|
29-Aug-2011 |
Timo Sirainen <tss@iki.fi> |
doveadm: Fixed authentication with remote doveadm server. |
10b8040903b1d1591f1d44552ff466c8789b8814 |
|
07-Aug-2011 |
Timo Sirainen <tss@iki.fi> |
doveadm-server: Many fixes to make it actually work properly. |
d472804f391e86f7fec7062b97e372747bd159c1 |
|
20-May-2011 |
Timo Sirainen <tss@iki.fi> |
doveadm: Added simple PLAIN authentication for remote connections.
Currently clients are required to use "doveadm" as the username and the
password must match doveadm_password setting. When using doveadm as a
client, it automatically uses these settings when connecting to remote
servers. |
2e37d45867d081db150ab78dad303b9077aea24f |
|
04-Mar-2011 |
Timo Sirainen <tss@iki.fi> |
Updated copyright notices to include year 2011. |
183bea41fa640dc8117f3eb45ff935cd81377a84 |
|
04-Mar-2011 |
Timo Sirainen <tss@iki.fi> |
Updated copyright notices to include year 2011. |
71df09024cea5f2faa93da3bb9513ee96ba6bf22 |
|
23-Jul-2010 |
Timo Sirainen <tss@iki.fi> |
doveadm: Added client/server architecture support for running mail commands.
This is done when doveadm_worker_count is non-zero. |