10 Commits

Author SHA1 Message Date
Convly
c9ebae4c9f Fix authorization issues due to null subject registration
Signed-off-by: Convly <jean-sebastien.herbaux@epitech.eu>
2020-07-08 11:48:45 +02:00
Convly
9cce0145c5 Fix elemMatch op bug (typo)
Signed-off-by: Convly <jean-sebastien.herbaux@epitech.eu>
2020-07-08 11:48:44 +02:00
Convly
46f0c87b7d Handle $or operation on pm query, better parsing for the query
Signed-off-by: Convly <jean-sebastien.herbaux@epitech.eu>
2020-07-08 11:48:41 +02:00
Convly
20f80b2361 Better permissions-manager.sanitize behavior
Forbid empty arrays as fields for permissions (on ability creation)
Differentiate input from output sanitizing

Signed-off-by: Convly <jean-sebastien.herbaux@epitech.eu>
2020-07-08 11:48:38 +02:00
Convly
c11e6dfa88 Use AbilityBuilder instead of defineAbility, fix content-manager::create route
Signed-off-by: Convly <jean-sebastien.herbaux@epitech.eu>
2020-07-08 11:48:17 +02:00
Convly
ed6a68d9be Add category to conditions
Signed-off-by: Convly <jean-sebastien.herbaux@epitech.eu>
2020-07-08 11:09:45 +02:00
Convly
027848eaa7 Fix pr comments (add doc, simplify engine code, add async test condition)
Signed-off-by: Convly <jean-sebastien.herbaux@epitech.eu>
2020-07-08 11:05:51 +02:00
Convly
a0b4132217 Merge engine.findPermissionsForUser with service.findUserPermissions
Signed-off-by: Convly <jean-sebastien.herbaux@epitech.eu>
2020-07-08 11:05:51 +02:00
Convly
efe6323eb3 Add checkMany & rework evaluatePermission (permission-engine) 2020-07-08 11:05:50 +02:00
Convly
ef94229d81 Add Condition Provider & Permissions Engine 2020-07-08 11:05:49 +02:00