]> git.ipfire.org Git - thirdparty/samba.git/commitdiff
s4:dsdb: Burn the memory of hashes returned by samdb_result_hashes()
authorAndreas Schneider <asn@samba.org>
Tue, 26 Jul 2022 09:31:54 +0000 (11:31 +0200)
committerAndreas Schneider <asn@cryptomilk.org>
Thu, 28 Jul 2022 11:51:29 +0000 (11:51 +0000)
Signed-off-by: Andreas Schneider <asn@samba.org>
Reviewed-by: Stefan Metzmacher <metze@samba.org>
source4/dsdb/common/util.c

index a7a93a9a06650714dd4e92a246622e793c90a098..112917544a31c1f58c83be0c79739a4c41269484 100644 (file)
@@ -508,6 +508,7 @@ unsigned int samdb_result_hashes(TALLOC_CTX *mem_ctx, const struct ldb_message *
        if (! *hashes) {
                return 0;
        }
+       talloc_keep_secret(*hashes);
 
        for (i=0;i<count;i++) {
                memcpy((*hashes)[i].hash, (i*16)+(char *)val->data, 16);