kristofferahl/FluentSecurity — Issue #4: Do not continue with running the rest of the policies after the first policy fails
Author: viswaug
Created: 2011-10-18 17:31:50+00:00
State: open

Here are my requirements:

1) There pages to which only authenticated users have access to
2) Users signup on the site ans wait for approval by admin. So, users can be in the system in an unapproved state. These users should see the pending approval page when trying to access any page on the site
3) Approved users can also be deactivated & reactivated by the admin. Deactivated user should see the 'please contact admin for reactivation' page.

I have 3 policies. 1) to check for valid user 2) to check for approval status 3) to check for active status. I might want to redirect users to different pages when the access the site based on their status and the business requirements.

Since all policies are run all the time, the policy to check for the approval status also needs to have a check in place for users that are not valid. But that case should be handled by the valid user policy that should have executed before the approval status policy. This redundant check will cause some performance issues if we don't watch out for it.

I think that the policy execution pipeline should stop on first failure.

Thank You,
Vish