I have used ldap_auth successfully by implementing the following in models/db.py:
............................................................
from gluon.contrib.login_methods.ldap_auth import ldap_auth
...
db = DAL('mysql://mydb:mydb@localhost/password')
...
# --- end of web2py scaffolding ---
...
auth.settings.login_methods.append(ldap_auth(mode='ad', server='
dc1.mydomain.com',base_dn='ou=users,dc=mydomain,dc=com'))
auth.settings.login_methods.append(ldap_auth(mode='ad', server='
dc1.mydomain.com',base_dn='ou=operators,dc=mydomain,dc=com'))
...
db2 = DAL('oracle://myextradb/account@password', migrate=False)
............................................................
I found that I had to make extra database definitions after the append statements or I received a segmentation fault.
I suspect that you could add another append statement to add an additional domain controller but I haven't tested this.
Hopefully this helps you - Tom