]> git.ipfire.org Git - thirdparty/dovecot/core.git/commitdiff
lib-master, auth: Fix clearing memory
authorTimo Sirainen <timo.sirainen@dovecot.fi>
Thu, 13 Sep 2018 12:29:45 +0000 (15:29 +0300)
committerVille Savolainen <ville.savolainen@dovecot.fi>
Thu, 20 Sep 2018 08:45:46 +0000 (11:45 +0300)
It doesn't look like these being wrong were causing any bugs.

src/auth/password-scheme-sodium.c
src/lib-master/master-service-haproxy.c

index b502fc5cfad2db99eac737e0a57abd1af0678e53..3e2f6bdf1d40f2bbfe8637b48362da59b87cceb9 100644 (file)
@@ -38,7 +38,7 @@ generate_argon2id(const char *plaintext, const struct password_generate_params *
        unsigned long long rounds = params->rounds;
        size_t memlimit;
        char result[crypto_pwhash_argon2id_STRBYTES];
-       i_zero(result);
+       i_zero(&result);
 
        if (rounds == 0)
                rounds = crypto_pwhash_argon2id_OPSLIMIT_INTERACTIVE;
index a9a73e8f02c0a2dadde5cefed3829a6e1f2ac2e7..f1a3bfdc3db54b624968e814b4705d0a6c020647 100644 (file)
@@ -301,7 +301,7 @@ master_service_haproxy_read(struct master_service_haproxy_conn *hpconn)
           with the first recv() call.
         */
        i_zero(&buf);
-       i_zero(rbuf);
+       i_zero(&rbuf);
 
        /* see if there is a HAPROXY protocol command waiting */
        if ((ret = master_service_haproxy_recv(fd, &buf, sizeof(buf), MSG_PEEK))<=0) {