Skip to content

ACL vs. (and) System pages

schnoog edited this page Dec 29, 2017 · 1 revision

ACL vs. System pages

XSS Protection

This Boilerplate contains two different kinds of access control.

System-Pages (sys pages)

System pages (login, profile, administration) using their own access control.

The roles needed to access the administration are defined within the main config.

ACL (group based)

The main principle of ACL is provided by the Auth library and the user groups defined within it. (Some of them my be disabled by config).

Each user is assigned to one or several groups. The value (Bitmask, 1^n-1) is than sumerized and a final number created.

Access control for pages

The access to each page can be defined based on user groups.

As long as the page is not marked as sys page and ACL is not deactivated, each access will be matched again the ACL rules.

Access control for ajax backends

Each ajax call contains a token which makes the backend able to identify the requester and the user group mask.

The access control need to be added to each backend manually, by checking the allowed mask against the user group.

if ( USERMASK & ACCESSMASK ) --> everything is OK