providers/ldap: Remove search group (#10639)
* remove search_group Signed-off-by: Jens Langhammer <jens@goauthentik.io> * make api operations cleaerer Signed-off-by: Jens Langhammer <jens@goauthentik.io> * fix migration Signed-off-by: Jens Langhammer <jens@goauthentik.io> * actually use get Signed-off-by: Jens Langhammer <jens@goauthentik.io> * use correct api client for ldap Signed-off-by: Jens Langhammer <jens@goauthentik.io> * fix tests Signed-off-by: Jens Langhammer <jens@goauthentik.io> * fix migration Signed-off-by: Jens Langhammer <jens@goauthentik.io> * unrelated: fix migration warning Signed-off-by: Jens Langhammer <jens@goauthentik.io> * add docs Signed-off-by: Jens Langhammer <jens@goauthentik.io> * update docs Signed-off-by: Jens Langhammer <jens@goauthentik.io> * unrelated: fix styling issue in dark mode Signed-off-by: Jens Langhammer <jens@goauthentik.io> * unrelated-ish fix button order in wizard Signed-off-by: Jens Langhammer <jens@goauthentik.io> * unrelated: fix missing css import Signed-off-by: Jens Langhammer <jens@goauthentik.io> * Optimised images with calibre/image-actions * Update index.md Co-authored-by: Tana M Berry <tanamarieberry@yahoo.com> Signed-off-by: Jens L. <jens@beryju.org> * Update index.md Co-authored-by: Tana M Berry <tanamarieberry@yahoo.com> Signed-off-by: Jens L. <jens@beryju.org> * Apply suggestions from code review Co-authored-by: Tana M Berry <tanamarieberry@yahoo.com> Signed-off-by: Jens L. <jens@beryju.org> * update release notes based on new template Signed-off-by: Jens Langhammer <jens@goauthentik.io> --------- Signed-off-by: Jens Langhammer <jens@goauthentik.io> Signed-off-by: Jens L. <jens@beryju.org> Co-authored-by: authentik-automation[bot] <135050075+authentik-automation[bot]@users.noreply.github.com> Co-authored-by: Tana M Berry <tanamarieberry@yahoo.com>
This commit is contained in:
		@ -5,6 +5,7 @@ from time import sleep
 | 
			
		||||
 | 
			
		||||
from docker.client import DockerClient, from_env
 | 
			
		||||
from docker.models.containers import Container
 | 
			
		||||
from guardian.shortcuts import assign_perm
 | 
			
		||||
from ldap3 import ALL, ALL_ATTRIBUTES, ALL_OPERATIONAL_ATTRIBUTES, SUBTREE, Connection, Server
 | 
			
		||||
from ldap3.core.exceptions import LDAPInvalidCredentialsResult
 | 
			
		||||
 | 
			
		||||
@ -54,9 +55,9 @@ class TestProviderLDAP(SeleniumTestCase):
 | 
			
		||||
        ldap: LDAPProvider = LDAPProvider.objects.create(
 | 
			
		||||
            name=generate_id(),
 | 
			
		||||
            authorization_flow=Flow.objects.get(slug="default-authentication-flow"),
 | 
			
		||||
            search_group=self.user.ak_groups.first(),
 | 
			
		||||
            search_mode=APIAccessMode.CACHED,
 | 
			
		||||
        )
 | 
			
		||||
        assign_perm("search_full_directory", self.user, ldap)
 | 
			
		||||
        # we need to create an application to actually access the ldap
 | 
			
		||||
        Application.objects.create(name=generate_id(), slug=generate_id(), provider=ldap)
 | 
			
		||||
        outpost: Outpost = Outpost.objects.create(
 | 
			
		||||
 | 
			
		||||
		Reference in New Issue
	
	Block a user