开发者

Cross-product web authentication systems

开发者 https://www.devze.com 2022-12-12 20:29 出处:网络
I\'m about to start a human resources web app system. My idea is to have the manager system and the website work with the same database, but make three or more \"products\" running with the same data.

I'm about to start a human resources web app system. My idea is to have the manager system and the website work with the same database, but make three or more "products" running with the same data. All in PHP and JavaScript.

My question is how can I get an authentication system like Zoho or Google, with one account for all services, and how can i store this开发者_如何学编程. In a single table? LDAP? Which one?


If they're all on the same domain, then why treat them as one app? Either have a single auth table in your db or use a seperate db called by all three apps.

As for the actual auth system, there are many ways - the one you choose will depend upon your individual requirements.

If you plan on extending the apps provided, it might be worth looking at setting up an OpenID provider for your domain and/or allowing logins from other OpenID providers (like StackOverflow does).


I would look around for "PHP Authentication frameworks"

Login Sessions might be something to checkout.

I've rolled my own code for this in the past. Creating a schema for platform objects and defining permissions for what user/group can access what applications. Below is a simple schema for this type of thing.

Table Users
     UserID
     ...

Table Applications
     ApplicationID
     ...

Table Permissions
     PermissionID
     ...

Table UserApplications
     UserApplicationID
     UserID
     ApplicationID
     PermissionID
     ...
0

精彩评论

暂无评论...
验证码 换一张
取 消

关注公众号