@@ -470,7 +470,7 @@ class LDAPAuthenticator(InternalAuthenticator):
470470
471471 model_config = ConfigDict (use_attribute_docstrings = True )
472472
473- server_address_list : Annotated [list [str ], OneOrMany ]
473+ server_address_list : Annotated [list [str ], OneOrMany , Field ( alias = "server_address" ) ]
474474 server_port : Annotated [
475475 int ,
476476 Field (
@@ -485,18 +485,18 @@ class LDAPAuthenticator(InternalAuthenticator):
485485 receive_timeout : float = 60.0
486486 bind_dn_template : Annotated [list [str ], OneOrMany ] = []
487487 allowed_groups : list [str ] = []
488- lookup_dn : bool
489- user_search_base : str
490- user_attribute : str
488+ lookup_dn : bool = False
489+ user_search_base : Optional [ str ] = None
490+ user_attribute : Optional [ str ] = None
491491 lookup_dn_search_filter : Optional [str ] = "({login_attr}={login})"
492- lookup_dn_search_user : Optional [str ]
493- lookup_dn_search_password : Optional [str ]
494- lookup_dn_user_dn_attribute : Optional [str ]
495- escape_userdn : bool
496- search_filter : str
492+ lookup_dn_search_user : Optional [str ] = None
493+ lookup_dn_search_password : Optional [str ] = None
494+ lookup_dn_user_dn_attribute : Optional [str ] = None
495+ escape_userdn : bool = False
496+ search_filter : str = ""
497497 attributes : list [str ] = []
498498 auth_state_attributes : list [str ] = []
499- use_lookup_dn_username : bool
499+ use_lookup_dn_username : bool = True
500500
501501 async def resolve_username (self , username_supplied_by_user ):
502502 import ldap3
0 commit comments