public boolean isAllowedGeodeMethod(Method method, Object target) {
    String methodName = method.getName();
    Set<Class> allowedGeodeClassesForMethod = allowedGeodeMethodsPerClass.get(methodName);

    if (allowedGeodeClassesForMethod == null) {
      return false;
    }

    for (Class<?> clazz : allowedGeodeClassesForMethod) {
      if (clazz.isAssignableFrom(target.getClass())) {
        try {
          authorizeRegionAccess(securityService, target);
          return true;
        } catch (NotAuthorizedException noAuthorizedException) {
          return false;
        }
      }
    }

    return false;
  }
Executes the verification logic to determine whether the {@code target} object instance belongs
to Geode and whether the {@code method} on the {@code target} object instance is considered
to be safe according to Geode security rules.
If the {@code target} object is an instance of {@link Region}, this methods also ensures that
the user has the {@code DATA:READ} permission granted for the target {@link Region}.
<p>

@param method the {@link Method} that should be verified.
@param target the {@link Object} on which the {@link Method} will be executed.
@return {@code true} if and only if the {@code target} object instance belongs to Geode and
        the {@code method} is considered safe to be executed on the {@code target} object
        instance according to the Geode security rules, {@code false} otherwise.
geode-core/src/main/java/org/apache/geode/cache/query/security/RestrictedMethodAuthorizer.java