|
HI, how you doing?
Do you have a video tutorial about how to create some sort of global ACL object and then store that object in cache of in database in serialized form?
I am also looking for tutorial on how to create database schema for user groups and premissions and then based on those tables create ACL.
Basically I want to store group names in a table like USERGROUP
id auto_increment
group_name
group_description (just for comments and notes about groups, not used for logic)
Then a table with permissions
id auto_increment
permission
description (just for notes, not for login)
The 'permission' will be, for example, 'edit_profile', or 'read_blog_article' or 'change_password'
Then there is a usual USER table with
id
username
password,
firstname,
lastname.
and maybe some other things.
And the tricky thing to somehow to tie the permission_id with group_id and then load all this data into ACL object and then maybe store the ACL somewhere in cache.
Right now I don't have a very clear idea on how to do this.
To make things even more difficult I want to make it so a user can belong to more than one group and then use ACL inheritence to calculate the permission.
If you have any experience or have a good idea about how to implement it, please reply.
|