| summaryrefslogtreecommitdiff | 
diff options
| author | nsensfel <SpamShield0@noot-noot.org> | 2018-12-13 18:37:07 +0100 | 
|---|---|---|
| committer | nsensfel <SpamShield0@noot-noot.org> | 2018-12-13 18:37:07 +0100 | 
| commit | 6e983617288abafcdcfd7fcf26fc246302a388f7 (patch) | |
| tree | 72658bf42400e808579a019d7dcd86d868442c93 /src/ataxia_security.erl | |
| parent | 730ac64b4f5a680a6f32c8a0bedccf500444fdc6 (diff) | |
...
Diffstat (limited to 'src/ataxia_security.erl')
| -rw-r--r-- | src/ataxia_security.erl | 12 | 
1 files changed, 11 insertions, 1 deletions
| diff --git a/src/ataxia_security.erl b/src/ataxia_security.erl index 6fbc7d1..97ed276 100644 --- a/src/ataxia_security.erl +++ b/src/ataxia_security.erl @@ -12,7 +12,8 @@  %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%  -export_type([user/0, permission/0]). --export([can_access/2, user_from_id/1]). +-export([can_access/2]). +-export([janitor/0, any/0, admin/0, user_from_id/1]).  %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%  %% LOCAL FUNCTIONS %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% @@ -24,6 +25,15 @@  -spec user_from_id (any()) -> user().  user_from_id (ID) -> {user, ID}. +-spec janitor () -> user(). +janitor () -> janitor. + +-spec any () -> user(). +any () -> any. + +-spec admin () -> user(). +admin () -> admin. +  -spec can_access (permission(), user()) -> boolean().  can_access (_, admin) -> true;  can_access (any, _) -> true; | 


