From 8deac813646ba8e0456ac5ca063b3ff19e522407 Mon Sep 17 00:00:00 2001 From: Jens Langhammer Date: Fri, 20 Jan 2023 11:42:23 +0100 Subject: [PATCH] outposts/ldap: fix queries filtering objectClass with non-lowercase values closes #2756 Signed-off-by: Jens Langhammer --- internal/outpost/ldap/utils/utils.go | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/internal/outpost/ldap/utils/utils.go b/internal/outpost/ldap/utils/utils.go index 841c30302..4c1c4db66 100644 --- a/internal/outpost/ldap/utils/utils.go +++ b/internal/outpost/ldap/utils/utils.go @@ -95,7 +95,12 @@ func IncludeObjectClass(searchOC string, ocs map[string]bool) bool { return true } - return ocs[searchOC] + for key, value := range ocs { + if strings.EqualFold(key, searchOC) { + return value + } + } + return false } func GetContainerEntry(filterOC string, dn string, ou string) *ldap.Entry {