Module Authorization
In: lib/in_controller.rb
lib/reader.rb
lib/in_model.rb
lib/helper.rb
lib/authorization.rb

Methods

Classes and Modules

Module Authorization::AuthorizationHelper
Module Authorization::AuthorizationInController
Module Authorization::AuthorizationInModel
Module Authorization::Reader
Class Authorization::Attribute
Class Authorization::AttributeAuthorizationError
Class Authorization::AuthorizationError
Class Authorization::AuthorizationRule
Class Authorization::AuthorizationUsageError
Class Authorization::Engine
Class Authorization::GuestUser
Class Authorization::NotAuthorized

Constants

AUTH_DSL_FILE = "#{RAILS_ROOT}/config/authorization_rules.rb"

Public Class methods

Controller-independent method for retrieving the current user. Needed for model security where the current controller is not available.

[Source]

    # File lib/authorization.rb, line 24
24:   def self.current_user
25:     $current_user || GuestUser.new
26:   end

Controller-independent method for setting the current user.

[Source]

    # File lib/authorization.rb, line 29
29:   def self.current_user=(user)
30:     $current_user = user
31:   end

[Validate]