summaryrefslogtreecommitdiff
path: root/source3/libnet
diff options
context:
space:
mode:
authorGünther Deschner <gd@samba.org>2021-02-19 15:00:24 +0100
committerGünther Deschner <gd@samba.org>2021-07-14 16:49:30 +0000
commiteff9610e7b02726d25ed952c5b1440f4d763b63c (patch)
treeafc5bff6241a10da32f9f4bfc32d9eb30c0cff33 /source3/libnet
parent799384792a8ef004a74ae3cf11fdf839eacfca2f (diff)
downloadsamba-eff9610e7b02726d25ed952c5b1440f4d763b63c.tar.gz
s3-libnet_join: always check config correctness while joining offline
Guenther Signed-off-by: Guenther Deschner <gd@samba.org> Reviewed-by: Alexander Bokovoy <ab@samba.org>
Diffstat (limited to 'source3/libnet')
-rw-r--r--source3/libnet/libnet_join.c12
1 files changed, 9 insertions, 3 deletions
diff --git a/source3/libnet/libnet_join.c b/source3/libnet/libnet_join.c
index 48d2a2db046..263420a2159 100644
--- a/source3/libnet/libnet_join.c
+++ b/source3/libnet/libnet_join.c
@@ -2763,11 +2763,12 @@ static WERROR libnet_DomainJoin(TALLOC_CTX *mem_ctx,
return ntstatus_to_werror(status);
}
- if (!r->in.provision_computer_account_only) {
- werr = libnet_join_check_config(mem_ctx, r);
- if (!W_ERROR_IS_OK(werr)) {
+ werr = libnet_join_check_config(mem_ctx, r);
+ if (!W_ERROR_IS_OK(werr)) {
+ if (!r->in.provision_computer_account_only) {
goto done;
}
+ /* do not fail when only provisioning */
}
#ifdef HAVE_ADS
@@ -2914,6 +2915,11 @@ static WERROR libnet_DomainOfflineJoin(TALLOC_CTX *mem_ctx,
return ntstatus_to_werror(status);
}
+ werr = libnet_join_check_config(mem_ctx, r);
+ if (!W_ERROR_IS_OK(werr)) {
+ return werr;
+ }
+
return WERR_OK;
#if 0
/* the following fields are currently not filled in */