I need the extension to do the following:
- Try to authenticate the user using the LDAP backend, if the user is found proceed to authenticate the user using that, same as the default LDAP auth. (If user exists in the LDAP but not in the board an account is made using the values from the LDAP like email and what-not)
- If a user doesn't exist in the LDAP, meaning it's a regular user not staff (in my use case) and the LDAP authentication fails, try to authenticate the person using the DB next before throwing an auth error from LDAP. (This means I can keep registration open since the default LDAP auth method still registers users in the DB still, they just can't authenticate after making an account since the db check isn't in place)
- If they both fail, then throw an error, either invalid username or invalid password.