]> git.ipfire.org Git - thirdparty/samba.git/commitdiff
HEIMDAL: don't bother seeing q if not sent
authorLove Hornquist Astrand <lha@h5l.org>
Mon, 29 Apr 2013 18:42:46 +0000 (11:42 -0700)
committerKarolin Seeger <kseeger@samba.org>
Sat, 23 Dec 2017 20:16:25 +0000 (21:16 +0100)
BUG: https://bugzilla.samba.org/show_bug.cgi?id=12986

Reviewed-by: Stefan Metzmacher <metze@samba.org>
Reviewed-by: Andrew Bartlett <abartlet@samba.org>
(cherry picked from heimdal commit 19f9fdbcea11013cf13ac72c416f161ee55dee2b)

Autobuild-User(master): Andrew Bartlett <abartlet@samba.org>
Autobuild-Date(master): Mon Aug 28 15:10:54 CEST 2017 on sn-devel-144

(cherry picked from commit dd3e06f14ec1788a59e4c6ba4ea165fd77b9135e)

source4/heimdal/kdc/pkinit.c

index 3a9e8f266cefb012e58925e3213a54ab9bd5ce5f..c874847cffde642552cb9dc04319c6592c4edfb9 100644 (file)
@@ -381,9 +381,12 @@ get_dh_param(krb5_context context,
     dh->g = integer_to_BN(context, "DH base", &dhparam.g);
     if (dh->g == NULL)
        goto out;
-    dh->q = integer_to_BN(context, "DH p-1 factor", &dhparam.q);
-    if (dh->g == NULL)
-       goto out;
+
+    if (dhparam.q) {
+       dh->q = integer_to_BN(context, "DH p-1 factor", dhparam.q);
+       if (dh->g == NULL)
+           goto out;
+    }
 
     {
        heim_integer glue;