Claim based authentication from PHP to Windows?

让人想犯罪 __ 提交于 2019-12-25 03:38:20

问题


i work at a company where all my web-applications connect to the LDAP-Directories or the AD for Authentication and/or Authorisation purposes. Generally this works quite well. Nowadays though - especially due to the latest introdution to SP2010 - people are looking forward to single sign ons and don't wanna re-login.

So my Question:

Is there any way to make PHP Claim the Authentication from Windows? I mean sure SharePoint does it with WIF on IIS - maybe theres a way PHP is as awesome :P

My quick google didnt bring up any great results, so my hopes aren't up too high, but i figured asking you guys might be worth a shot. Thanks in advance - happy new year!


回答1:


There's no simple way to implement this in pure PHP. I've had the exact same task and done it, but the whole solution involves raw HTTP/1.1, NTLM and SMB (Windows share) over TCP/UDP/NetBIOS - at the least. Each of those alone is complicated enough and PHP hasn't got any extensions to help with them.

There is an "Apache way" though:

  • mod_auth_sspi (if you're running on Windows)
  • mod_auth_ntlm (I think this only works with Apache <= 1.3)
  • libapache2-authenntlm-perl (there are reports that this one causes the web server to hang after receiving a large number of requests)
  • mod_auth_kerb (haven't used this one, but NTLM is replaced by a Microsoft implementation of KerberosV5 and it's the most modern solution available; however, it requires additional server configuration)


来源:https://stackoverflow.com/questions/8709031/claim-based-authentication-from-php-to-windows

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!