|
Cookbook /
RestrictActionsSummary: require admin privilege for most actions (if not defined otherwise).
Version: 1.5
Prerequisites: none
Status: stable
Maintainer: Sven
Categories: Security
Discussion: RestrictActions-Talk?
Questions answered by this recipe
DescriptionThis recipe prevents all actions that are not configured to be allowed. (Some are allowed by default.) How to Install1. Download restrict_actions_v1.5.phpΔ and save it in your cookbook directory. 2. Edit your local config file and set the permissions by adding lines like: SDVA($RequiredPermissionLevels, array(
'action1' => 'userlevel1',
'action2' => 'userlevel2',
...
'actionN' => 'userlevelN',
));
where the actions are the ?action= values you want to allow and the userlevels are either
"*" means do not add any extra protection, "-" means disable the action completely (even for users with admin privilege).
3. Below these permissions, write the usual include code: require_once "
where X.X is the version number. If you're using AuthUser, include that before you include restrict_actions. Security and Privacy ReminderBy default, Restirct Actions changes forbidden actions to browse. If you want to deny even reading protected pages, find the two occurences of CommentsSee Discussion at RestrictActions-Talk?. Releases
Reminders
See AlsoContributors
|