You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@nifi.apache.org by GitBox <gi...@apache.org> on 2020/03/04 14:40:19 UTC

[GitHub] [nifi] mcgilman commented on a change in pull request #4099: NIFI-7170: Add option to disable anonymous authentication

mcgilman commented on a change in pull request #4099: NIFI-7170: Add option to disable anonymous authentication
URL: https://github.com/apache/nifi/pull/4099#discussion_r387708612
 
 

 ##########
 File path: nifi-commons/nifi-properties/src/main/java/org/apache/nifi/util/NiFiProperties.java
 ##########
 @@ -904,10 +905,19 @@ public boolean isLoginIdentityProviderEnabled() {
         return !StringUtils.isBlank(getProperty(NiFiProperties.SECURITY_USER_LOGIN_IDENTITY_PROVIDER));
     }
 
+    /**
+     * @return True if property value is 'true'; False otherwise.
+     */
+    public Boolean isAnonymousAuthenticationAllowed() {
+        final String anonymousAuthenticationAllowed = getProperty(SECURITY_ANONYMOUS_AUTHENTICATION, "false");
+
+        return "true".equalsIgnoreCase(anonymousAuthenticationAllowed);
 
 Review comment:
   I think this is a good idea. However [1] is already filed to address this. Do you want me to update how we treat this property specifically for this PR even if we provide a more general solution later?
   
   [1] https://issues.apache.org/jira/browse/NIFI-7172

----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
users@infra.apache.org


With regards,
Apache Git Services