From: Nick Porter Date: Tue, 28 Jan 2025 10:35:16 +0000 (+0000) Subject: Use server side sort control when fetching profiles X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=8f1195d733f862378e0dd13e673d12fb7a5024fa;p=thirdparty%2Ffreeradius-server.git Use server side sort control when fetching profiles --- diff --git a/src/modules/rlm_ldap/profile.c b/src/modules/rlm_ldap/profile.c index eaf3a74c520..944718f8bd5 100644 --- a/src/modules/rlm_ldap/profile.c +++ b/src/modules/rlm_ldap/profile.c @@ -146,6 +146,7 @@ unlang_action_t rlm_ldap_map_profile(fr_ldap_result_code_t *ret, char const *dn, int scope, char const *filter, fr_ldap_map_exp_t const *expanded) { ldap_profile_ctx_t *profile_ctx; + LDAPControl *serverctrls[] = { inst->profile_sort_ctrl, NULL }; if (!dn || !*dn) return UNLANG_ACTION_CALCULATE_RESULT; @@ -166,5 +167,5 @@ unlang_action_t rlm_ldap_map_profile(fr_ldap_result_code_t *ret, return fr_ldap_trunk_search(profile_ctx, &profile_ctx->query, request, ttrunk, dn, scope, filter, - expanded->attrs, NULL, NULL); + expanded->attrs, serverctrls, NULL); }