]> git.ipfire.org Git - thirdparty/samba.git/commitdiff
s4:kdc: Check return value from ldb_dn_get_linearized()
authorJoseph Sutton <josephsutton@catalyst.net.nz>
Thu, 10 Aug 2023 03:53:23 +0000 (15:53 +1200)
committerAndrew Bartlett <abartlet@samba.org>
Mon, 14 Aug 2023 04:57:34 +0000 (04:57 +0000)
Signed-off-by: Joseph Sutton <josephsutton@catalyst.net.nz>
Reviewed-by: Andrew Bartlett <abartlet@samba.org>
source4/kdc/db-glue.c

index 37f9734fa9192da5c9e20c421d372c538e1b2c4c..22990e5133ed13d443b090036b0f373c1c8cfe1c 100644 (file)
@@ -108,6 +108,11 @@ static void auth_sam_trigger_repl_secret(TALLOC_CTX *mem_ctx,
         }
 
         r.in.user_dn = ldb_dn_get_linearized(user_dn);
+        if (r.in.user_dn == NULL) {
+                DBG_WARNING("Unable to get user DN\n");
+                TALLOC_FREE(tmp_ctx);
+                return;
+        }
 
         /*
          * This seem to rely on the current IRPC implementation,