s3:winbindd: remove useless 'renewable' argument to ads_cached_connection_connect()
authorStefan Metzmacher <metze@samba.org>
Tue, 5 Mar 2024 12:22:37 +0000 (13:22 +0100)
committerStefan Metzmacher <metze@samba.org>
Tue, 14 May 2024 10:18:31 +0000 (10:18 +0000)
There's really no need to get a reneable ticket for an ldap connection,
we currently always do a kinit for each connection anyway.

Signed-off-by: Stefan Metzmacher <metze@samba.org>
Reviewed-by: Andreas Schneider <asn@samba.org>
source3/winbindd/winbindd_ads.c

index 7d6324033ea2f0b8980cea7cb8fd58206dbce952..1714f0e6ef827808974c767c4b296c46488bf392 100644 (file)
@@ -86,7 +86,6 @@ static void ads_cached_connection_reuse(ADS_STRUCT **adsp)
  * @param[in]    ldap_server      DNS name of server to connect to
  * @param[in]    password         Our machine account secret
  * @param[in]    auth_realm       Realm of local domain for creating krb token
- * @param[in]    renewable        Renewable ticket time
  *
  * @return ADS_STATUS
  */
@@ -95,7 +94,6 @@ static ADS_STATUS ads_cached_connection_connect(const char *target_realm,
                                                const char *ldap_server,
                                                char *password,
                                                char *auth_realm,
-                                               time_t renewable,
                                                TALLOC_CTX *mem_ctx,
                                                ADS_STRUCT **adsp)
 {
@@ -128,7 +126,6 @@ static ADS_STATUS ads_cached_connection_connect(const char *target_realm,
        ADS_TALLOC_CONST_FREE(ads->auth.password);
        ADS_TALLOC_CONST_FREE(ads->auth.realm);
 
-       ads->auth.renewable = renewable;
        ads->auth.password = talloc_strdup(ads, password);
        if (ads->auth.password == NULL) {
                status = ADS_ERROR_NT(NT_STATUS_NO_MEMORY);
@@ -258,7 +255,6 @@ ADS_STATUS ads_idmap_cached_connection(const char *dom_name,
                ldap_server,            /* DNS name to connect to. */
                password,               /* password for auth realm. */
                realm,                  /* realm used for krb5 ticket. */
-               0,                      /* renewable ticket time. */
                mem_ctx,                /* memory context for ads struct */
                adsp);                  /* Returns ads struct. */
 
@@ -336,7 +332,6 @@ static ADS_STATUS ads_cached_connection(struct winbindd_domain *domain,
                                        domain->name, NULL,
                                        password,
                                        realm,
-                                       WINBINDD_PAM_AUTH_KRB5_RENEW_TIME,
                                        domain,
                                        &domain->backend_data.ads_conn);
        if (!ADS_ERR_OK(status)) {