Package com.styra.opa.springboot.input
Interface OPAInputResourceCustomizer
- Functional Interface:
- This is a functional interface and can therefore be used as the assignment target for a lambda expression or method reference.
By defining a bean which implements this interface, clients could customize OPA
input.resource
.-
Method Summary
Modifier and TypeMethodDescriptioncustomize
(Authentication authentication, RequestAuthorizationContext requestAuthorizationContext, Map<String, Object> resource) Customizesresource
Map
.
-
Method Details
-
customize
Map<String,Object> customize(Authentication authentication, RequestAuthorizationContext requestAuthorizationContext, Map<String, Object> resource) Customizesresource
Map
.- Parameters:
resource
- contains:- "type": "endpoint"
(configurable via
opa.request.resource.type
property) - "id":
HttpServletRequest.getServletPath()
- "type": "endpoint"
(configurable via
- Returns:
- should at least contains these keys:
-