Github user mcgilman commented on a diff in the pull request:
https://github.com/apache/nifi/pull/628#discussion_r70422981
--- Diff:
nifi-api/src/main/java/org/apache/nifi/authorization/resource/Authorizable.java
---
@@ -67,7 +69,8 @@ default boolean isAuthorized(Authorizer authorizer,
RequestAction action, NiFiUs
* @return is authorized
*/
default AuthorizationResult checkAuthorization(Authorizer authorizer,
RequestAction action, NiFiUser user, Map<String, String> resourceContext) {
- // TODO - include user details context
+ final Map<String,String> userContext = new HashMap<>();
+ userContext.put(UserContextKeys.CLIENT_ADDRESS.name(),
user.getClientAddress());
--- End diff --
I think we have some instances where the client address is not set on the
user. We should probably not include the userContext in those cases.
---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at [email protected] or file a JIRA ticket
with INFRA.
---