reloadAuthParams function can destroy configuration values
in our new Manager, we use a function to reload auth parameters, depending on the choice of auth/userDB/passwordDB/issuerDB backend.
The problem with this function is that we can loose some parameters. Here is the way to reproduce:
- Use LDAP in authentication, apply -> LDAP parameters node appear
- Fill one of LDAP parameters (for example managerDN), apply and save
- Now use Apache in authentication, apply -> LDAP parameters disappear (if not, remove LDAP from other backends)
- Save
- Try to reuse LDAP in authentication, apply -> LDAP parameters node appear
- Check managerDn value: it was not saved!
Indeed, as the node was loaded in Ajax, and then hidden, it is not saved, so we loose all previous configuration if we change the backend.