@Test
  public void dataReadClientCanGet() throws Exception {
    Properties props = getVMPropertiesWithPermission("dataRead");
    int locatorPort = locator.getPort();

    ClientVM client = csRule.startClientVM(2, clientVmConfiguration, props,
        cf -> cf.addPoolLocator("localhost", locatorPort));

    // Add some values for the client to get
    server.invoke(() -> {
      Cache cache = ClusterStartupRule.getCache();
      Region<String, String> region = cache.getRegion(regionName);
      region.put(singleKey, singleValue);
      region.put(mapKey1, mapValue1);
      region.put(mapKey2, mapValue2);
    });

    // Client can successfully get the data
    client.invoke(() -> {
      ClientCache cache = ClusterStartupRule.getClientCache();
      ClientRegionFactory<String, String> rf =
          cache.createClientRegionFactory(ClientRegionShortcut.PROXY);
      Region<String, String> region = rf.create(regionName);

      assertThat(region.get(initKey)).isEqualTo(initValue);
      assertThat(region.get(singleKey)).isEqualTo(singleValue);
      assertThat(region.getAll(keyValueMap.keySet())).containsAllEntriesOf(keyValueMap);
    });
  }
Tests for authorization from client to server for data puts and gets. For similar test in the
case of failover, see {@link ClientDataAuthorizationUsingLegacySecurityWithFailoverDUnitTest}.

@since GemFire 5.5
geode-core/src/upgradeTest/java/org/apache/geode/security/ClientDataAuthorizationUsingLegacySecurityDUnitTest.java