Commit 4ab08a0
committed
providers/ldap: avoid negative caching on flow errors
- direct: map flow/transport errors to LDAPResultOperationsError instead of InvalidCredentials.
- memory: cache only non-OperationsError results; guard against missing flags/session when deriving TTL.
This prevents transient backend/flow failures from being cached as invalid credentials
for a DN/password combination. Successful binds and genuine InvalidCredentials/access
outcomes continue to be cached as before, preserving intended behavior.
Signed-off-by: Christian Albrecht <christian.albrecht@mayflower.de>1 parent 7a23055 commit 4ab08a0
2 files changed
+7
-5
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
46 | 46 | | |
47 | 47 | | |
48 | 48 | | |
49 | | - | |
| 49 | + | |
50 | 50 | | |
51 | 51 | | |
52 | 52 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
54 | 54 | | |
55 | 55 | | |
56 | 56 | | |
57 | | - | |
58 | | - | |
| 57 | + | |
| 58 | + | |
| 59 | + | |
| 60 | + | |
59 | 61 | | |
60 | | - | |
61 | | - | |
| 62 | + | |
| 63 | + | |
62 | 64 | | |
63 | 65 | | |
64 | 66 | | |
| |||
0 commit comments