Package dev.galasa.framework.api.common
Class PublicRoute
java.lang.Object
dev.galasa.framework.api.common.BaseRoute
dev.galasa.framework.api.common.PublicRoute
- All Implemented Interfaces:
IRoute
This is an abstract class that represents a route that is publicly accessible and does not require a JWT.
No RBAC limits can be assigned to public routes since requests will not contain an 'Authorization' header.
-
Field Summary
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionboolean
isActionPermitted
(BuiltInAction action, String loginId) Checks if the given action is permitted for the user that sent the given requestMethods inherited from class dev.galasa.framework.api.common.BaseRoute
checkJsonElementIsValidJSON, checkRequestHasContent, getPathRegex, getResponseBuilder, getResponseType, getSupportedQueryParameterNames, handleDeleteRequest, handleGetRequest, handlePostRequest, handlePutRequest, parseRequestBody, validateAcceptHeader
-
Constructor Details
-
PublicRoute
-
-
Method Details
-
isActionPermitted
public boolean isActionPermitted(BuiltInAction action, String loginId) throws InternalServletException Description copied from interface:IRoute
Checks if the given action is permitted for the user that sent the given request- Parameters:
action
- the action being performedloginId
- the login ID of the user sending a request to this route- Returns:
- true if the user is allowed to perform the given action, false otherwise
- Throws:
InternalServletException
- if there was an issue accessing the RBAC service
-