summaryrefslogtreecommitdiff
path: root/auth
diff options
context:
space:
mode:
authorAndreas Schneider <asn@samba.org>2021-04-23 16:32:27 +0200
committerAndreas Schneider <asn@cryptomilk.org>2021-08-03 09:28:38 +0000
commit2daf3e79751d11a31a1e44d21b70517356301ee7 (patch)
treeeec2a46d0003abfa353f6fc374dccd930c033ba9 /auth
parent6d928eb1e8ea44f0d0aea4ec9b1b7c385a281193 (diff)
downloadsamba-2daf3e79751d11a31a1e44d21b70517356301ee7.tar.gz
auth:gensec: Use lpcfg_weak_crypto()
Pair-Programmed-With: Stefan Metzmacher <metze@samba.org> Signed-off-by: Andreas Schneider <asn@samba.org> Signed-off-by: Stefan Metzmacher <metze@samba.org> Reviewed-by: Andrew Bartlett <abartlet@samba.org>
Diffstat (limited to 'auth')
-rw-r--r--auth/gensec/gensec_start.c5
1 files changed, 3 insertions, 2 deletions
diff --git a/auth/gensec/gensec_start.c b/auth/gensec/gensec_start.c
index 906e3ee302c..bd5b7259d3f 100644
--- a/auth/gensec/gensec_start.c
+++ b/auth/gensec/gensec_start.c
@@ -29,10 +29,10 @@
#include "auth/gensec/gensec.h"
#include "auth/gensec/gensec_internal.h"
#include "lib/param/param.h"
+#include "lib/param/loadparm.h"
#include "lib/util/tsort.h"
#include "lib/util/samba_modules.h"
#include "lib/util/base64.h"
-#include "lib/crypto/gnutls_helpers.h"
#undef DBGC_CLASS
#define DBGC_CLASS DBGC_AUTH
@@ -51,7 +51,8 @@ bool gensec_security_ops_enabled(const struct gensec_security_ops *ops, struct g
ops->name,
ops->enabled);
- if (!samba_gnutls_weak_crypto_allowed() && ops->weak_crypto) {
+ if (ops->weak_crypto &&
+ lpcfg_weak_crypto(security->settings->lp_ctx) != SAMBA_WEAK_CRYPTO_ALLOWED) {
ok = false;
}