Dashboard > Bistro > ... > Reference Guide > SecurityController
SecurityController Log In   View a printable version of the current page.

Added by Alex Pedenko , last edited by Kirill Skrygan on May 04, 2009  (view change)
Labels: 
(None)

Overview

The SecurityController class is a default, deny-first implementation of the ISecurityController interface.

Usage

This class is used as a marker defining which bind points require what permissions for access. When bound to a specific bind point, all controllers matching that bind point will be subject to the requirements defined in the security controller.

Example

Given the following security definition

[Bind("/action/search")]
[Deny("?", OnFailure = FailAction.Redirect, Target = "/action/signin")]
public class SearchSecurity : SecurityController { }

these controllers would not be accessible by anonymous users

[Bind("/action/search/{contentType}/first-time")]
public class FirstTimeSearch : AbstractController
{
...
}

/// <summary>
/// Summary description for Search
/// </summary>
[Bind("/action/search/{contentType}")]
public class Search : AbstractController
{
...
}

Furthermore, attempts to access any of these two controllers while not being authenticated, would result in a FailAction of Redirect, and would redirect the user to the Target, or /action/signin

See also:

SecurityController in the Bistro Class Library.

Powered by a free Atlassian Confluence Open Source Project / Non-profit License granted to Workflow Server. Evaluate Confluence today.
Powered by Atlassian Confluence 2.7, the Enterprise Wiki. Bug/feature request - Atlassian news - Contact administrators