Simulate an LDAP Server?
For a number of reasons, I do not want to host an actual LDAP server.
Instead, through PHP, I want to simulate the essential functions of an LDAP server.
So I want, for instance, to be able to respond to ldap_search, ldap_connect, ldap_bind, ldap_unbind, etc.
Results would come from MySQL.
It looks like ldap_search would be a matter of returning the same response that an LDAP URL Query would return, which is like a JSON format, but I am unsure about e.g. ldap_bind.开发者_高级运维
Right now I am just researching the feasibility of providing a "simulated" LDAP Server. I would greatly appreciate any thoughts on how much this would require, using PHP/MySQL.
Thanks in advance!
I think you'll have to go through the protocol specifications and basically build a server implementation. It will give you an idea what you need to do, an LDAP client app will follow the protocol specs very closely.
Specs: https://www.rfc-editor.org/rfc/rfc4510
精彩评论