module Praetorian

Defined in:

praetorian.cr
praetorian/policy.cr
praetorian/version.cr

Constant Summary

VERSION = "0.3.1"

Macro Summary

Macro Detail

macro authorise(user, object, query, policy_class) #

Same as .authorize


[View source]
macro authorise(user, object, query) #

[View source]
macro authorize(user, object, query, policy_class) #

Retrieves the policy for the given object, initializing it with the object and user and finally throwing an error if the user is not authorized to perform the given action.


[View source]
macro authorize(user, object, query) #

[View source]
macro check_auth(query, object, policy) #

Performs actual policy query check


[View source]