C# Class ScrewTurn.Wiki.AuthChecker

Utility class for checking permissions and authorizations.
All the methods in this class implement a security bypass for the admin user.
Afficher le fichier Open project: mono/ScrewTurnWiki Class Usage Examples

Private Properties

Свойство Type Description

Méthodes publiques

Méthode Description
CheckActionForDirectory ( IFilesStorageProviderV30 provider, string directory, string action, string currentUser, string groups ) : bool

Checks whether an action is allowed for a directory.

CheckActionForGlobals ( string action, string currentUser, string groups ) : bool

Checks whether an action is allowed for the global resources.

CheckActionForNamespace ( NamespaceInfo nspace, string action, string currentUser, string groups ) : bool

Checks whether an action is allowed for a namespace.

CheckActionForPage ( System.PageInfo page, string action, string currentUser, string groups ) : bool

Checks whether an action is allowed for a page.

Method Details

CheckActionForDirectory() public static méthode

Checks whether an action is allowed for a directory.
public static CheckActionForDirectory ( IFilesStorageProviderV30 provider, string directory, string action, string currentUser, string groups ) : bool
provider IFilesStorageProviderV30 The provider that manages the directory.
directory string The full path of the directory.
action string The action the user is attempting to perform.
currentUser string The current user.
groups string The groups the user is member of.
Résultat bool

CheckActionForGlobals() public static méthode

Checks whether an action is allowed for the global resources.
public static CheckActionForGlobals ( string action, string currentUser, string groups ) : bool
action string The action the user is attempting to perform.
currentUser string The current user.
groups string The groups the user is member of.
Résultat bool

CheckActionForNamespace() public static méthode

Checks whether an action is allowed for a namespace.
public static CheckActionForNamespace ( NamespaceInfo nspace, string action, string currentUser, string groups ) : bool
nspace NamespaceInfo The current namespace (null for the root).
action string The action the user is attempting to perform.
currentUser string The current user.
groups string The groups the user is member of.
Résultat bool

CheckActionForPage() public static méthode

Checks whether an action is allowed for a page.
public static CheckActionForPage ( System.PageInfo page, string action, string currentUser, string groups ) : bool
page System.PageInfo The current page.
action string The action the user is attempting to perform.
currentUser string The current user.
groups string The groups the user is member of.
Résultat bool