cmdb icon indicating copy to clipboard operation
cmdb copied to clipboard

[Bug]: ldap:无法筛选出多级目录下的账号

Open taoyang987 opened this issue 10 months ago • 1 comments

Contact Details

[email protected]

This bug is related to UI or API?

API

What happened?

这是我ldap中的目录cn=ty,ou=ywz,ou=yfzx,dc=hzguode,dc=com 在网页ldap中,如果配置成cn={},ou=ywz,ou=yfzx,dc=hzguode,dc=com 那么账号是可以登录的, 但是,如果配置成cn={},dc=hzguode,dc=com,会提示账号不存在. 可是一般ldap都会配置会多层目录的

Version

newest

What browsers are you seeing the problem on?

No response

Relevant log output

No response

taoyang987 avatar Mar 26 '24 02:03 taoyang987

https://github.com/taoyang987/cmdb/blob/master/cmdb-api/api/lib/perm/authentication/ldap.py 我修改了下代码,已经可以验证账号了 但是邮箱属性死活带不过来. 这种登录方式就是绑定管理员账号,然后去ldap获取所有账号,跟登录账号比对,再去验证密码. ui界面上也要稍微修改下

taoyang987 avatar Mar 27 '24 05:03 taoyang987