-
Notifications
You must be signed in to change notification settings - Fork 120
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
TIMEOUTs not working #264
Comments
Adding multiple However, the model backend requires that the user account has a valid password set. What makes you think the fallback the model backend is not working? |
As you can see I used multiple But if I use a non-existing I would expect that because of |
Can I have the logs please? It would be good to know where it's getting
stuck.
Those settings are passed to the underlying ldap library.
…On Wed, 20 Sep 2023 at 05:50, gumish ***@***.***> wrote:
As you can see I used multiple AUTHENTICATION_BACKENDS.
But if I use a non-existing LDAP_AUTH_URL address like ['ldaps://
nonsense.com'], then during login, *I only see a rotating spinner in the
browser, and nothing happens.*
I would expect that because of LDAP_AUTH_CONNECT_TIMEOUT = 2 after 2
seconds it switch to 'django.contrib.auth.backends.ModelBackend' and log
me in.
—
Reply to this email directly, view it on GitHub
<#264 (comment)>,
or unsubscribe
<https://github.com/notifications/unsubscribe-auth/AABEKCHVAQAWYWG4B7EDE2DX3JYHPANCNFSM6AAAAAA33HJAL4>
.
You are receiving this because you commented.Message ID:
***@***.***>
|
I am not sure if this will be useful: LDAP_AUTH_URL = ['ldaps://existing_server.com'] - existing running ldap server
>> successfully logged in LDAP_AUTH_URL changed to ['ldaps://nonsense.com'] - non-existing server
>> no response, browser is endlessly waiting for it |
I think you're going to have to delve into the I'm wondering if it's one of: |
Yes, I agree. I have noticed that you only pass setting variables to |
Placing ModelBackend first in AUTHENTICATION_BACKENDS allows me to login when my LDAP server is unreachable. If LDAPBackend comes first and the server is unreachable then Django hangs. |
Same issue here these parameters seems to be ignored
|
Currently the pool is initiated so that servers are retried indefinetely. This makes it hard to define concrete hard timeout for login operation. This change exposes ldap3's ServerPool active parameter as setting. That way it provides means to resolve situations as with etianen#264. https://ldap3.readthedocs.io/en/latest/server.html#server-pool
Hello, at first thank you for great package! I am a newbie in Django+LDAP but I have managed to run it in quite short time :)
But I have a question about the case if the LDAP server is not reachable, so it can't be connected.
LDAP_AUTH_URL = ['ldaps://nonsense.com']
Is there a fallback that it will stop trying to connect the server and authenticate you via User model data?
I thought that these settings could help but nothing happened:
I have also tried to add ModelBackend but also without success:
Also nothing about unreachable server appears in console (with logging settings from help):
The text was updated successfully, but these errors were encountered: