add custom permissions to Device and DatabaseUser
add authorization info to DatabaseRealm and make it object
convert List of permissions to set of permissions and fix tests
fix Permissions object compilation issue
make DatabaseRealm object
make DeviceRealm object
add new roles
userrealms should put userinfo as user principal and fix tests