Bug with custom role permissions validation
There are several issues related to the validation the occurs when creating custom roles
-
falsevalues can be stored in the database. This adds unneeded overhead since we are only concerned with enabled permissions. All other permissions are assumed to be disabled by default. - Roles with permissions that are disabled via feature flag are able to stored. There should be a validation error when attempting to create a role with disabled permissions.
- When unknown permissions are passed we get a generic JSON schema validation error (
must be a valid json schema). We should return a more helpful error response.