diff options
author | Sumit Bose <sbose@redhat.com> | 2020-12-01 14:12:33 +0100 |
---|---|---|
committer | Sumit Bose <sbose@redhat.com> | 2020-12-03 12:25:33 +0100 |
commit | ccf48aa7761065283483d667f3efaf33b5b2a728 (patch) | |
tree | 5dec6703bb914790ab5b33faf2fae3690329c9f9 /service | |
parent | e41de8344a09092ae4d973f495eef54a106a11ee (diff) |
service: make sure use_ldaps is not only set for automatic join
The check if ldaps is requested or not was only called if an automatic
join was enabled. With this patch it is checked in all cases.
Resolves: https://bugzilla.redhat.com/show_bug.cgi?id=1826964
Diffstat (limited to 'service')
-rw-r--r-- | service/realm-sssd-ad.c | 26 |
1 files changed, 13 insertions, 13 deletions
diff --git a/service/realm-sssd-ad.c b/service/realm-sssd-ad.c index 00a9093..ea5f28c 100644 --- a/service/realm-sssd-ad.c +++ b/service/realm-sssd-ad.c @@ -350,19 +350,6 @@ parse_join_options (JoinClosure *join, } /* - * Check if ldaps should be used and if membership software supports - * it. - */ - join->use_ldaps = realm_option_use_ldaps (options); - if (join->use_ldaps && - g_str_equal (software, REALM_DBUS_IDENTIFIER_SAMBA)) { - realm_diagnostics_info (join->invocation, - "Membership software %s does " - "not support ldaps, trying " - "without.", software); - } - - /* * If we are enrolling with a user password, then we have to use samba, * adcli only supports admin passwords. */ @@ -393,6 +380,19 @@ parse_join_options (JoinClosure *join, g_assert (software != NULL); + /* + * Check if ldaps should be used and if membership software supports + * it. + */ + join->use_ldaps = realm_option_use_ldaps (options); + if (join->use_ldaps && + g_str_equal (software, REALM_DBUS_IDENTIFIER_SAMBA)) { + realm_diagnostics_info (join->invocation, + "Membership software %s does " + "not support ldaps, trying " + "without.", software); + } + if (g_str_equal (software, REALM_DBUS_IDENTIFIER_ADCLI)) { join->use_adcli = TRUE; join->packages = ADCLI_PACKAGES; |