]> git.ipfire.org Git - thirdparty/dovecot/core.git/commitdiff
submission-login: Fix pipelining of commands beyond AUTH.
authorStephan Bosch <stephan.bosch@dovecot.fi>
Sun, 24 Dec 2017 11:17:48 +0000 (12:17 +0100)
committerVille Savolainen <ville.savolainen@dovecot.fi>
Wed, 31 Jan 2018 14:05:57 +0000 (16:05 +0200)
The master_data_prefix was initialized wrong; it omitted the expected '\0' byte after the helo field.

src/submission-login/client-authenticate.c

index a993effd969edb0dec60c6dbf60c3ff8b4215e06..d72c3df41f41dac174c85b2482b709ca5386c6ac 100644 (file)
@@ -254,7 +254,7 @@ int cmd_auth(void *conn_ctx, struct smtp_server_cmd_ctx *cmd,
        /* pass ehlo parameter to post-login service upon successful login */
        i_free(client->master_data_prefix);
        client->master_data_prefix = (void *)prefix;
-       client->master_data_prefix_len = strlen(prefix);
+       client->master_data_prefix_len = strlen(prefix) + 1;
 
        subm_client->pending_auth = cmd;