summaryrefslogtreecommitdiff
path: root/source3/libnet/libnet_join.c
diff options
context:
space:
mode:
authorPavel Filipenský <pfilipensky@samba.org>2024-02-13 13:43:50 +0100
committerPavel Filipensky <pfilipensky@samba.org>2024-07-26 17:12:36 +0000
commiteeb79875c6edc82bfcaa8ed5d0eade77d64f7e8d (patch)
tree158c5c9485f2b89124d157f71d04f9980308e83e /source3/libnet/libnet_join.c
parent683f6eec40f2efbb122329800ebb2f5d2f518746 (diff)
downloadsamba-eeb79875c6edc82bfcaa8ed5d0eade77d64f7e8d.tar.gz
samba-eeb79875c6edc82bfcaa8ed5d0eade77d64f7e8d.tar.bz2
samba-eeb79875c6edc82bfcaa8ed5d0eade77d64f7e8d.zip
s3:libnet: Sync keytab during libnet_join_create_keytab()
BUG: https://bugzilla.samba.org/show_bug.cgi?id=6750 Signed-off-by: Pavel Filipenský <pfilipensky@samba.org> Reviewed-by: Stefan Metzmacher <metze@samba.org>
Diffstat (limited to 'source3/libnet/libnet_join.c')
-rw-r--r--source3/libnet/libnet_join.c10
1 files changed, 2 insertions, 8 deletions
diff --git a/source3/libnet/libnet_join.c b/source3/libnet/libnet_join.c
index 490f8ea37ab..d49d54436bb 100644
--- a/source3/libnet/libnet_join.c
+++ b/source3/libnet/libnet_join.c
@@ -859,15 +859,9 @@ static ADS_STATUS libnet_join_set_etypes(TALLOC_CTX *mem_ctx,
static bool libnet_join_create_keytab(TALLOC_CTX *mem_ctx,
struct libnet_JoinCtx *r)
{
- if (!USE_SYSTEM_KEYTAB) {
- return true;
- }
+ NTSTATUS ntstatus = sync_pw2keytabs();
- if (ads_keytab_create_default(r->in.ads) != 0) {
- return false;
- }
-
- return true;
+ return NT_STATUS_IS_OK(ntstatus);
}
/****************************************************************