Hi,
I am building an access control system and I am storing all user permissions and groups in SQL Server. My site has many different sections and each user may or may not have access to one of those sections and within that section I will have another layer of permissions, i.e. read access/write access etc..
As I will need to be checking the users rights in every single part of the site, I am thinking whats the best approach to achieve this. I do not want to end up creating a procedure in every single section. I would like to have a single place where i can call the access control code and verify retrieve the appropiate permissions and rights.
Should I be writting this procedure in the global.asax file and use session variables to store the permission for the user so I can call that from anywhere in the site?
Thanks for your thoughts
I am building an access control system and I am storing all user permissions and groups in SQL Server. My site has many different sections and each user may or may not have access to one of those sections and within that section I will have another layer of permissions, i.e. read access/write access etc..
As I will need to be checking the users rights in every single part of the site, I am thinking whats the best approach to achieve this. I do not want to end up creating a procedure in every single section. I would like to have a single place where i can call the access control code and verify retrieve the appropiate permissions and rights.
Should I be writting this procedure in the global.asax file and use session variables to store the permission for the user so I can call that from anywhere in the site?
Thanks for your thoughts