Forked from
DM / dm-docs
261 commits behind, 167 commits ahead of the upstream repository.
-
sveseli authored
add first functional DS web service with user, experiment and auth controllers that allow retrieving user and experiment information from the db, start/stop experiment, and principal authorization; added corresponding API and CLI classes; added storage manager skeleton
sveseli authoredadd first functional DS web service with user, experiment and auth controllers that allow retrieving user and experiment information from the db, start/stop experiment, and principal authorization; added corresponding API and CLI classes; added storage manager skeleton
Code owners
Assign users and groups as approvers for specific file changes. Learn more.
authRouteDescriptor.py 833 B
#!/usr/bin/env python
#
# Auth route descriptor.
#
from dm.common.utility.configurationManager import ConfigurationManager
from authSessionController import AuthSessionController
class AuthRouteDescriptor:
@classmethod
def getRoutes(cls):
contextRoot = ConfigurationManager.getInstance().getContextRoot()
authSessionController = AuthSessionController()
routes = [
# Get authorization principal
{
'name' : 'getAuthorizationPrincipal',
'path' : '%s/authorizationPrincipals/:(username)' % contextRoot,
'controller' : authSessionController,
'action' : 'getAuthorizationPrincipal',
'method' : [ 'GET' ]
},
]
return routes