geode-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From u..@apache.org
Subject [geode] 01/01: GEODE-3604: Refactoring of Protocol to be less intrusive on the core.
Date Fri, 15 Sep 2017 19:00:33 GMT
This is an automated email from the ASF dual-hosted git repository.

udo pushed a commit to branch feature/GEODE-3604
in repository https://gitbox.apache.org/repos/asf/geode.git

commit d32a64100cbc8d25e9e4803998d4421f0e92d3fd
Author: kohlmu-pivotal <ukohlmeyer@pivotal.io>
AuthorDate: Fri Sep 8 15:48:07 2017 -0700

    GEODE-3604: Refactoring of Protocol to be less intrusive on the core.
---
 .../distributed/internal/tcpserver/TcpServer.java  | 17 ++--
 .../geode/internal/cache/CacheServerImpl.java      |  4 +-
 .../sockets/GenericProtocolServerConnection.java   | 46 ++++++-----
 .../tier/sockets/ServerConnectionFactory.java      | 93 ++++++----------------
 .../cache/tier/sockets/TcpServerFactory.java       | 14 +++-
 .../ClientProtocolMessageHandler.java              |  7 +-
 .../MessageExecutionContext.java                   | 39 +++++----
 .../ProtocolMessageHandlerLookupService.java}      | 24 +++---
 .../protocol}/security/server/Authenticator.java   | 16 ++--
 .../server/AuthenticatorLookupService.java         | 62 +++++++++++++++
 .../server/AuthorizationLookupService.java         | 60 ++++++++++++++
 .../protocol}/security/server/Authorizer.java      | 10 ++-
 .../security/server/NoOpAuthenticator.java         | 13 +--
 .../protocol}/security/server/NoOpAuthorizer.java  | 11 ++-
 .../protocol}/security/server/package.html         |  0
 ...internal.protocol.security.server.Authenticator |  1 +
 ...de.internal.protocol.security.server.Authorizer |  1 +
 .../org.apache.geode.security.server.Authenticator |  1 -
 .../tier/sockets/ServerConnectionFactoryTest.java  | 36 +++------
 .../exception/UnknownProtobufPrimitiveType.java    |  2 +-
 .../protocol/operations/OperationHandler.java      |  8 +-
 .../protocol/protobuf/EncodingTypeTranslator.java  |  3 +-
 .../geode/protocol/protobuf/OperationContext.java  |  4 +-
 ...essor.java => ProtobufOperationsProcessor.java} | 23 ++++--
 ...or.java => ProtobufProtocolMessageHandler.java} | 62 ++++++++++-----
 .../protobuf/ProtobufSimpleAuthenticator.java      | 79 ------------------
 .../operations/GetAllRequestOperationHandler.java  | 30 +++----
 .../GetAvailableServersOperationHandler.java       | 30 +++----
 .../GetRegionNamesRequestOperationHandler.java     |  6 +-
 .../GetRegionRequestOperationHandler.java          |  8 +-
 .../operations/GetRequestOperationHandler.java     |  8 +-
 .../operations/PutAllRequestOperationHandler.java  | 17 ++--
 .../operations/PutRequestOperationHandler.java     |  8 +-
 .../operations/RemoveRequestOperationHandler.java  |  8 +-
 .../server/ProtobufSimpleAuthenticator.java        | 75 +++++++++++++++++
 .../server}/ProtobufSimpleAuthorizer.java          | 18 ++---
 .../protobuf/utilities/ProtobufPrimitiveTypes.java |  6 +-
 .../protobuf/utilities/ProtobufUtilities.java      |  4 +-
 .../protocol/{protobuf => responses}/Failure.java  |  2 +-
 .../protocol/{protobuf => responses}/Result.java   |  2 +-
 .../protocol/{protobuf => responses}/Success.java  |  2 +-
 ...cache.tier.sockets.ClientProtocolMessageHandler |  1 -
 ....internal.protocol.ClientProtocolMessageHandler |  1 +
 ...internal.protocol.security.server.Authenticator |  1 +
 ...de.internal.protocol.security.server.Authorizer |  1 +
 .../org.apache.geode.security.server.Authenticator |  1 -
 .../GenericProtocolServerConnectionTest.java       | 13 ++-
 .../RoundTripCacheConnectionJUnitTest.java         | 28 +++----
 ...ava => ProtobufProtocolMessageHandlerTest.java} | 12 +--
 .../ProtobufSimpleAuthenticatorJUnitTest.java      | 41 ++++++----
 .../GetAllRequestOperationHandlerJUnitTest.java    | 24 +++---
 ...tAvailableServersOperationHandlerJUnitTest.java |  6 +-
 ...egionNamesRequestOperationHandlerJUnitTest.java | 22 ++---
 .../GetRegionRequestOperationHandlerJUnitTest.java | 50 +++++-------
 .../GetRequestOperationHandlerJUnitTest.java       | 60 +++++++-------
 .../PutAllRequestOperationHandlerJUnitTest.java    | 51 ++++++------
 .../PutRequestOperationHandlerJUnitTest.java       | 64 +++++++--------
 .../RemoveRequestOperationHandlerJUnitTest.java    | 61 +++++++-------
 .../utilities/ProtobufUtilitiesJUnitTest.java      | 15 ++--
 .../server}/AuthenticationIntegrationTest.java     | 45 ++++++-----
 .../server}/AuthorizationIntegrationTest.java      |  9 ++-
 61 files changed, 734 insertions(+), 632 deletions(-)

diff --git a/geode-core/src/main/java/org/apache/geode/distributed/internal/tcpserver/TcpServer.java b/geode-core/src/main/java/org/apache/geode/distributed/internal/tcpserver/TcpServer.java
index a721589..bbf8be8 100755
--- a/geode-core/src/main/java/org/apache/geode/distributed/internal/tcpserver/TcpServer.java
+++ b/geode-core/src/main/java/org/apache/geode/distributed/internal/tcpserver/TcpServer.java
@@ -58,9 +58,9 @@ import org.apache.geode.internal.VersionedDataInputStream;
 import org.apache.geode.internal.VersionedDataOutputStream;
 import org.apache.geode.internal.cache.InternalCache;
 import org.apache.geode.internal.cache.tier.CommunicationMode;
-import org.apache.geode.internal.cache.tier.sockets.ClientProtocolMessageHandler;
+import org.apache.geode.internal.protocol.ClientProtocolMessageHandler;
 import org.apache.geode.internal.cache.tier.sockets.HandShake;
-import org.apache.geode.internal.cache.tier.sockets.MessageExecutionContext;
+import org.apache.geode.internal.protocol.MessageExecutionContext;
 import org.apache.geode.internal.logging.LogService;
 import org.apache.geode.internal.net.SocketCreator;
 import org.apache.geode.internal.net.SocketCreatorFactory;
@@ -97,12 +97,7 @@ public class TcpServer {
   // GossipServer.
   public final static int OLDGOSSIPVERSION = 1001;
 
-  private static/* GemStoneAddition */ final Map GOSSIP_TO_GEMFIRE_VERSION_MAP = new HashMap();
-
-  /**
-   * For the new client-server protocol, which ignores the usual handshake mechanism.
-   */
-  public static final byte PROTOBUF_CLIENT_SERVER_PROTOCOL = (byte) 110;
+  private static final Map GOSSIP_TO_GEMFIRE_VERSION_MAP = new HashMap();
 
   // For test purpose only
   public static boolean isTesting = false;
@@ -117,7 +112,7 @@ public class TcpServer {
 
   private static final Logger log = LogService.getLogger();
 
-  protected/* GemStoneAddition */ final/* GemStoneAddition */ static int READ_TIMEOUT =
+  protected final static int READ_TIMEOUT =
       Integer.getInteger(DistributionConfig.GEMFIRE_PREFIX + "TcpServer.READ_TIMEOUT", 60 * 1000);
   // This is for backwards compatibility. The p2p.backlog flag used to be the only way to configure
   // the locator backlog.
@@ -372,8 +367,8 @@ public class TcpServer {
 
         short versionOrdinal;
         if (gossipVersion == NON_GOSSIP_REQUEST_VERSION) {
-          if (input.readUnsignedByte() == PROTOBUF_CLIENT_SERVER_PROTOCOL
-              && Boolean.getBoolean("geode.feature-protobuf-protocol")) {
+          if (input.readUnsignedByte() == CommunicationMode.ProtobufClientServerProtocol
+              .getModeNumber() && Boolean.getBoolean("geode.feature-protobuf-protocol")) {
             messageHandler.receiveMessage(input, socket.getOutputStream(),
                 new MessageExecutionContext(internalLocator));
           } else {
diff --git a/geode-core/src/main/java/org/apache/geode/internal/cache/CacheServerImpl.java b/geode-core/src/main/java/org/apache/geode/internal/cache/CacheServerImpl.java
index bcd8b32..b5327a8 100644
--- a/geode-core/src/main/java/org/apache/geode/internal/cache/CacheServerImpl.java
+++ b/geode-core/src/main/java/org/apache/geode/internal/cache/CacheServerImpl.java
@@ -27,6 +27,7 @@ import java.util.List;
 import java.util.Set;
 import java.util.concurrent.atomic.AtomicInteger;
 
+import org.apache.geode.internal.cache.tier.sockets.GenericProtocolServerConnection;
 import org.apache.geode.internal.cache.tier.sockets.ServerConnectionFactory;
 import org.apache.logging.log4j.Logger;
 
@@ -37,7 +38,6 @@ import org.apache.geode.InvalidValueException;
 import org.apache.geode.cache.AttributesFactory;
 import org.apache.geode.cache.ClientSession;
 import org.apache.geode.cache.DataPolicy;
-import org.apache.geode.cache.DiskStore;
 import org.apache.geode.cache.DiskStoreFactory;
 import org.apache.geode.cache.DynamicRegionFactory;
 import org.apache.geode.cache.EvictionAction;
@@ -95,7 +95,7 @@ public class CacheServerImpl extends AbstractCacheServer implements Distribution
   /**
    * The server connection factory, that provides either a
    * {@link org.apache.geode.internal.cache.tier.sockets.LegacyServerConnection} or a new
-   * {@link org.apache.geode.internal.cache.tier.sockets.GenericProtocolServerConnection}
+   * {@link GenericProtocolServerConnection}
    */
   private final ServerConnectionFactory serverConnectionFactory = new ServerConnectionFactory();
 
diff --git a/geode-core/src/main/java/org/apache/geode/internal/cache/tier/sockets/GenericProtocolServerConnection.java b/geode-core/src/main/java/org/apache/geode/internal/cache/tier/sockets/GenericProtocolServerConnection.java
index 6c81028..6d9d361 100644
--- a/geode-core/src/main/java/org/apache/geode/internal/cache/tier/sockets/GenericProtocolServerConnection.java
+++ b/geode-core/src/main/java/org/apache/geode/internal/cache/tier/sockets/GenericProtocolServerConnection.java
@@ -15,19 +15,22 @@
 
 package org.apache.geode.internal.cache.tier.sockets;
 
-import org.apache.geode.internal.cache.InternalCache;
-import org.apache.geode.internal.cache.tier.Acceptor;
-import org.apache.geode.internal.cache.tier.CachedRegionHelper;
-import org.apache.geode.internal.security.SecurityService;
-import org.apache.geode.security.SecurityManager;
-import org.apache.geode.security.server.Authenticator;
-
 import java.io.EOFException;
 import java.io.IOException;
 import java.io.InputStream;
 import java.io.OutputStream;
 import java.net.Socket;
 
+import org.apache.geode.internal.cache.InternalCache;
+import org.apache.geode.internal.cache.tier.Acceptor;
+import org.apache.geode.internal.cache.tier.CachedRegionHelper;
+import org.apache.geode.internal.protocol.ClientProtocolMessageHandler;
+import org.apache.geode.internal.protocol.MessageExecutionContext;
+import org.apache.geode.internal.protocol.security.server.Authenticator;
+import org.apache.geode.internal.security.SecurityService;
+import org.apache.geode.security.AuthenticationFailedException;
+import org.apache.geode.security.SecurityManager;
+
 /**
  * Holds the socket and protocol handler for the new client protocol.
  */
@@ -41,14 +44,15 @@ public class GenericProtocolServerConnection extends ServerConnection {
    * Creates a new <code>GenericProtocolServerConnection</code> that processes messages received
    * from an edge client over a given <code>Socket</code>.
    */
-  public GenericProtocolServerConnection(Socket s, InternalCache c, CachedRegionHelper helper,
-      CacheServerStats stats, int hsTimeout, int socketBufferSize, String communicationModeStr,
-      byte communicationMode, Acceptor acceptor, ClientProtocolMessageHandler newClientProtocol,
-      SecurityService securityService, Authenticator authenticator) {
-    super(s, c, helper, stats, hsTimeout, socketBufferSize, communicationModeStr, communicationMode,
-        acceptor, securityService);
+  GenericProtocolServerConnection(Socket socket, InternalCache cache,
+      CachedRegionHelper cachedRegionHelper, CacheServerStats cacheServerStats, int hsTimeout,
+      int socketBufferSize, String communicationModeStr, byte communicationMode, Acceptor acceptor,
+      SecurityService securityService, ClientProtocolMessageHandler clientProtocolMessageHandler,
+      Authenticator authenticator) {
+    super(socket, cache, cachedRegionHelper, cacheServerStats, hsTimeout, socketBufferSize,
+        communicationModeStr, communicationMode, acceptor, securityService);
     securityManager = securityService.getSecurityManager();
-    this.messageHandler = newClientProtocol;
+    this.messageHandler = clientProtocolMessageHandler;
     this.authenticator = authenticator;
   }
 
@@ -59,12 +63,14 @@ public class GenericProtocolServerConnection extends ServerConnection {
       InputStream inputStream = socket.getInputStream();
       OutputStream outputStream = socket.getOutputStream();
 
-      if (!authenticator.isAuthenticated()) {
-        authenticator.authenticate(inputStream, outputStream, securityManager);
-      } else {
-        messageHandler.receiveMessage(inputStream, outputStream,
-            new MessageExecutionContext(this.getCache(), authenticator.getAuthorizer()));
-      }
+      Object authenticationToken =
+          authenticator.authenticate(inputStream, outputStream, securityManager);
+      messageHandler.receiveMessage(inputStream, outputStream,
+          new MessageExecutionContext(this.getCache(), authenticationToken, securityManager));
+    } catch (AuthenticationFailedException e) {
+      logger.warn(e);
+      this.setFlagProcessMessagesAsFalse();
+      setClientDisconnectedException(e);
     } catch (EOFException e) {
       this.setFlagProcessMessagesAsFalse();
       setClientDisconnectedException(e);
diff --git a/geode-core/src/main/java/org/apache/geode/internal/cache/tier/sockets/ServerConnectionFactory.java b/geode-core/src/main/java/org/apache/geode/internal/cache/tier/sockets/ServerConnectionFactory.java
index f0348c3..3058c81 100644
--- a/geode-core/src/main/java/org/apache/geode/internal/cache/tier/sockets/ServerConnectionFactory.java
+++ b/geode-core/src/main/java/org/apache/geode/internal/cache/tier/sockets/ServerConnectionFactory.java
@@ -17,92 +17,49 @@ package org.apache.geode.internal.cache.tier.sockets;
 
 import static org.apache.geode.internal.cache.tier.CommunicationMode.ProtobufClientServerProtocol;
 
+import java.io.IOException;
+import java.net.Socket;
+
 import org.apache.geode.internal.cache.InternalCache;
 import org.apache.geode.internal.cache.tier.Acceptor;
 import org.apache.geode.internal.cache.tier.CachedRegionHelper;
+import org.apache.geode.internal.protocol.ClientProtocolMessageHandler;
+import org.apache.geode.internal.protocol.ProtocolMessageHandlerLookupService;
+import org.apache.geode.internal.protocol.security.server.AuthenticatorLookupService;
 import org.apache.geode.internal.security.SecurityService;
-import org.apache.geode.security.server.Authenticator;
-
-import java.io.IOException;
-import java.net.Socket;
-import java.util.HashMap;
-import java.util.Map;
-import java.util.ServiceLoader;
 
 /**
  * Creates instances of ServerConnection based on the connection mode provided.
  */
 public class ServerConnectionFactory {
-  private ClientProtocolMessageHandler protocolHandler;
-  private Map<String, Class<? extends Authenticator>> authenticators = null;
+  private final ProtocolMessageHandlerLookupService protocolMessageHandlerLookupService;
+  private final AuthenticatorLookupService authenticatorLookupService;
 
-  public ServerConnectionFactory() {}
+  public ServerConnectionFactory() {
+    protocolMessageHandlerLookupService = new ProtocolMessageHandlerLookupService();
+    authenticatorLookupService = new AuthenticatorLookupService();
 
-  private synchronized void initializeAuthenticatorsMap() {
-    if (authenticators != null) {
-      return;
-    }
-    authenticators = new HashMap<>();
-    ServiceLoader<Authenticator> loader = ServiceLoader.load(Authenticator.class);
-    for (Authenticator streamAuthenticator : loader) {
-      authenticators.put(streamAuthenticator.implementationID(), streamAuthenticator.getClass());
-    }
   }
 
-  private synchronized ClientProtocolMessageHandler initializeMessageHandler() {
-    if (protocolHandler != null) {
-      return protocolHandler;
-    }
-
-    protocolHandler = new MessageHandlerFactory().makeMessageHandler();
-
-    return protocolHandler;
-  }
-
-  private Authenticator findStreamAuthenticator(String implementationID) {
-    if (authenticators == null) {
-      initializeAuthenticatorsMap();
-    }
-    Class<? extends Authenticator> streamAuthenticatorClass = authenticators.get(implementationID);
-    if (streamAuthenticatorClass == null) {
-      throw new ServiceLoadingFailureException(
-          "Could not find implementation for Authenticator with implementation ID "
-              + implementationID);
-    } else {
-      try {
-        return streamAuthenticatorClass.newInstance();
-      } catch (InstantiationException | IllegalAccessException e) {
-        throw new ServiceLoadingFailureException(
-            "Unable to instantiate authenticator for ID " + implementationID, e);
-      }
-    }
-  }
-
-  private ClientProtocolMessageHandler getClientProtocolMessageHandler() {
-    if (protocolHandler == null) {
-      initializeMessageHandler();
-    }
-    return protocolHandler;
-  }
-
-  public ServerConnection makeServerConnection(Socket s, InternalCache c, CachedRegionHelper helper,
-      CacheServerStats stats, int hsTimeout, int socketBufferSize, String communicationModeStr,
-      byte communicationMode, Acceptor acceptor, SecurityService securityService)
-      throws IOException {
-    if (communicationMode == ProtobufClientServerProtocol.getModeNumber()) {
+  public ServerConnection makeServerConnection(Socket socket, InternalCache cache,
+      CachedRegionHelper cachedRegionHelper, CacheServerStats cacheServerStats, int hsTimeout,
+      int socketBufferSize, String communicationModeStr, byte communicationMode, Acceptor acceptor,
+      SecurityService securityService) throws IOException {
+    if (ProtobufClientServerProtocol.getModeNumber() == communicationMode) {
       if (!Boolean.getBoolean("geode.feature-protobuf-protocol")) {
         throw new IOException("Server received unknown communication mode: " + communicationMode);
       } else {
-        String authenticationMode =
-            System.getProperty("geode.protocol-authentication-mode", "NOOP");
-
-        return new GenericProtocolServerConnection(s, c, helper, stats, hsTimeout, socketBufferSize,
-            communicationModeStr, communicationMode, acceptor, getClientProtocolMessageHandler(),
-            securityService, findStreamAuthenticator(authenticationMode));
+        ClientProtocolMessageHandler clientProtocolMessageHandler =
+            protocolMessageHandlerLookupService.lookupProtocolHandler("PROTOBUF");
+        return new GenericProtocolServerConnection(socket, cache, cachedRegionHelper,
+            cacheServerStats, hsTimeout, socketBufferSize, communicationModeStr, communicationMode,
+            acceptor, securityService, clientProtocolMessageHandler,
+            authenticatorLookupService.getAuthenticator());
       }
     } else {
-      return new LegacyServerConnection(s, c, helper, stats, hsTimeout, socketBufferSize,
-          communicationModeStr, communicationMode, acceptor, securityService);
+      return new LegacyServerConnection(socket, cache, cachedRegionHelper, cacheServerStats,
+          hsTimeout, socketBufferSize, communicationModeStr, communicationMode, acceptor,
+          securityService);
     }
   }
 }
diff --git a/geode-core/src/main/java/org/apache/geode/internal/cache/tier/sockets/TcpServerFactory.java b/geode-core/src/main/java/org/apache/geode/internal/cache/tier/sockets/TcpServerFactory.java
index 959e6e2..15dff3b 100644
--- a/geode-core/src/main/java/org/apache/geode/internal/cache/tier/sockets/TcpServerFactory.java
+++ b/geode-core/src/main/java/org/apache/geode/internal/cache/tier/sockets/TcpServerFactory.java
@@ -16,7 +16,9 @@
 package org.apache.geode.internal.cache.tier.sockets;
 
 import java.net.InetAddress;
+import java.util.Iterator;
 import java.util.Properties;
+import java.util.ServiceLoader;
 
 import org.apache.logging.log4j.Logger;
 
@@ -26,6 +28,7 @@ import org.apache.geode.distributed.internal.PoolStatHelper;
 import org.apache.geode.distributed.internal.tcpserver.TcpHandler;
 import org.apache.geode.distributed.internal.tcpserver.TcpServer;
 import org.apache.geode.internal.logging.LogService;
+import org.apache.geode.internal.protocol.ClientProtocolMessageHandler;
 
 public class TcpServerFactory {
   private ClientProtocolMessageHandler protocolHandler;
@@ -33,7 +36,16 @@ public class TcpServerFactory {
 
   public TcpServerFactory() {
     try {
-      protocolHandler = new MessageHandlerFactory().makeMessageHandler();
+      ServiceLoader<ClientProtocolMessageHandler> loader =
+          ServiceLoader.load(ClientProtocolMessageHandler.class);
+      Iterator<ClientProtocolMessageHandler> iterator = loader.iterator();
+
+      if (!iterator.hasNext()) {
+        throw new ServiceLoadingFailureException(
+            "There is no ClientProtocolMessageHandler implementation found in JVM");
+      }
+
+      protocolHandler = iterator.next();
     } catch (ServiceLoadingFailureException ex) {
       logger.warn(ex.getMessage());
     }
diff --git a/geode-core/src/main/java/org/apache/geode/internal/cache/tier/sockets/ClientProtocolMessageHandler.java b/geode-core/src/main/java/org/apache/geode/internal/protocol/ClientProtocolMessageHandler.java
similarity index 85%
rename from geode-core/src/main/java/org/apache/geode/internal/cache/tier/sockets/ClientProtocolMessageHandler.java
rename to geode-core/src/main/java/org/apache/geode/internal/protocol/ClientProtocolMessageHandler.java
index 0ced3aa..86bd563 100644
--- a/geode-core/src/main/java/org/apache/geode/internal/cache/tier/sockets/ClientProtocolMessageHandler.java
+++ b/geode-core/src/main/java/org/apache/geode/internal/protocol/ClientProtocolMessageHandler.java
@@ -13,12 +13,15 @@
  * the License.
  */
 
-package org.apache.geode.internal.cache.tier.sockets;
+package org.apache.geode.internal.protocol;
 
 import java.io.IOException;
 import java.io.InputStream;
 import java.io.OutputStream;
 
+import org.apache.geode.internal.cache.tier.sockets.GenericProtocolServerConnection;
+import org.apache.geode.internal.cache.tier.sockets.ServerConnectionFactory;
+
 
 /**
  * This is an interface that other modules can implement to hook into
@@ -31,4 +34,6 @@ import java.io.OutputStream;
 public interface ClientProtocolMessageHandler {
   void receiveMessage(InputStream inputStream, OutputStream outputStream,
       MessageExecutionContext executionContext) throws IOException;
+
+  String getMessageHandlerProtocolName();
 }
diff --git a/geode-core/src/main/java/org/apache/geode/internal/cache/tier/sockets/MessageExecutionContext.java b/geode-core/src/main/java/org/apache/geode/internal/protocol/MessageExecutionContext.java
similarity index 71%
rename from geode-core/src/main/java/org/apache/geode/internal/cache/tier/sockets/MessageExecutionContext.java
rename to geode-core/src/main/java/org/apache/geode/internal/protocol/MessageExecutionContext.java
index 1130ce7..c52419b 100644
--- a/geode-core/src/main/java/org/apache/geode/internal/cache/tier/sockets/MessageExecutionContext.java
+++ b/geode-core/src/main/java/org/apache/geode/internal/protocol/MessageExecutionContext.java
@@ -13,35 +13,37 @@
  * the License.
  */
 
-package org.apache.geode.internal.cache.tier.sockets;
+package org.apache.geode.internal.protocol;
 
 import org.apache.geode.annotations.Experimental;
 import org.apache.geode.cache.Cache;
 import org.apache.geode.distributed.Locator;
-import org.apache.geode.distributed.internal.InternalLocator;
 import org.apache.geode.internal.exception.InvalidExecutionContextException;
-import org.apache.geode.security.server.NoOpAuthorizer;
-import org.apache.geode.security.server.Authorizer;
+import org.apache.geode.security.SecurityManager;
 
 @Experimental
 public class MessageExecutionContext {
   private Cache cache;
   private Locator locator;
-  private Authorizer authorizer;
+  private final Object authenticationToken;
+  private final SecurityManager securityManager;
 
-  public MessageExecutionContext(Cache cache, Authorizer streamAuthorizer) {
+  public MessageExecutionContext(Cache cache, Object authenticationToken,
+      SecurityManager securityManager) {
     this.cache = cache;
-    this.authorizer = streamAuthorizer;
+    this.authenticationToken = authenticationToken;
+    this.securityManager = securityManager;
   }
 
-  public MessageExecutionContext(InternalLocator locator) {
+
+  public MessageExecutionContext(Locator locator) {
     this.locator = locator;
-    // set a no-op authorizer until such time as locators implement authentication
-    // and authorization checks
-    this.authorizer = new NoOpAuthorizer();
+    this.authenticationToken = null;
+    this.securityManager = null;
   }
 
   /**
+   * 
    * Returns the cache associated with this execution
    * <p>
    *
@@ -70,10 +72,19 @@ public class MessageExecutionContext {
   }
 
   /**
-   * Returns the Authorizer associated with this execution. This can be used to perform
+   * Returns the AuthenticatedTokenassociated with this execution. This can be used to perform
    * authorization checks for the user associated with this thread.
    */
-  public Authorizer getAuthorizer() {
-    return authorizer;
+  public Object getAuthenticationToken() {
+    return authenticationToken;
+  }
+
+  /**
+   * Returns the security manager.
+   * 
+   * @return
+   */
+  public SecurityManager getSecurityManager() {
+    return securityManager;
   }
 }
diff --git a/geode-core/src/main/java/org/apache/geode/internal/cache/tier/sockets/MessageHandlerFactory.java b/geode-core/src/main/java/org/apache/geode/internal/protocol/ProtocolMessageHandlerLookupService.java
similarity index 59%
rename from geode-core/src/main/java/org/apache/geode/internal/cache/tier/sockets/MessageHandlerFactory.java
rename to geode-core/src/main/java/org/apache/geode/internal/protocol/ProtocolMessageHandlerLookupService.java
index 2aca8c2..4196fd6 100644
--- a/geode-core/src/main/java/org/apache/geode/internal/cache/tier/sockets/MessageHandlerFactory.java
+++ b/geode-core/src/main/java/org/apache/geode/internal/protocol/ProtocolMessageHandlerLookupService.java
@@ -13,22 +13,26 @@
  * the License.
  */
 
-package org.apache.geode.internal.cache.tier.sockets;
+package org.apache.geode.internal.protocol;
 
-import java.util.Iterator;
+import java.util.HashMap;
+import java.util.Map;
 import java.util.ServiceLoader;
 
-public class MessageHandlerFactory {
-  public ClientProtocolMessageHandler makeMessageHandler() {
+public class ProtocolMessageHandlerLookupService {
+  private Map<String, ClientProtocolMessageHandler> protocolMessageHandlers = new HashMap<>();
+
+  public ProtocolMessageHandlerLookupService() {
     ServiceLoader<ClientProtocolMessageHandler> loader =
         ServiceLoader.load(ClientProtocolMessageHandler.class);
-    Iterator<ClientProtocolMessageHandler> iterator = loader.iterator();
-
-    if (!iterator.hasNext()) {
-      throw new ServiceLoadingFailureException(
-          "There is no ClientProtocolMessageHandler implementation found in JVM");
+    for (ClientProtocolMessageHandler clientProtocolMessageHandler : loader) {
+      protocolMessageHandlers.put(clientProtocolMessageHandler.getMessageHandlerProtocolName(),
+          clientProtocolMessageHandler);
     }
 
-    return iterator.next();
+  }
+
+  public ClientProtocolMessageHandler lookupProtocolHandler(String protocolType) {
+    return protocolMessageHandlers.get(protocolType);
   }
 }
diff --git a/geode-core/src/main/java/org/apache/geode/security/server/Authenticator.java b/geode-core/src/main/java/org/apache/geode/internal/protocol/security/server/Authenticator.java
similarity index 81%
rename from geode-core/src/main/java/org/apache/geode/security/server/Authenticator.java
rename to geode-core/src/main/java/org/apache/geode/internal/protocol/security/server/Authenticator.java
index 7893b4b..7d68aa0 100644
--- a/geode-core/src/main/java/org/apache/geode/security/server/Authenticator.java
+++ b/geode-core/src/main/java/org/apache/geode/internal/protocol/security/server/Authenticator.java
@@ -12,13 +12,13 @@
  * or implied. See the License for the specific language governing permissions and limitations under
  * the License.
  */
-package org.apache.geode.security.server;
+package org.apache.geode.internal.protocol.security.server;
 
 import java.io.IOException;
 import java.io.InputStream;
 import java.io.OutputStream;
 
-import org.apache.geode.security.AuthenticationRequiredException;
+import org.apache.geode.annotations.Experimental;
 import org.apache.geode.security.SecurityManager;
 
 /**
@@ -28,15 +28,17 @@ import org.apache.geode.security.SecurityManager;
  * If authentication fails, an implementor may continue to wait for another valid authentication
  * exchange.
  */
+@Experimental
 public interface Authenticator {
   /**
    *
    * @param inputStream to read auth messages from.
    * @param outputStream to send messages to.
    * @param securityManager can be used for validating credentials against.
+   * @return a authentication token that proves that the remote entity was authenticated
    * @throws IOException if EOF or if invalid input is received.
    */
-  void authenticate(InputStream inputStream, OutputStream outputStream,
+  Object authenticate(InputStream inputStream, OutputStream outputStream,
       SecurityManager securityManager) throws IOException;
 
   /**
@@ -47,13 +49,7 @@ public interface Authenticator {
   boolean isAuthenticated();
 
   /**
-   * Return an authorization object which can be used to determine which permissions this stream has
-   * according to the provided securityManager.
-   */
-  Authorizer getAuthorizer() throws AuthenticationRequiredException;
-
-  /**
    * @return a unique identifier for this particular implementation (NOOP, PASSTHROUGH, etc.)
    */
-  String implementationID();
+  String getImplementationID();
 }
diff --git a/geode-core/src/main/java/org/apache/geode/internal/protocol/security/server/AuthenticatorLookupService.java b/geode-core/src/main/java/org/apache/geode/internal/protocol/security/server/AuthenticatorLookupService.java
new file mode 100644
index 0000000..ccea628
--- /dev/null
+++ b/geode-core/src/main/java/org/apache/geode/internal/protocol/security/server/AuthenticatorLookupService.java
@@ -0,0 +1,62 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one or more contributor license
+ * agreements. See the NOTICE file distributed with this work for additional information regarding
+ * copyright ownership. The ASF licenses this file to You under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance with the License. You may obtain a
+ * copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software distributed under the License
+ * is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express
+ * or implied. See the License for the specific language governing permissions and limitations under
+ * the License.
+ */
+package org.apache.geode.internal.protocol.security.server;
+
+import java.util.HashMap;
+import java.util.Map;
+import java.util.ServiceLoader;
+
+import org.apache.geode.GemFireConfigException;
+import org.apache.geode.internal.cache.tier.sockets.ServiceLoadingFailureException;
+
+public class AuthenticatorLookupService {
+  private Map<String, Class<? extends Authenticator>> authenticators = null;
+
+  public AuthenticatorLookupService() {
+    if (authenticators == null) {
+      initializeAuthenticatorsMap();
+    }
+  }
+
+  private synchronized void initializeAuthenticatorsMap() {
+    if (authenticators != null) {
+      return;
+    }
+    authenticators = new HashMap<>();
+    ServiceLoader<Authenticator> loader = ServiceLoader.load(Authenticator.class);
+    for (Authenticator streamAuthenticator : loader) {
+      authenticators.put(streamAuthenticator.getImplementationID(), streamAuthenticator.getClass());
+    }
+  }
+
+  public Authenticator getAuthenticator() {
+    String authenticationMode = System.getProperty("geode.protocol-authentication-mode", "NOOP");
+
+    Class<? extends Authenticator> streamAuthenticatorClass =
+        authenticators.get(authenticationMode);
+    if (streamAuthenticatorClass == null) {
+      throw new GemFireConfigException(
+          "Could not find implementation for Authenticator with implementation ID "
+              + authenticationMode);
+    } else {
+      try {
+        return streamAuthenticatorClass.newInstance();
+      } catch (InstantiationException | IllegalAccessException e) {
+        throw new ServiceLoadingFailureException(
+            "Unable to instantiate authenticator for ID " + authenticationMode, e);
+      }
+    }
+  }
+}
diff --git a/geode-core/src/main/java/org/apache/geode/internal/protocol/security/server/AuthorizationLookupService.java b/geode-core/src/main/java/org/apache/geode/internal/protocol/security/server/AuthorizationLookupService.java
new file mode 100644
index 0000000..2002dc3
--- /dev/null
+++ b/geode-core/src/main/java/org/apache/geode/internal/protocol/security/server/AuthorizationLookupService.java
@@ -0,0 +1,60 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one or more contributor license
+ * agreements. See the NOTICE file distributed with this work for additional information regarding
+ * copyright ownership. The ASF licenses this file to You under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance with the License. You may obtain a
+ * copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software distributed under the License
+ * is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express
+ * or implied. See the License for the specific language governing permissions and limitations under
+ * the License.
+ */
+package org.apache.geode.internal.protocol.security.server;
+
+import java.util.HashMap;
+import java.util.Map;
+import java.util.ServiceLoader;
+
+import org.apache.geode.GemFireConfigException;
+import org.apache.geode.internal.cache.tier.sockets.ServiceLoadingFailureException;
+
+public class AuthorizationLookupService {
+  private Map<String, Class<? extends Authorizer>> authorizers = null;
+
+  public AuthorizationLookupService() {
+    if (authorizers == null) {
+      initializeAuthenticatorsMap();
+    }
+  }
+
+  private synchronized void initializeAuthenticatorsMap() {
+    if (authorizers != null) {
+      return;
+    }
+    authorizers = new HashMap<>();
+    ServiceLoader<Authorizer> loader = ServiceLoader.load(Authorizer.class);
+    for (Authorizer authorizer : loader) {
+      authorizers.put(authorizer.getImplementationID(), authorizer.getClass());
+    }
+  }
+
+  public Authorizer getAuthorizer() {
+    String authorizationMode = System.getProperty("geode.protocol-authentication-mode", "NOOP");
+
+    Class<? extends Authorizer> authorizationClass = authorizers.get(authorizationMode);
+    if (authorizationClass == null) {
+      throw new GemFireConfigException(
+          "Could not find implementation for Authorizer with ID " + authorizationMode);
+    } else {
+      try {
+        return authorizationClass.newInstance();
+      } catch (InstantiationException | IllegalAccessException e) {
+        throw new ServiceLoadingFailureException(
+            "Unable to instantiate authenticator for ID " + authorizationMode, e);
+      }
+    }
+  }
+}
diff --git a/geode-core/src/main/java/org/apache/geode/security/server/Authorizer.java b/geode-core/src/main/java/org/apache/geode/internal/protocol/security/server/Authorizer.java
similarity index 72%
rename from geode-core/src/main/java/org/apache/geode/security/server/Authorizer.java
rename to geode-core/src/main/java/org/apache/geode/internal/protocol/security/server/Authorizer.java
index fea2198..5d92208 100644
--- a/geode-core/src/main/java/org/apache/geode/security/server/Authorizer.java
+++ b/geode-core/src/main/java/org/apache/geode/internal/protocol/security/server/Authorizer.java
@@ -12,10 +12,16 @@
  * or implied. See the License for the specific language governing permissions and limitations under
  * the License.
  */
-package org.apache.geode.security.server;
+package org.apache.geode.internal.protocol.security.server;
 
+import org.apache.geode.annotations.Experimental;
 import org.apache.geode.security.ResourcePermission;
+import org.apache.geode.security.SecurityManager;
 
+@Experimental
 public interface Authorizer {
-  boolean authorize(ResourcePermission permissionRequested);
+  boolean authorize(Object authenticatedToken, ResourcePermission permissionRequested,
+      SecurityManager securityManager);
+
+  String getImplementationID();
 }
diff --git a/geode-core/src/main/java/org/apache/geode/security/server/NoOpAuthenticator.java b/geode-core/src/main/java/org/apache/geode/internal/protocol/security/server/NoOpAuthenticator.java
similarity index 79%
rename from geode-core/src/main/java/org/apache/geode/security/server/NoOpAuthenticator.java
rename to geode-core/src/main/java/org/apache/geode/internal/protocol/security/server/NoOpAuthenticator.java
index bf435d2..d68415f 100644
--- a/geode-core/src/main/java/org/apache/geode/security/server/NoOpAuthenticator.java
+++ b/geode-core/src/main/java/org/apache/geode/internal/protocol/security/server/NoOpAuthenticator.java
@@ -12,7 +12,7 @@
  * or implied. See the License for the specific language governing permissions and limitations under
  * the License.
  */
-package org.apache.geode.security.server;
+package org.apache.geode.internal.protocol.security.server;
 
 import java.io.IOException;
 import java.io.InputStream;
@@ -26,9 +26,9 @@ import org.apache.geode.security.SecurityManager;
  */
 public class NoOpAuthenticator implements Authenticator {
   @Override
-  public void authenticate(InputStream inputStream, OutputStream outputStream,
+  public Object authenticate(InputStream inputStream, OutputStream outputStream,
       SecurityManager securityManager) throws IOException {
-    // this method needs to do nothing as it is a pass-through implementation
+    return null;
   }
 
   @Override
@@ -37,12 +37,7 @@ public class NoOpAuthenticator implements Authenticator {
   }
 
   @Override
-  public Authorizer getAuthorizer() {
-    return new NoOpAuthorizer();
-  }
-
-  @Override
-  public String implementationID() {
+  public String getImplementationID() {
     return "NOOP";
   }
 }
diff --git a/geode-core/src/main/java/org/apache/geode/security/server/NoOpAuthorizer.java b/geode-core/src/main/java/org/apache/geode/internal/protocol/security/server/NoOpAuthorizer.java
similarity index 76%
rename from geode-core/src/main/java/org/apache/geode/security/server/NoOpAuthorizer.java
rename to geode-core/src/main/java/org/apache/geode/internal/protocol/security/server/NoOpAuthorizer.java
index 1491f04..d3cdab4 100644
--- a/geode-core/src/main/java/org/apache/geode/security/server/NoOpAuthorizer.java
+++ b/geode-core/src/main/java/org/apache/geode/internal/protocol/security/server/NoOpAuthorizer.java
@@ -12,16 +12,23 @@
  * or implied. See the License for the specific language governing permissions and limitations under
  * the License.
  */
-package org.apache.geode.security.server;
+package org.apache.geode.internal.protocol.security.server;
 
 import org.apache.geode.security.ResourcePermission;
+import org.apache.geode.security.SecurityManager;
 
 /**
  * An implementation of {@link Authorizer} that doesn't use its parameters and always returns true.
  */
 public class NoOpAuthorizer implements Authorizer {
   @Override
-  public boolean authorize(ResourcePermission permissionRequested) {
+  public boolean authorize(Object authenticatedToken, ResourcePermission permissionRequested,
+      SecurityManager securityManager) {
     return true;
   }
+
+  @Override
+  public String getImplementationID() {
+    return "NOOP";
+  }
 }
diff --git a/geode-core/src/main/java/org/apache/geode/security/server/package.html b/geode-core/src/main/java/org/apache/geode/internal/protocol/security/server/package.html
similarity index 100%
rename from geode-core/src/main/java/org/apache/geode/security/server/package.html
rename to geode-core/src/main/java/org/apache/geode/internal/protocol/security/server/package.html
diff --git a/geode-core/src/main/resources/META-INF/services/org.apache.geode.internal.protocol.security.server.Authenticator b/geode-core/src/main/resources/META-INF/services/org.apache.geode.internal.protocol.security.server.Authenticator
new file mode 100644
index 0000000..e115aae
--- /dev/null
+++ b/geode-core/src/main/resources/META-INF/services/org.apache.geode.internal.protocol.security.server.Authenticator
@@ -0,0 +1 @@
+org.apache.geode.internal.protocol.security.server.NoOpAuthenticator
\ No newline at end of file
diff --git a/geode-core/src/main/resources/META-INF/services/org.apache.geode.internal.protocol.security.server.Authorizer b/geode-core/src/main/resources/META-INF/services/org.apache.geode.internal.protocol.security.server.Authorizer
new file mode 100644
index 0000000..85fcb4a
--- /dev/null
+++ b/geode-core/src/main/resources/META-INF/services/org.apache.geode.internal.protocol.security.server.Authorizer
@@ -0,0 +1 @@
+org.apache.geode.internal.protocol.security.server.NoOpAuthorizer
\ No newline at end of file
diff --git a/geode-core/src/main/resources/META-INF/services/org.apache.geode.security.server.Authenticator b/geode-core/src/main/resources/META-INF/services/org.apache.geode.security.server.Authenticator
deleted file mode 100644
index 4f34d2a..0000000
--- a/geode-core/src/main/resources/META-INF/services/org.apache.geode.security.server.Authenticator
+++ /dev/null
@@ -1 +0,0 @@
-org.apache.geode.security.server.NoOpAuthenticator
diff --git a/geode-core/src/test/java/org/apache/geode/internal/cache/tier/sockets/ServerConnectionFactoryTest.java b/geode-core/src/test/java/org/apache/geode/internal/cache/tier/sockets/ServerConnectionFactoryTest.java
index 09c5949..568571d 100644
--- a/geode-core/src/test/java/org/apache/geode/internal/cache/tier/sockets/ServerConnectionFactoryTest.java
+++ b/geode-core/src/test/java/org/apache/geode/internal/cache/tier/sockets/ServerConnectionFactoryTest.java
@@ -15,23 +15,24 @@
 
 package org.apache.geode.internal.cache.tier.sockets;
 
-import org.apache.geode.internal.cache.InternalCache;
-import org.apache.geode.internal.cache.tier.CommunicationMode;
-import org.apache.geode.internal.cache.tier.CachedRegionHelper;
-import org.apache.geode.internal.security.SecurityService;
-import org.apache.geode.test.junit.categories.UnitTest;
-import org.junit.Rule;
-import org.junit.Test;
-import org.junit.contrib.java.lang.system.RestoreSystemProperties;
-import org.junit.experimental.categories.Category;
+import static org.junit.Assert.assertTrue;
+import static org.mockito.Mockito.mock;
+import static org.mockito.Mockito.when;
 
 import java.io.IOException;
 import java.net.InetAddress;
 import java.net.Socket;
 
-import static org.junit.Assert.assertTrue;
-import static org.mockito.Mockito.mock;
-import static org.mockito.Mockito.when;
+import org.junit.Rule;
+import org.junit.Test;
+import org.junit.contrib.java.lang.system.RestoreSystemProperties;
+import org.junit.experimental.categories.Category;
+
+import org.apache.geode.internal.cache.InternalCache;
+import org.apache.geode.internal.cache.tier.CachedRegionHelper;
+import org.apache.geode.internal.cache.tier.CommunicationMode;
+import org.apache.geode.internal.security.SecurityService;
+import org.apache.geode.test.junit.categories.UnitTest;
 
 /**
  * We don't test the path where the service providing protobufProtocolHandler is actually present,
@@ -58,17 +59,6 @@ public class ServerConnectionFactoryTest {
 
   }
 
-  /**
-   * @throws ServiceLoadingFailureException because the service is implemented in a different
-   *         module, and when this unit test is run, that module won't be present.
-   */
-  @Test(expected = ServiceLoadingFailureException.class)
-  public void newClientProtocolFailsWithSystemPropertySet() throws IOException {
-    System.setProperty("geode.feature-protobuf-protocol", "true");
-    ServerConnection serverConnection = serverConnectionMockedExceptForCommunicationMode(
-        CommunicationMode.ProtobufClientServerProtocol.getModeNumber());
-  }
-
   @Test
   public void makeServerConnection() throws Exception {
     CommunicationMode[] communicationModes = new CommunicationMode[] {
diff --git a/geode-protobuf/src/main/java/org/apache/geode/protocol/protobuf/utilities/exception/UnknownProtobufPrimitiveType.java b/geode-protobuf/src/main/java/org/apache/geode/protocol/exception/UnknownProtobufPrimitiveType.java
similarity index 93%
rename from geode-protobuf/src/main/java/org/apache/geode/protocol/protobuf/utilities/exception/UnknownProtobufPrimitiveType.java
rename to geode-protobuf/src/main/java/org/apache/geode/protocol/exception/UnknownProtobufPrimitiveType.java
index ca1dc72..eac9900 100644
--- a/geode-protobuf/src/main/java/org/apache/geode/protocol/protobuf/utilities/exception/UnknownProtobufPrimitiveType.java
+++ b/geode-protobuf/src/main/java/org/apache/geode/protocol/exception/UnknownProtobufPrimitiveType.java
@@ -12,7 +12,7 @@
  * or implied. See the License for the specific language governing permissions and limitations under
  * the License.
  */
-package org.apache.geode.protocol.protobuf.utilities.exception;
+package org.apache.geode.protocol.exception;
 
 import org.apache.geode.annotations.Experimental;
 
diff --git a/geode-protobuf/src/main/java/org/apache/geode/protocol/operations/OperationHandler.java b/geode-protobuf/src/main/java/org/apache/geode/protocol/operations/OperationHandler.java
index aca8ac2..b954039 100644
--- a/geode-protobuf/src/main/java/org/apache/geode/protocol/operations/OperationHandler.java
+++ b/geode-protobuf/src/main/java/org/apache/geode/protocol/operations/OperationHandler.java
@@ -15,17 +15,17 @@
 package org.apache.geode.protocol.operations;
 
 import org.apache.geode.annotations.Experimental;
-import org.apache.geode.internal.cache.tier.sockets.MessageExecutionContext;
 import org.apache.geode.internal.exception.InvalidExecutionContextException;
-import org.apache.geode.protocol.protobuf.ProtobufOpsProcessor;
-import org.apache.geode.protocol.protobuf.Result;
+import org.apache.geode.internal.protocol.MessageExecutionContext;
+import org.apache.geode.protocol.protobuf.ProtobufOperationsProcessor;
+import org.apache.geode.protocol.responses.Result;
 import org.apache.geode.serialization.SerializationService;
 
 /**
  * This interface is implemented by a object capable of handling request types 'Req' and returning
  * an a response of type 'Resp'
  *
- * See {@link ProtobufOpsProcessor}
+ * See {@link ProtobufOperationsProcessor}
  */
 @Experimental
 public interface OperationHandler<Req, Resp> {
diff --git a/geode-protobuf/src/main/java/org/apache/geode/protocol/protobuf/EncodingTypeTranslator.java b/geode-protobuf/src/main/java/org/apache/geode/protocol/protobuf/EncodingTypeTranslator.java
index ab2d118..afbb066 100644
--- a/geode-protobuf/src/main/java/org/apache/geode/protocol/protobuf/EncodingTypeTranslator.java
+++ b/geode-protobuf/src/main/java/org/apache/geode/protocol/protobuf/EncodingTypeTranslator.java
@@ -28,7 +28,8 @@ import org.apache.geode.serialization.exception.UnsupportedEncodingTypeException
  */
 @Experimental
 public abstract class EncodingTypeTranslator {
-  static final HashMap<Class, BasicTypes.EncodingType> typeToEncodingMap = intializeTypeMap();
+  private static final HashMap<Class, BasicTypes.EncodingType> typeToEncodingMap =
+      intializeTypeMap();
 
   private static HashMap<Class, BasicTypes.EncodingType> intializeTypeMap() {
     HashMap<Class, BasicTypes.EncodingType> result = new HashMap<>();
diff --git a/geode-protobuf/src/main/java/org/apache/geode/protocol/protobuf/OperationContext.java b/geode-protobuf/src/main/java/org/apache/geode/protocol/protobuf/OperationContext.java
index 1b04e54..6885342 100644
--- a/geode-protobuf/src/main/java/org/apache/geode/protocol/protobuf/OperationContext.java
+++ b/geode-protobuf/src/main/java/org/apache/geode/protocol/protobuf/OperationContext.java
@@ -37,11 +37,11 @@ public class OperationContext<OperationRequest, OperationResponse> {
     this.operationHandler = operationHandler;
     this.fromRequest = fromRequest;
     this.toResponse = toResponse;
-    this.toErrorResponse = OperationContext::makeErrorBuilder;
+    this.toErrorResponse = this::makeErrorBuilder;
     accessPermissionRequired = permissionRequired;
   }
 
-  public static ClientProtocol.Response.Builder makeErrorBuilder(
+  private ClientProtocol.Response.Builder makeErrorBuilder(
       ClientProtocol.ErrorResponse errorResponse) {
     return ClientProtocol.Response.newBuilder().setErrorResponse(errorResponse);
   }
diff --git a/geode-protobuf/src/main/java/org/apache/geode/protocol/protobuf/ProtobufOpsProcessor.java b/geode-protobuf/src/main/java/org/apache/geode/protocol/protobuf/ProtobufOperationsProcessor.java
similarity index 76%
rename from geode-protobuf/src/main/java/org/apache/geode/protocol/protobuf/ProtobufOpsProcessor.java
rename to geode-protobuf/src/main/java/org/apache/geode/protocol/protobuf/ProtobufOperationsProcessor.java
index 7dee26b..9cc072e 100644
--- a/geode-protobuf/src/main/java/org/apache/geode/protocol/protobuf/ProtobufOpsProcessor.java
+++ b/geode-protobuf/src/main/java/org/apache/geode/protocol/protobuf/ProtobufOperationsProcessor.java
@@ -15,11 +15,14 @@
 package org.apache.geode.protocol.protobuf;
 
 import org.apache.geode.annotations.Experimental;
-import org.apache.geode.internal.cache.tier.sockets.MessageExecutionContext;
 import org.apache.geode.internal.exception.InvalidExecutionContextException;
+import org.apache.geode.internal.protocol.MessageExecutionContext;
 import org.apache.geode.internal.protocol.protobuf.ClientProtocol;
+import org.apache.geode.internal.protocol.security.server.Authorizer;
 import org.apache.geode.protocol.protobuf.registry.OperationContextRegistry;
 import org.apache.geode.protocol.protobuf.utilities.ProtobufResponseUtilities;
+import org.apache.geode.protocol.responses.Failure;
+import org.apache.geode.protocol.responses.Result;
 import org.apache.geode.serialization.SerializationService;
 
 /**
@@ -27,25 +30,30 @@ import org.apache.geode.serialization.SerializationService;
  * it to the appropriate handler.
  */
 @Experimental
-public class ProtobufOpsProcessor {
+public class ProtobufOperationsProcessor {
 
   private final OperationContextRegistry operationContextRegistry;
   private final SerializationService serializationService;
+  private final Authorizer authorizer;
 
-  public ProtobufOpsProcessor(SerializationService serializationService,
-      OperationContextRegistry operationContextRegistry) {
+  ProtobufOperationsProcessor(SerializationService serializationService,
+      OperationContextRegistry operationContextRegistry, Authorizer autherizer) {
     this.serializationService = serializationService;
     this.operationContextRegistry = operationContextRegistry;
+    this.authorizer = autherizer;
   }
 
-  public ClientProtocol.Response process(ClientProtocol.Request request,
-      MessageExecutionContext context) {
+  public ClientProtocol.Response process(final ClientProtocol.Request request,
+      final MessageExecutionContext context) {
     ClientProtocol.Request.RequestAPICase requestType = request.getRequestAPICase();
     OperationContext operationContext = operationContextRegistry.getOperationContext(requestType);
     ClientProtocol.Response.Builder builder;
     Result result;
+
     try {
-      if (context.getAuthorizer().authorize(operationContext.getAccessPermissionRequired())) {
+      boolean authorized = authorizer.authorize(context.getAuthenticationToken(),
+          operationContext.getAccessPermissionRequired(), context.getSecurityManager());
+      if (authorized) {
         result = operationContext.getOperationHandler().process(serializationService,
             operationContext.getFromRequest().apply(request), context);
       } else {
@@ -63,4 +71,5 @@ public class ProtobufOpsProcessor {
         operationContext.getToErrorResponse());
     return builder.build();
   }
+
 }
diff --git a/geode-protobuf/src/main/java/org/apache/geode/protocol/protobuf/ProtobufStreamProcessor.java b/geode-protobuf/src/main/java/org/apache/geode/protocol/protobuf/ProtobufProtocolMessageHandler.java
similarity index 55%
rename from geode-protobuf/src/main/java/org/apache/geode/protocol/protobuf/ProtobufStreamProcessor.java
rename to geode-protobuf/src/main/java/org/apache/geode/protocol/protobuf/ProtobufProtocolMessageHandler.java
index f28c310..8607392 100644
--- a/geode-protobuf/src/main/java/org/apache/geode/protocol/protobuf/ProtobufStreamProcessor.java
+++ b/geode-protobuf/src/main/java/org/apache/geode/protocol/protobuf/ProtobufProtocolMessageHandler.java
@@ -20,10 +20,12 @@ import java.io.InputStream;
 import java.io.OutputStream;
 
 import org.apache.geode.annotations.Experimental;
-import org.apache.geode.internal.cache.tier.sockets.ClientProtocolMessageHandler;
-import org.apache.geode.internal.cache.tier.sockets.MessageExecutionContext;
-import org.apache.geode.protocol.exception.InvalidProtocolMessageException;
+import org.apache.geode.internal.protocol.ClientProtocolMessageHandler;
+import org.apache.geode.internal.protocol.MessageExecutionContext;
 import org.apache.geode.internal.protocol.protobuf.ClientProtocol;
+import org.apache.geode.internal.protocol.security.server.AuthorizationLookupService;
+import org.apache.geode.internal.protocol.security.server.Authorizer;
+import org.apache.geode.protocol.exception.InvalidProtocolMessageException;
 import org.apache.geode.protocol.protobuf.registry.OperationContextRegistry;
 import org.apache.geode.protocol.protobuf.serializer.ProtobufProtocolSerializer;
 import org.apache.geode.protocol.protobuf.utilities.ProtobufUtilities;
@@ -35,40 +37,60 @@ import org.apache.geode.serialization.registry.exception.CodecAlreadyRegisteredF
  * and then pushes it to the output stream.
  */
 @Experimental
-public class ProtobufStreamProcessor implements ClientProtocolMessageHandler {
+public class ProtobufProtocolMessageHandler implements ClientProtocolMessageHandler {
   private final ProtobufProtocolSerializer protobufProtocolSerializer;
-  private final ProtobufOpsProcessor protobufOpsProcessor;
+  private final ProtobufOperationsProcessor protobufOperationProcessor;
+  private final OperationContextRegistry operationContextRegistry;
+  private final ProtobufSerializationService protobufSerializationService;
+  private final Authorizer authorizer;
 
-  public ProtobufStreamProcessor() throws CodecAlreadyRegisteredForTypeException {
+  public ProtobufProtocolMessageHandler() throws CodecAlreadyRegisteredForTypeException {
     protobufProtocolSerializer = new ProtobufProtocolSerializer();
-    protobufOpsProcessor = new ProtobufOpsProcessor(new ProtobufSerializationService(),
-        new OperationContextRegistry());
+    operationContextRegistry = new OperationContextRegistry();
+    protobufSerializationService = new ProtobufSerializationService();
+    authorizer = new AuthorizationLookupService().getAuthorizer();
+    protobufOperationProcessor = new ProtobufOperationsProcessor(protobufSerializationService,
+        operationContextRegistry, authorizer);
+
   }
 
   @Override
   public void receiveMessage(InputStream inputStream, OutputStream outputStream,
       MessageExecutionContext executionContext) throws IOException {
     try {
-      processOneMessage(inputStream, outputStream, executionContext);
+      ClientProtocol.Message incomingMessage = deserializeMessageFromInputStream(inputStream);
+      ClientProtocol.Message outgoingMessage = processMessage(incomingMessage, executionContext);
+      serializeMessageToOutputStream(outgoingMessage, outputStream);
     } catch (InvalidProtocolMessageException e) {
       throw new IOException(e);
     }
   }
 
-  private void processOneMessage(InputStream inputStream, OutputStream outputStream,
-      MessageExecutionContext executionContext)
-      throws InvalidProtocolMessageException, IOException {
-    ClientProtocol.Message message = protobufProtocolSerializer.deserialize(inputStream);
-    if (message == null) {
-      throw new EOFException("Tried to deserialize protobuf message at EOF");
-    }
+  @Override
+  public String getMessageHandlerProtocolName() {
+    return "PROTOBUF";
+  }
 
-    ClientProtocol.Request request = message.getRequest();
-    ClientProtocol.Response response = protobufOpsProcessor.process(request, executionContext);
+  private ClientProtocol.Message processMessage(ClientProtocol.Message message,
+      MessageExecutionContext executionContext) {
+    ClientProtocol.Response response =
+        protobufOperationProcessor.process(message.getRequest(), executionContext);
     ClientProtocol.MessageHeader responseHeader =
         ProtobufUtilities.createMessageHeaderForRequest(message);
-    ClientProtocol.Message responseMessage =
-        ProtobufUtilities.createProtobufResponse(responseHeader, response);
+    return ProtobufUtilities.createProtobufResponse(responseHeader, response);
+  }
+
+  private void serializeMessageToOutputStream(ClientProtocol.Message responseMessage,
+      OutputStream outputStream) throws IOException {
     protobufProtocolSerializer.serialize(responseMessage, outputStream);
   }
+
+  private ClientProtocol.Message deserializeMessageFromInputStream(InputStream inputStream)
+      throws InvalidProtocolMessageException, EOFException {
+    ClientProtocol.Message message = protobufProtocolSerializer.deserialize(inputStream);
+    if (message == null) {
+      throw new EOFException("Tried to deserialize protobuf message at EOF");
+    }
+    return message;
+  }
 }
diff --git a/geode-protobuf/src/main/java/org/apache/geode/protocol/protobuf/ProtobufSimpleAuthenticator.java b/geode-protobuf/src/main/java/org/apache/geode/protocol/protobuf/ProtobufSimpleAuthenticator.java
deleted file mode 100644
index 5fadadd..0000000
--- a/geode-protobuf/src/main/java/org/apache/geode/protocol/protobuf/ProtobufSimpleAuthenticator.java
+++ /dev/null
@@ -1,79 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one or more contributor license
- * agreements. See the NOTICE file distributed with this work for additional information regarding
- * copyright ownership. The ASF licenses this file to You under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance with the License. You may obtain a
- * copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software distributed under the License
- * is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express
- * or implied. See the License for the specific language governing permissions and limitations under
- * the License.
- */
-package org.apache.geode.protocol.protobuf;
-
-import org.apache.geode.management.internal.security.ResourceConstants;
-import org.apache.geode.internal.protocol.protobuf.AuthenticationAPI;
-import org.apache.geode.security.AuthenticationRequiredException;
-import org.apache.geode.security.server.Authenticator;
-import org.apache.geode.security.AuthenticationFailedException;
-import org.apache.geode.security.SecurityManager;
-import org.apache.geode.security.server.Authorizer;
-
-import java.io.EOFException;
-import java.io.IOException;
-import java.io.InputStream;
-import java.io.OutputStream;
-import java.util.Properties;
-
-public class ProtobufSimpleAuthenticator implements Authenticator {
-  private ProtobufSimpleAuthorizer authorizer = null;
-
-  @Override
-  public void authenticate(InputStream inputStream, OutputStream outputStream,
-      SecurityManager securityManager) throws IOException {
-    AuthenticationAPI.SimpleAuthenticationRequest authenticationRequest =
-        AuthenticationAPI.SimpleAuthenticationRequest.parseDelimitedFrom(inputStream);
-    if (authenticationRequest == null) {
-      throw new EOFException();
-    }
-
-    Properties properties = new Properties();
-    properties.setProperty(ResourceConstants.USER_NAME, authenticationRequest.getUsername());
-    properties.setProperty(ResourceConstants.PASSWORD, authenticationRequest.getPassword());
-
-    authorizer = null; // authenticating a new user clears current authorizer
-    try {
-      Object principal = securityManager.authenticate(properties);
-      if (principal != null) {
-        authorizer = new ProtobufSimpleAuthorizer(principal, securityManager);
-      }
-    } catch (AuthenticationFailedException e) {
-      authorizer = null;
-    }
-
-    AuthenticationAPI.SimpleAuthenticationResponse.newBuilder().setAuthenticated(isAuthenticated())
-        .build().writeDelimitedTo(outputStream);
-  }
-
-  @Override
-  public boolean isAuthenticated() {
-    // note: an authorizer is only created if the user has been authenticated
-    return authorizer != null;
-  }
-
-  @Override
-  public Authorizer getAuthorizer() throws AuthenticationRequiredException {
-    if (authorizer == null) {
-      throw new AuthenticationRequiredException("Not yet authenticated");
-    }
-    return authorizer;
-  }
-
-  @Override
-  public String implementationID() {
-    return "SIMPLE";
-  }
-}
diff --git a/geode-protobuf/src/main/java/org/apache/geode/protocol/protobuf/operations/GetAllRequestOperationHandler.java b/geode-protobuf/src/main/java/org/apache/geode/protocol/protobuf/operations/GetAllRequestOperationHandler.java
index 446dbcb..9715ea8 100644
--- a/geode-protobuf/src/main/java/org/apache/geode/protocol/protobuf/operations/GetAllRequestOperationHandler.java
+++ b/geode-protobuf/src/main/java/org/apache/geode/protocol/protobuf/operations/GetAllRequestOperationHandler.java
@@ -14,24 +14,20 @@
  */
 package org.apache.geode.protocol.protobuf.operations;
 
-import java.util.List;
-import java.util.Map;
-import java.util.stream.Collectors;
-
 import org.apache.geode.annotations.Experimental;
 import org.apache.geode.cache.CacheLoaderException;
 import org.apache.geode.cache.PartitionedRegionStorageException;
 import org.apache.geode.cache.Region;
 import org.apache.geode.cache.TimeoutException;
-import org.apache.geode.internal.cache.tier.sockets.MessageExecutionContext;
+import org.apache.geode.internal.protocol.MessageExecutionContext;
 import org.apache.geode.internal.exception.InvalidExecutionContextException;
 import org.apache.geode.internal.protocol.protobuf.BasicTypes;
 import org.apache.geode.internal.protocol.protobuf.RegionAPI;
 import org.apache.geode.protocol.operations.OperationHandler;
-import org.apache.geode.protocol.protobuf.Failure;
+import org.apache.geode.protocol.responses.Failure;
 import org.apache.geode.protocol.protobuf.ProtocolErrorCode;
-import org.apache.geode.protocol.protobuf.Result;
-import org.apache.geode.protocol.protobuf.Success;
+import org.apache.geode.protocol.responses.Result;
+import org.apache.geode.protocol.responses.Success;
 import org.apache.geode.protocol.protobuf.utilities.ProtobufResponseUtilities;
 import org.apache.geode.protocol.protobuf.utilities.ProtobufUtilities;
 import org.apache.geode.serialization.SerializationService;
@@ -53,18 +49,16 @@ public class GetAllRequestOperationHandler
           .makeErrorResponse(ProtocolErrorCode.REGION_NOT_FOUND.codeValue, "Region not found"));
     }
 
-    Map<Boolean, List<Object>> resultsCollection = request.getKeyList().stream()
-        .map((key) -> processOneMessage(serializationService, region, key))
-        .collect(Collectors.partitioningBy(x -> x instanceof BasicTypes.Entry));
     RegionAPI.GetAllResponse.Builder responseBuilder = RegionAPI.GetAllResponse.newBuilder();
 
-    for (Object entry : resultsCollection.get(true)) {
-      responseBuilder.addEntries((BasicTypes.Entry) entry);
-    }
-
-    for (Object entry : resultsCollection.get(false)) {
-      responseBuilder.addFailures((BasicTypes.KeyedError) entry);
-    }
+    request.getKeyList().stream().map((key) -> processOneMessage(serializationService, region, key))
+        .forEach(entry -> {
+          if (entry instanceof BasicTypes.Entry) {
+            responseBuilder.addEntries((BasicTypes.Entry) entry);
+          } else if (entry instanceof BasicTypes.KeyedError) {
+            responseBuilder.addFailures((BasicTypes.KeyedError) entry);
+          }
+        });
 
     return Success.of(responseBuilder.build());
   }
diff --git a/geode-protobuf/src/main/java/org/apache/geode/protocol/protobuf/operations/GetAvailableServersOperationHandler.java b/geode-protobuf/src/main/java/org/apache/geode/protocol/protobuf/operations/GetAvailableServersOperationHandler.java
index a242492..1c9a6fa 100644
--- a/geode-protobuf/src/main/java/org/apache/geode/protocol/protobuf/operations/GetAvailableServersOperationHandler.java
+++ b/geode-protobuf/src/main/java/org/apache/geode/protocol/protobuf/operations/GetAvailableServersOperationHandler.java
@@ -14,20 +14,19 @@
  */
 package org.apache.geode.protocol.protobuf.operations;
 
-import java.util.ArrayList;
-import java.util.Collection;
-import java.util.stream.Collectors;
+import java.util.Collections;
+import java.util.List;
 
 import org.apache.geode.annotations.Experimental;
 import org.apache.geode.distributed.internal.InternalLocator;
 import org.apache.geode.distributed.internal.ServerLocation;
-import org.apache.geode.internal.cache.tier.sockets.MessageExecutionContext;
+import org.apache.geode.internal.protocol.MessageExecutionContext;
 import org.apache.geode.internal.exception.InvalidExecutionContextException;
-import org.apache.geode.protocol.operations.OperationHandler;
 import org.apache.geode.internal.protocol.protobuf.BasicTypes;
-import org.apache.geode.protocol.protobuf.Result;
 import org.apache.geode.internal.protocol.protobuf.ServerAPI;
-import org.apache.geode.protocol.protobuf.Success;
+import org.apache.geode.protocol.operations.OperationHandler;
+import org.apache.geode.protocol.responses.Result;
+import org.apache.geode.protocol.responses.Success;
 import org.apache.geode.serialization.SerializationService;
 
 @Experimental
@@ -40,18 +39,19 @@ public class GetAvailableServersOperationHandler implements
       MessageExecutionContext executionContext) throws InvalidExecutionContextException {
 
     InternalLocator internalLocator = (InternalLocator) executionContext.getLocator();
-    ArrayList serversFromSnapshot =
+    List serversFromSnapshot =
         internalLocator.getServerLocatorAdvisee().getLoadSnapshot().getServers(null);
     if (serversFromSnapshot == null) {
-      serversFromSnapshot = new ArrayList();
+      serversFromSnapshot = Collections.EMPTY_LIST;
     }
 
-    Collection<BasicTypes.Server> servers = (Collection<BasicTypes.Server>) serversFromSnapshot
-        .stream().map(serverLocation -> getServerProtobufMessage((ServerLocation) serverLocation))
-        .collect(Collectors.toList());
-    ServerAPI.GetAvailableServersResponse.Builder builder =
-        ServerAPI.GetAvailableServersResponse.newBuilder().addAllServers(servers);
-    return Success.of(builder.build());
+    ServerAPI.GetAvailableServersResponse.Builder serverResponseBuilder =
+        ServerAPI.GetAvailableServersResponse.newBuilder();
+
+    serversFromSnapshot.stream()
+        .map(serverLocation -> getServerProtobufMessage((ServerLocation) serverLocation)).forEach(
+            serverMessage -> serverResponseBuilder.addServers((BasicTypes.Server) serverMessage));
+    return Success.of(serverResponseBuilder.build());
   }
 
   private BasicTypes.Server getServerProtobufMessage(ServerLocation serverLocation) {
diff --git a/geode-protobuf/src/main/java/org/apache/geode/protocol/protobuf/operations/GetRegionNamesRequestOperationHandler.java b/geode-protobuf/src/main/java/org/apache/geode/protocol/protobuf/operations/GetRegionNamesRequestOperationHandler.java
index 8d1b466..e819b1f 100644
--- a/geode-protobuf/src/main/java/org/apache/geode/protocol/protobuf/operations/GetRegionNamesRequestOperationHandler.java
+++ b/geode-protobuf/src/main/java/org/apache/geode/protocol/protobuf/operations/GetRegionNamesRequestOperationHandler.java
@@ -18,12 +18,12 @@ import java.util.Set;
 
 import org.apache.geode.annotations.Experimental;
 import org.apache.geode.cache.Region;
-import org.apache.geode.internal.cache.tier.sockets.MessageExecutionContext;
+import org.apache.geode.internal.protocol.MessageExecutionContext;
 import org.apache.geode.internal.exception.InvalidExecutionContextException;
 import org.apache.geode.protocol.operations.OperationHandler;
 import org.apache.geode.internal.protocol.protobuf.RegionAPI;
-import org.apache.geode.protocol.protobuf.Result;
-import org.apache.geode.protocol.protobuf.Success;
+import org.apache.geode.protocol.responses.Result;
+import org.apache.geode.protocol.responses.Success;
 import org.apache.geode.protocol.protobuf.utilities.ProtobufResponseUtilities;
 import org.apache.geode.serialization.SerializationService;
 
diff --git a/geode-protobuf/src/main/java/org/apache/geode/protocol/protobuf/operations/GetRegionRequestOperationHandler.java b/geode-protobuf/src/main/java/org/apache/geode/protocol/protobuf/operations/GetRegionRequestOperationHandler.java
index a41519a..2e94cb8 100644
--- a/geode-protobuf/src/main/java/org/apache/geode/protocol/protobuf/operations/GetRegionRequestOperationHandler.java
+++ b/geode-protobuf/src/main/java/org/apache/geode/protocol/protobuf/operations/GetRegionRequestOperationHandler.java
@@ -16,15 +16,15 @@ package org.apache.geode.protocol.protobuf.operations;
 
 import org.apache.geode.annotations.Experimental;
 import org.apache.geode.cache.Region;
-import org.apache.geode.internal.cache.tier.sockets.MessageExecutionContext;
+import org.apache.geode.internal.protocol.MessageExecutionContext;
 import org.apache.geode.internal.exception.InvalidExecutionContextException;
 import org.apache.geode.internal.protocol.protobuf.BasicTypes;
 import org.apache.geode.protocol.operations.OperationHandler;
-import org.apache.geode.protocol.protobuf.Failure;
+import org.apache.geode.protocol.responses.Failure;
 import org.apache.geode.protocol.protobuf.ProtocolErrorCode;
 import org.apache.geode.internal.protocol.protobuf.RegionAPI;
-import org.apache.geode.protocol.protobuf.Result;
-import org.apache.geode.protocol.protobuf.Success;
+import org.apache.geode.protocol.responses.Result;
+import org.apache.geode.protocol.responses.Success;
 import org.apache.geode.protocol.protobuf.utilities.ProtobufResponseUtilities;
 import org.apache.geode.protocol.protobuf.utilities.ProtobufUtilities;
 import org.apache.geode.serialization.SerializationService;
diff --git a/geode-protobuf/src/main/java/org/apache/geode/protocol/protobuf/operations/GetRequestOperationHandler.java b/geode-protobuf/src/main/java/org/apache/geode/protocol/protobuf/operations/GetRequestOperationHandler.java
index 79ad85a..5f37a76 100644
--- a/geode-protobuf/src/main/java/org/apache/geode/protocol/protobuf/operations/GetRequestOperationHandler.java
+++ b/geode-protobuf/src/main/java/org/apache/geode/protocol/protobuf/operations/GetRequestOperationHandler.java
@@ -16,15 +16,15 @@ package org.apache.geode.protocol.protobuf.operations;
 
 import org.apache.geode.annotations.Experimental;
 import org.apache.geode.cache.Region;
-import org.apache.geode.internal.cache.tier.sockets.MessageExecutionContext;
+import org.apache.geode.internal.protocol.MessageExecutionContext;
 import org.apache.geode.internal.exception.InvalidExecutionContextException;
 import org.apache.geode.protocol.operations.OperationHandler;
 import org.apache.geode.internal.protocol.protobuf.BasicTypes;
-import org.apache.geode.protocol.protobuf.Failure;
+import org.apache.geode.protocol.responses.Failure;
 import org.apache.geode.protocol.protobuf.ProtocolErrorCode;
 import org.apache.geode.internal.protocol.protobuf.RegionAPI;
-import org.apache.geode.protocol.protobuf.Result;
-import org.apache.geode.protocol.protobuf.Success;
+import org.apache.geode.protocol.responses.Result;
+import org.apache.geode.protocol.responses.Success;
 import org.apache.geode.protocol.protobuf.utilities.ProtobufResponseUtilities;
 import org.apache.geode.protocol.protobuf.utilities.ProtobufUtilities;
 import org.apache.geode.serialization.SerializationService;
diff --git a/geode-protobuf/src/main/java/org/apache/geode/protocol/protobuf/operations/PutAllRequestOperationHandler.java b/geode-protobuf/src/main/java/org/apache/geode/protocol/protobuf/operations/PutAllRequestOperationHandler.java
index 8f2d9ef..03f7379 100644
--- a/geode-protobuf/src/main/java/org/apache/geode/protocol/protobuf/operations/PutAllRequestOperationHandler.java
+++ b/geode-protobuf/src/main/java/org/apache/geode/protocol/protobuf/operations/PutAllRequestOperationHandler.java
@@ -15,22 +15,21 @@
 package org.apache.geode.protocol.protobuf.operations;
 
 import java.util.Objects;
-import java.util.stream.Collectors;
 
 import org.apache.logging.log4j.LogManager;
 import org.apache.logging.log4j.Logger;
 
 import org.apache.geode.annotations.Experimental;
 import org.apache.geode.cache.Region;
-import org.apache.geode.internal.cache.tier.sockets.MessageExecutionContext;
+import org.apache.geode.internal.protocol.MessageExecutionContext;
 import org.apache.geode.internal.exception.InvalidExecutionContextException;
 import org.apache.geode.protocol.operations.OperationHandler;
 import org.apache.geode.internal.protocol.protobuf.BasicTypes;
-import org.apache.geode.protocol.protobuf.Failure;
+import org.apache.geode.protocol.responses.Failure;
 import org.apache.geode.protocol.protobuf.ProtocolErrorCode;
 import org.apache.geode.internal.protocol.protobuf.RegionAPI;
-import org.apache.geode.protocol.protobuf.Result;
-import org.apache.geode.protocol.protobuf.Success;
+import org.apache.geode.protocol.responses.Result;
+import org.apache.geode.protocol.responses.Success;
 import org.apache.geode.protocol.protobuf.utilities.ProtobufResponseUtilities;
 import org.apache.geode.protocol.protobuf.utilities.ProtobufUtilities;
 import org.apache.geode.serialization.SerializationService;
@@ -54,10 +53,10 @@ public class PutAllRequestOperationHandler
           "Region passed by client did not exist: " + putAllRequest.getRegionName(), logger, null));
     }
 
-    RegionAPI.PutAllResponse.Builder builder = RegionAPI.PutAllResponse.newBuilder()
-        .addAllFailedKeys(putAllRequest.getEntryList().stream()
-            .map((entry) -> singlePut(serializationService, region, entry)).filter(Objects::nonNull)
-            .collect(Collectors.toList()));
+    RegionAPI.PutAllResponse.Builder builder = RegionAPI.PutAllResponse.newBuilder();
+    putAllRequest.getEntryList().stream()
+        .map((entry) -> singlePut(serializationService, region, entry)).filter(Objects::nonNull)
+        .forEach(failedKey -> builder.addFailedKeys(failedKey));
     return Success.of(builder.build());
   }
 
diff --git a/geode-protobuf/src/main/java/org/apache/geode/protocol/protobuf/operations/PutRequestOperationHandler.java b/geode-protobuf/src/main/java/org/apache/geode/protocol/protobuf/operations/PutRequestOperationHandler.java
index 3be4a84..3a89fa2 100644
--- a/geode-protobuf/src/main/java/org/apache/geode/protocol/protobuf/operations/PutRequestOperationHandler.java
+++ b/geode-protobuf/src/main/java/org/apache/geode/protocol/protobuf/operations/PutRequestOperationHandler.java
@@ -16,15 +16,15 @@ package org.apache.geode.protocol.protobuf.operations;
 
 import org.apache.geode.annotations.Experimental;
 import org.apache.geode.cache.Region;
-import org.apache.geode.internal.cache.tier.sockets.MessageExecutionContext;
+import org.apache.geode.internal.protocol.MessageExecutionContext;
 import org.apache.geode.internal.exception.InvalidExecutionContextException;
 import org.apache.geode.protocol.operations.OperationHandler;
 import org.apache.geode.internal.protocol.protobuf.BasicTypes;
-import org.apache.geode.protocol.protobuf.Failure;
+import org.apache.geode.protocol.responses.Failure;
 import org.apache.geode.protocol.protobuf.ProtocolErrorCode;
 import org.apache.geode.internal.protocol.protobuf.RegionAPI;
-import org.apache.geode.protocol.protobuf.Result;
-import org.apache.geode.protocol.protobuf.Success;
+import org.apache.geode.protocol.responses.Result;
+import org.apache.geode.protocol.responses.Success;
 import org.apache.geode.protocol.protobuf.utilities.ProtobufResponseUtilities;
 import org.apache.geode.protocol.protobuf.utilities.ProtobufUtilities;
 import org.apache.geode.serialization.SerializationService;
diff --git a/geode-protobuf/src/main/java/org/apache/geode/protocol/protobuf/operations/RemoveRequestOperationHandler.java b/geode-protobuf/src/main/java/org/apache/geode/protocol/protobuf/operations/RemoveRequestOperationHandler.java
index 513dc25..6d9b7a8 100644
--- a/geode-protobuf/src/main/java/org/apache/geode/protocol/protobuf/operations/RemoveRequestOperationHandler.java
+++ b/geode-protobuf/src/main/java/org/apache/geode/protocol/protobuf/operations/RemoveRequestOperationHandler.java
@@ -19,14 +19,14 @@ import org.apache.logging.log4j.Logger;
 
 import org.apache.geode.annotations.Experimental;
 import org.apache.geode.cache.Region;
-import org.apache.geode.internal.cache.tier.sockets.MessageExecutionContext;
+import org.apache.geode.internal.protocol.MessageExecutionContext;
 import org.apache.geode.internal.exception.InvalidExecutionContextException;
 import org.apache.geode.protocol.operations.OperationHandler;
-import org.apache.geode.protocol.protobuf.Failure;
+import org.apache.geode.protocol.responses.Failure;
 import org.apache.geode.protocol.protobuf.ProtocolErrorCode;
 import org.apache.geode.internal.protocol.protobuf.RegionAPI;
-import org.apache.geode.protocol.protobuf.Result;
-import org.apache.geode.protocol.protobuf.Success;
+import org.apache.geode.protocol.responses.Result;
+import org.apache.geode.protocol.responses.Success;
 import org.apache.geode.protocol.protobuf.utilities.ProtobufResponseUtilities;
 import org.apache.geode.protocol.protobuf.utilities.ProtobufUtilities;
 import org.apache.geode.serialization.SerializationService;
diff --git a/geode-protobuf/src/main/java/org/apache/geode/protocol/protobuf/security/server/ProtobufSimpleAuthenticator.java b/geode-protobuf/src/main/java/org/apache/geode/protocol/protobuf/security/server/ProtobufSimpleAuthenticator.java
new file mode 100644
index 0000000..2cdbeae
--- /dev/null
+++ b/geode-protobuf/src/main/java/org/apache/geode/protocol/protobuf/security/server/ProtobufSimpleAuthenticator.java
@@ -0,0 +1,75 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one or more contributor license
+ * agreements. See the NOTICE file distributed with this work for additional information regarding
+ * copyright ownership. The ASF licenses this file to You under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance with the License. You may obtain a
+ * copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software distributed under the License
+ * is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express
+ * or implied. See the License for the specific language governing permissions and limitations under
+ * the License.
+ */
+package org.apache.geode.protocol.protobuf.security.server;
+
+import java.io.EOFException;
+import java.io.IOException;
+import java.io.InputStream;
+import java.io.OutputStream;
+import java.util.Properties;
+
+import org.apache.geode.internal.protocol.protobuf.AuthenticationAPI;
+import org.apache.geode.internal.protocol.security.server.Authenticator;
+import org.apache.geode.management.internal.security.ResourceConstants;
+import org.apache.geode.security.AuthenticationFailedException;
+import org.apache.geode.security.SecurityManager;
+
+public class ProtobufSimpleAuthenticator implements Authenticator {
+  private boolean authenticationSuccessfull = false;
+  private Object principal;
+
+  @Override
+  public Object authenticate(InputStream inputStream, OutputStream outputStream,
+      SecurityManager securityManager) throws IOException {
+    if (authenticationSuccessfull) {
+      return principal;
+    } else {
+      AuthenticationAPI.SimpleAuthenticationRequest authenticationRequest =
+          AuthenticationAPI.SimpleAuthenticationRequest.parseDelimitedFrom(inputStream);
+      if (authenticationRequest == null) {
+        // TODO Why are we returning and EOF here?
+        throw new EOFException();
+      }
+
+      Properties properties = new Properties();
+      properties.setProperty(ResourceConstants.USER_NAME, authenticationRequest.getUsername());
+      properties.setProperty(ResourceConstants.PASSWORD, authenticationRequest.getPassword());
+
+      try {
+        principal = securityManager.authenticate(properties);
+        authenticationSuccessfull = true;
+        AuthenticationAPI.SimpleAuthenticationResponse.newBuilder()
+            .setAuthenticated(isAuthenticated()).build().writeDelimitedTo(outputStream);
+        return principal;
+      } catch (AuthenticationFailedException e) {
+        // We need to add some logging here;
+        // logger.error(e);
+        AuthenticationAPI.SimpleAuthenticationResponse.newBuilder().setAuthenticated(false).build()
+            .writeDelimitedTo(outputStream);
+        throw e;
+      }
+    }
+  }
+
+  @Override
+  public boolean isAuthenticated() {
+    return authenticationSuccessfull;
+  }
+
+  @Override
+  public String getImplementationID() {
+    return "SIMPLE";
+  }
+}
diff --git a/geode-protobuf/src/main/java/org/apache/geode/protocol/protobuf/ProtobufSimpleAuthorizer.java b/geode-protobuf/src/main/java/org/apache/geode/protocol/protobuf/security/server/ProtobufSimpleAuthorizer.java
similarity index 69%
rename from geode-protobuf/src/main/java/org/apache/geode/protocol/protobuf/ProtobufSimpleAuthorizer.java
rename to geode-protobuf/src/main/java/org/apache/geode/protocol/protobuf/security/server/ProtobufSimpleAuthorizer.java
index e29abfa..067bb6a 100644
--- a/geode-protobuf/src/main/java/org/apache/geode/protocol/protobuf/ProtobufSimpleAuthorizer.java
+++ b/geode-protobuf/src/main/java/org/apache/geode/protocol/protobuf/security/server/ProtobufSimpleAuthorizer.java
@@ -12,23 +12,21 @@
  * or implied. See the License for the specific language governing permissions and limitations under
  * the License.
  */
-package org.apache.geode.protocol.protobuf;
+package org.apache.geode.protocol.protobuf.security.server;
 
+import org.apache.geode.internal.protocol.security.server.Authorizer;
 import org.apache.geode.security.ResourcePermission;
 import org.apache.geode.security.SecurityManager;
-import org.apache.geode.security.server.Authorizer;
 
 public class ProtobufSimpleAuthorizer implements Authorizer {
-  private final Object authenticatedPrincipal;
-  private final SecurityManager securityManager;
-
-  public ProtobufSimpleAuthorizer(Object authenticatedPrincipal, SecurityManager securityManager) {
-    this.authenticatedPrincipal = authenticatedPrincipal;
-    this.securityManager = securityManager;
+  @Override
+  public boolean authorize(Object authenticatedPrincipal, ResourcePermission permissionRequested,
+      SecurityManager securityManager) {
+    return securityManager.authorize(authenticatedPrincipal, permissionRequested);
   }
 
   @Override
-  public boolean authorize(ResourcePermission permissionRequested) {
-    return securityManager.authorize(authenticatedPrincipal, permissionRequested);
+  public String getImplementationID() {
+    return "SIMPLE";
   }
 }
diff --git a/geode-protobuf/src/main/java/org/apache/geode/protocol/protobuf/utilities/ProtobufPrimitiveTypes.java b/geode-protobuf/src/main/java/org/apache/geode/protocol/protobuf/utilities/ProtobufPrimitiveTypes.java
index 90ce308..c847cda 100644
--- a/geode-protobuf/src/main/java/org/apache/geode/protocol/protobuf/utilities/ProtobufPrimitiveTypes.java
+++ b/geode-protobuf/src/main/java/org/apache/geode/protocol/protobuf/utilities/ProtobufPrimitiveTypes.java
@@ -15,8 +15,12 @@
 package org.apache.geode.protocol.protobuf.utilities;
 
 import org.apache.geode.annotations.Experimental;
-import org.apache.geode.protocol.protobuf.utilities.exception.UnknownProtobufPrimitiveType;
+import org.apache.geode.protocol.exception.UnknownProtobufPrimitiveType;
 
+
+/**
+ * This enums primary use is to serialize Java primitive types with Protobuf
+ */
 @Experimental
 public enum ProtobufPrimitiveTypes {
 
diff --git a/geode-protobuf/src/main/java/org/apache/geode/protocol/protobuf/utilities/ProtobufUtilities.java b/geode-protobuf/src/main/java/org/apache/geode/protocol/protobuf/utilities/ProtobufUtilities.java
index 4da8723..927f8ba 100644
--- a/geode-protobuf/src/main/java/org/apache/geode/protocol/protobuf/utilities/ProtobufUtilities.java
+++ b/geode-protobuf/src/main/java/org/apache/geode/protocol/protobuf/utilities/ProtobufUtilities.java
@@ -21,10 +21,10 @@ import org.apache.geode.cache.Region;
 import org.apache.geode.cache.RegionAttributes;
 import org.apache.geode.internal.protocol.protobuf.BasicTypes;
 import org.apache.geode.internal.protocol.protobuf.ClientProtocol;
+import org.apache.geode.internal.protocol.protobuf.RegionAPI;
+import org.apache.geode.protocol.exception.UnknownProtobufPrimitiveType;
 import org.apache.geode.protocol.protobuf.EncodingTypeTranslator;
 import org.apache.geode.protocol.protobuf.ProtobufSerializationService;
-import org.apache.geode.internal.protocol.protobuf.RegionAPI;
-import org.apache.geode.protocol.protobuf.utilities.exception.UnknownProtobufPrimitiveType;
 import org.apache.geode.serialization.SerializationService;
 import org.apache.geode.serialization.exception.UnsupportedEncodingTypeException;
 import org.apache.geode.serialization.registry.exception.CodecNotRegisteredForTypeException;
diff --git a/geode-protobuf/src/main/java/org/apache/geode/protocol/protobuf/Failure.java b/geode-protobuf/src/main/java/org/apache/geode/protocol/responses/Failure.java
similarity index 97%
rename from geode-protobuf/src/main/java/org/apache/geode/protocol/protobuf/Failure.java
rename to geode-protobuf/src/main/java/org/apache/geode/protocol/responses/Failure.java
index e1595dc..a5e0c97 100644
--- a/geode-protobuf/src/main/java/org/apache/geode/protocol/protobuf/Failure.java
+++ b/geode-protobuf/src/main/java/org/apache/geode/protocol/responses/Failure.java
@@ -12,7 +12,7 @@
  * or implied. See the License for the specific language governing permissions and limitations under
  * the License.
  */
-package org.apache.geode.protocol.protobuf;
+package org.apache.geode.protocol.responses;
 
 import java.util.function.Function;
 
diff --git a/geode-protobuf/src/main/java/org/apache/geode/protocol/protobuf/Result.java b/geode-protobuf/src/main/java/org/apache/geode/protocol/responses/Result.java
similarity index 96%
rename from geode-protobuf/src/main/java/org/apache/geode/protocol/protobuf/Result.java
rename to geode-protobuf/src/main/java/org/apache/geode/protocol/responses/Result.java
index f0c3b32..df5e32b 100644
--- a/geode-protobuf/src/main/java/org/apache/geode/protocol/protobuf/Result.java
+++ b/geode-protobuf/src/main/java/org/apache/geode/protocol/responses/Result.java
@@ -12,7 +12,7 @@
  * or implied. See the License for the specific language governing permissions and limitations under
  * the License.
  */
-package org.apache.geode.protocol.protobuf;
+package org.apache.geode.protocol.responses;
 
 import java.util.function.Function;
 
diff --git a/geode-protobuf/src/main/java/org/apache/geode/protocol/protobuf/Success.java b/geode-protobuf/src/main/java/org/apache/geode/protocol/responses/Success.java
similarity index 97%
rename from geode-protobuf/src/main/java/org/apache/geode/protocol/protobuf/Success.java
rename to geode-protobuf/src/main/java/org/apache/geode/protocol/responses/Success.java
index 0d3895b..4d1bba2 100644
--- a/geode-protobuf/src/main/java/org/apache/geode/protocol/protobuf/Success.java
+++ b/geode-protobuf/src/main/java/org/apache/geode/protocol/responses/Success.java
@@ -12,7 +12,7 @@
  * or implied. See the License for the specific language governing permissions and limitations under
  * the License.
  */
-package org.apache.geode.protocol.protobuf;
+package org.apache.geode.protocol.responses;
 
 import java.util.function.Function;
 
diff --git a/geode-protobuf/src/main/resources/META-INF/services/org.apache.geode.internal.cache.tier.sockets.ClientProtocolMessageHandler b/geode-protobuf/src/main/resources/META-INF/services/org.apache.geode.internal.cache.tier.sockets.ClientProtocolMessageHandler
deleted file mode 100644
index 5a17eda..0000000
--- a/geode-protobuf/src/main/resources/META-INF/services/org.apache.geode.internal.cache.tier.sockets.ClientProtocolMessageHandler
+++ /dev/null
@@ -1 +0,0 @@
-org.apache.geode.protocol.protobuf.ProtobufStreamProcessor
\ No newline at end of file
diff --git a/geode-protobuf/src/main/resources/META-INF/services/org.apache.geode.internal.protocol.ClientProtocolMessageHandler b/geode-protobuf/src/main/resources/META-INF/services/org.apache.geode.internal.protocol.ClientProtocolMessageHandler
new file mode 100644
index 0000000..33fe588
--- /dev/null
+++ b/geode-protobuf/src/main/resources/META-INF/services/org.apache.geode.internal.protocol.ClientProtocolMessageHandler
@@ -0,0 +1 @@
+org.apache.geode.protocol.protobuf.ProtobufProtocolMessageHandler
\ No newline at end of file
diff --git a/geode-protobuf/src/main/resources/META-INF/services/org.apache.geode.internal.protocol.security.server.Authenticator b/geode-protobuf/src/main/resources/META-INF/services/org.apache.geode.internal.protocol.security.server.Authenticator
new file mode 100644
index 0000000..0005e93
--- /dev/null
+++ b/geode-protobuf/src/main/resources/META-INF/services/org.apache.geode.internal.protocol.security.server.Authenticator
@@ -0,0 +1 @@
+org.apache.geode.protocol.protobuf.security.server.ProtobufSimpleAuthenticator
\ No newline at end of file
diff --git a/geode-protobuf/src/main/resources/META-INF/services/org.apache.geode.internal.protocol.security.server.Authorizer b/geode-protobuf/src/main/resources/META-INF/services/org.apache.geode.internal.protocol.security.server.Authorizer
new file mode 100644
index 0000000..a2bf30d
--- /dev/null
+++ b/geode-protobuf/src/main/resources/META-INF/services/org.apache.geode.internal.protocol.security.server.Authorizer
@@ -0,0 +1 @@
+org.apache.geode.protocol.protobuf.security.server.ProtobufSimpleAuthorizer
\ No newline at end of file
diff --git a/geode-protobuf/src/main/resources/META-INF/services/org.apache.geode.security.server.Authenticator b/geode-protobuf/src/main/resources/META-INF/services/org.apache.geode.security.server.Authenticator
deleted file mode 100644
index 45e4eea..0000000
--- a/geode-protobuf/src/main/resources/META-INF/services/org.apache.geode.security.server.Authenticator
+++ /dev/null
@@ -1 +0,0 @@
-org.apache.geode.protocol.protobuf.ProtobufSimpleAuthenticator
\ No newline at end of file
diff --git a/geode-core/src/test/java/org/apache/geode/internal/cache/tier/sockets/GenericProtocolServerConnectionTest.java b/geode-protobuf/src/test/java/org/apache/geode/internal/cache/tier/sockets/GenericProtocolServerConnectionTest.java
similarity index 89%
rename from geode-core/src/test/java/org/apache/geode/internal/cache/tier/sockets/GenericProtocolServerConnectionTest.java
rename to geode-protobuf/src/test/java/org/apache/geode/internal/cache/tier/sockets/GenericProtocolServerConnectionTest.java
index be9c4a2..a6a0907 100644
--- a/geode-core/src/test/java/org/apache/geode/internal/cache/tier/sockets/GenericProtocolServerConnectionTest.java
+++ b/geode-protobuf/src/test/java/org/apache/geode/internal/cache/tier/sockets/GenericProtocolServerConnectionTest.java
@@ -19,12 +19,20 @@ import static org.mockito.Mockito.doThrow;
 import static org.mockito.Mockito.mock;
 import static org.mockito.Mockito.when;
 
+import java.io.IOException;
+import java.net.InetAddress;
+import java.net.Socket;
+
+import org.junit.Test;
+import org.junit.experimental.categories.Category;
+
 import org.apache.geode.internal.Assert;
 import org.apache.geode.internal.cache.InternalCache;
 import org.apache.geode.internal.cache.tier.CachedRegionHelper;
 import org.apache.geode.internal.cache.tier.CommunicationMode;
+import org.apache.geode.internal.protocol.ClientProtocolMessageHandler;
+import org.apache.geode.internal.protocol.security.server.AuthenticatorLookupService;
 import org.apache.geode.internal.security.SecurityService;
-import org.apache.geode.security.server.NoOpAuthenticator;
 import org.apache.geode.test.junit.categories.UnitTest;
 
 import org.junit.Test;
@@ -79,6 +87,7 @@ public class GenericProtocolServerConnectionTest {
     return new GenericProtocolServerConnection(socketMock, mock(InternalCache.class),
         mock(CachedRegionHelper.class), mock(CacheServerStats.class), 0, 0, "",
         CommunicationMode.ProtobufClientServerProtocol.getModeNumber(), mock(AcceptorImpl.class),
-        clientProtocolMock, mock(SecurityService.class), new NoOpAuthenticator());
+        mock(SecurityService.class), clientProtocolMock,
+        new AuthenticatorLookupService().getAuthenticator());
   }
 }
diff --git a/geode-protobuf/src/test/java/org/apache/geode/protocol/RoundTripCacheConnectionJUnitTest.java b/geode-protobuf/src/test/java/org/apache/geode/protocol/RoundTripCacheConnectionJUnitTest.java
index cc15e4f..cf67a10 100644
--- a/geode-protobuf/src/test/java/org/apache/geode/protocol/RoundTripCacheConnectionJUnitTest.java
+++ b/geode-protobuf/src/test/java/org/apache/geode/protocol/RoundTripCacheConnectionJUnitTest.java
@@ -71,7 +71,6 @@ import org.apache.geode.protocol.protobuf.utilities.ProtobufRequestUtilities;
 import org.apache.geode.protocol.protobuf.utilities.ProtobufUtilities;
 import org.apache.geode.serialization.SerializationService;
 import org.apache.geode.serialization.exception.UnsupportedEncodingTypeException;
-import org.apache.geode.serialization.registry.exception.CodecAlreadyRegisteredForTypeException;
 import org.apache.geode.serialization.registry.exception.CodecNotRegisteredForTypeException;
 import org.apache.geode.test.junit.categories.IntegrationTest;
 import org.apache.geode.util.test.TestUtil;
@@ -276,28 +275,21 @@ public class RoundTripCacheConnectionJUnitTest {
 
   @Test
   public void testConnectionCountIsProperlyDecremented() throws Exception {
-    CacheServer cacheServer = this.cache.getCacheServers().stream().findFirst().get();
+    CacheServer cacheServer = this.cache.getCacheServers().get(0);
     AcceptorImpl acceptor = ((CacheServerImpl) cacheServer).getAcceptor();
-    Awaitility.await().atMost(30, TimeUnit.SECONDS).until(() -> {
-      return acceptor.getClientServerCnxCount() == 1;
-    });
+    Awaitility.await().atMost(30, TimeUnit.SECONDS)
+        .until(() -> acceptor.getClientServerCnxCount() == 1);
     // run another test that creates a connection to the server
     testNewProtocolGetRegionNamesCallSucceeds();
     assertFalse(socket.isClosed());
     socket.close();
-    Awaitility.await().atMost(30, TimeUnit.SECONDS).until(() -> {
-      return acceptor.getClientServerCnxCount() == 0;
-    });
+    Awaitility.await().atMost(30, TimeUnit.SECONDS)
+        .until(() -> acceptor.getClientServerCnxCount() == 0);
   }
 
   @Test
   public void testNewProtocolRespectsMaxConnectionLimit() throws IOException, InterruptedException {
-    cache.getDistributedSystem().disconnect();
-
-    CacheFactory cacheFactory = new CacheFactory();
-    cacheFactory.set(ConfigurationProperties.LOCATORS, "");
-    cacheFactory.set(ConfigurationProperties.MCAST_PORT, "0");
-    cache = cacheFactory.create();
+    cache.getCacheServers().get(0).stop();
 
     CacheServer cacheServer = cache.addCacheServer();
     final int cacheServerPort = AvailablePortHelper.getRandomAvailableTCPPort();
@@ -409,8 +401,7 @@ public class RoundTripCacheConnectionJUnitTest {
 
   private void validateGetResponse(Socket socket,
       ProtobufProtocolSerializer protobufProtocolSerializer, Object expectedValue)
-      throws InvalidProtocolMessageException, IOException, UnsupportedEncodingTypeException,
-      CodecNotRegisteredForTypeException, CodecAlreadyRegisteredForTypeException {
+      throws InvalidProtocolMessageException, IOException {
     ClientProtocol.Response response =
         deserializeResponse(socket, protobufProtocolSerializer, TEST_GET_CORRELATION_ID);
 
@@ -462,9 +453,8 @@ public class RoundTripCacheConnectionJUnitTest {
   }
 
   private void validateGetAllResponse(Socket socket,
-      ProtobufProtocolSerializer protobufProtocolSerializer)
-      throws InvalidProtocolMessageException, IOException, UnsupportedEncodingTypeException,
-      CodecNotRegisteredForTypeException, CodecAlreadyRegisteredForTypeException {
+      ProtobufProtocolSerializer protobufProtocolSerializer) throws InvalidProtocolMessageException,
+      IOException, UnsupportedEncodingTypeException, CodecNotRegisteredForTypeException {
     ClientProtocol.Response response =
         deserializeResponse(socket, protobufProtocolSerializer, TEST_GET_CORRELATION_ID);
     assertEquals(ClientProtocol.Response.ResponseAPICase.GETALLRESPONSE,
diff --git a/geode-protobuf/src/test/java/org/apache/geode/protocol/protobuf/ProtobufStreamProcessorTest.java b/geode-protobuf/src/test/java/org/apache/geode/protocol/protobuf/ProtobufProtocolMessageHandlerTest.java
similarity index 78%
rename from geode-protobuf/src/test/java/org/apache/geode/protocol/protobuf/ProtobufStreamProcessorTest.java
rename to geode-protobuf/src/test/java/org/apache/geode/protocol/protobuf/ProtobufProtocolMessageHandlerTest.java
index 50d7b40..6cd56af 100644
--- a/geode-protobuf/src/test/java/org/apache/geode/protocol/protobuf/ProtobufStreamProcessorTest.java
+++ b/geode-protobuf/src/test/java/org/apache/geode/protocol/protobuf/ProtobufProtocolMessageHandlerTest.java
@@ -26,20 +26,20 @@ import org.junit.Test;
 import org.junit.experimental.categories.Category;
 
 import org.apache.geode.internal.cache.InternalCache;
-import org.apache.geode.internal.cache.tier.sockets.MessageExecutionContext;
-import org.apache.geode.security.server.NoOpAuthorizer;
+import org.apache.geode.internal.protocol.MessageExecutionContext;
 import org.apache.geode.test.junit.categories.UnitTest;
 
 @Category(UnitTest.class)
-public class ProtobufStreamProcessorTest {
+public class ProtobufProtocolMessageHandlerTest {
   @Test(expected = EOFException.class)
   public void receiveMessage() throws Exception {
     InputStream inputStream = new ByteArrayInputStream(new byte[0]);
     OutputStream outputStream = new ByteArrayOutputStream(2);
 
-    ProtobufStreamProcessor protobufStreamProcessor = new ProtobufStreamProcessor();
+    ProtobufProtocolMessageHandler protobufProtocolMessageHandler =
+        new ProtobufProtocolMessageHandler();
     InternalCache mockInternalCache = mock(InternalCache.class);
-    protobufStreamProcessor.receiveMessage(inputStream, outputStream,
-        new MessageExecutionContext(mockInternalCache, new NoOpAuthorizer()));
+    protobufProtocolMessageHandler.receiveMessage(inputStream, outputStream,
+        new MessageExecutionContext(mockInternalCache, null, null));
   }
 }
diff --git a/geode-protobuf/src/test/java/org/apache/geode/protocol/protobuf/ProtobufSimpleAuthenticatorJUnitTest.java b/geode-protobuf/src/test/java/org/apache/geode/protocol/protobuf/ProtobufSimpleAuthenticatorJUnitTest.java
index 33424a3..118ea03 100644
--- a/geode-protobuf/src/test/java/org/apache/geode/protocol/protobuf/ProtobufSimpleAuthenticatorJUnitTest.java
+++ b/geode-protobuf/src/test/java/org/apache/geode/protocol/protobuf/ProtobufSimpleAuthenticatorJUnitTest.java
@@ -15,21 +15,7 @@
 
 package org.apache.geode.protocol.protobuf;
 
-import org.apache.geode.examples.security.ExampleSecurityManager;
-import org.apache.geode.management.internal.security.ResourceConstants;
-import org.apache.geode.internal.protocol.protobuf.AuthenticationAPI;
-import org.apache.geode.security.AuthenticationFailedException;
-import org.apache.geode.security.SecurityManager;
-import org.apache.geode.test.junit.categories.UnitTest;
-import org.junit.Before;
-import org.junit.Test;
-import org.junit.experimental.categories.Category;
-
-import java.io.ByteArrayInputStream;
-import java.io.ByteArrayOutputStream;
-import java.io.IOException;
-import java.util.Properties;
-
+import static org.apache.geode.internal.Assert.fail;
 import static org.junit.Assert.assertFalse;
 import static org.junit.Assert.assertTrue;
 import static org.mockito.ArgumentMatchers.any;
@@ -37,6 +23,23 @@ import static org.mockito.ArgumentMatchers.same;
 import static org.mockito.Mockito.mock;
 import static org.mockito.Mockito.when;
 
+import java.io.ByteArrayInputStream;
+import java.io.ByteArrayOutputStream;
+import java.io.IOException;
+import java.util.Properties;
+
+import org.junit.Before;
+import org.junit.Test;
+import org.junit.experimental.categories.Category;
+
+import org.apache.geode.examples.security.ExampleSecurityManager;
+import org.apache.geode.internal.protocol.protobuf.AuthenticationAPI;
+import org.apache.geode.management.internal.security.ResourceConstants;
+import org.apache.geode.protocol.protobuf.security.server.ProtobufSimpleAuthenticator;
+import org.apache.geode.security.AuthenticationFailedException;
+import org.apache.geode.security.SecurityManager;
+import org.apache.geode.test.junit.categories.UnitTest;
+
 @Category(UnitTest.class)
 public class ProtobufSimpleAuthenticatorJUnitTest {
   private static final String TEST_USERNAME = "user1";
@@ -96,8 +99,12 @@ public class ProtobufSimpleAuthenticatorJUnitTest {
     when(mockSecurityManager.authenticate(expectedAuthProperties))
         .thenThrow(new AuthenticationFailedException("BOOM!"));
 
-    protobufSimpleAuthenticator.authenticate(byteArrayInputStream, byteArrayOutputStream,
-        mockSecurityManager);
+    try {
+      protobufSimpleAuthenticator.authenticate(byteArrayInputStream, byteArrayOutputStream,
+          mockSecurityManager);
+      fail("This should throw an AuthenticationFailedException.");
+    } catch (AuthenticationFailedException e) {
+    }
 
     AuthenticationAPI.SimpleAuthenticationResponse simpleAuthenticationResponse =
         getSimpleAuthenticationResponse(byteArrayOutputStream);
diff --git a/geode-protobuf/src/test/java/org/apache/geode/protocol/protobuf/operations/GetAllRequestOperationHandlerJUnitTest.java b/geode-protobuf/src/test/java/org/apache/geode/protocol/protobuf/operations/GetAllRequestOperationHandlerJUnitTest.java
index 0850f25..09f9177 100644
--- a/geode-protobuf/src/test/java/org/apache/geode/protocol/protobuf/operations/GetAllRequestOperationHandlerJUnitTest.java
+++ b/geode-protobuf/src/test/java/org/apache/geode/protocol/protobuf/operations/GetAllRequestOperationHandlerJUnitTest.java
@@ -33,15 +33,14 @@ import org.junit.experimental.categories.Category;
 
 import org.apache.geode.cache.CacheLoaderException;
 import org.apache.geode.cache.Region;
-import org.apache.geode.internal.cache.tier.sockets.MessageExecutionContext;
 import org.apache.geode.internal.exception.InvalidExecutionContextException;
+import org.apache.geode.internal.protocol.MessageExecutionContext;
 import org.apache.geode.internal.protocol.protobuf.BasicTypes;
 import org.apache.geode.internal.protocol.protobuf.RegionAPI;
-import org.apache.geode.protocol.protobuf.Result;
-import org.apache.geode.protocol.protobuf.Success;
 import org.apache.geode.protocol.protobuf.utilities.ProtobufRequestUtilities;
 import org.apache.geode.protocol.protobuf.utilities.ProtobufUtilities;
-import org.apache.geode.security.server.NoOpAuthorizer;
+import org.apache.geode.protocol.responses.Result;
+import org.apache.geode.protocol.responses.Success;
 import org.apache.geode.serialization.exception.UnsupportedEncodingTypeException;
 import org.apache.geode.serialization.registry.exception.CodecAlreadyRegisteredForTypeException;
 import org.apache.geode.serialization.registry.exception.CodecNotRegisteredForTypeException;
@@ -80,9 +79,8 @@ public class GetAllRequestOperationHandlerJUnitTest extends OperationHandlerJUni
   public void processReturnsExpectedValuesForValidKeys()
       throws CodecAlreadyRegisteredForTypeException, UnsupportedEncodingTypeException,
       CodecNotRegisteredForTypeException, InvalidExecutionContextException {
-    Result<RegionAPI.GetAllResponse> result =
-        operationHandler.process(serializationServiceStub, generateTestRequest(true, false),
-            new MessageExecutionContext(cacheStub, new NoOpAuthorizer()));
+    Result<RegionAPI.GetAllResponse> result = operationHandler.process(serializationServiceStub,
+        generateTestRequest(true, false), new MessageExecutionContext(cacheStub, null, null));
 
     assertTrue(result instanceof Success);
 
@@ -101,9 +99,8 @@ public class GetAllRequestOperationHandlerJUnitTest extends OperationHandlerJUni
   @Test
   public void processReturnsNoEntriesForNoKeysRequested() throws UnsupportedEncodingTypeException,
       CodecNotRegisteredForTypeException, InvalidExecutionContextException {
-    Result<RegionAPI.GetAllResponse> result =
-        operationHandler.process(serializationServiceStub, generateTestRequest(false, false),
-            new MessageExecutionContext(cacheStub, new NoOpAuthorizer()));
+    Result<RegionAPI.GetAllResponse> result = operationHandler.process(serializationServiceStub,
+        generateTestRequest(false, false), new MessageExecutionContext(cacheStub, null, null));
 
     assertTrue(result instanceof Success);
 
@@ -120,7 +117,7 @@ public class GetAllRequestOperationHandlerJUnitTest extends OperationHandlerJUni
     RegionAPI.GetAllRequest getAllRequest =
         ProtobufRequestUtilities.createGetAllRequest(TEST_REGION, testKeys);
     Result<RegionAPI.GetAllResponse> result = operationHandler.process(serializationServiceStub,
-        getAllRequest, new MessageExecutionContext(cacheStub, new NoOpAuthorizer()));
+        getAllRequest, new MessageExecutionContext(cacheStub, null, null));
 
     assertTrue(result instanceof Success);
     RegionAPI.GetAllResponse message = result.getMessage();
@@ -134,9 +131,8 @@ public class GetAllRequestOperationHandlerJUnitTest extends OperationHandlerJUni
   @Test
   public void multipleKeysWhereOneThrows() throws UnsupportedEncodingTypeException,
       CodecNotRegisteredForTypeException, InvalidExecutionContextException {
-    Result<RegionAPI.GetAllResponse> result =
-        operationHandler.process(serializationServiceStub, generateTestRequest(true, true),
-            new MessageExecutionContext(cacheStub, new NoOpAuthorizer()));
+    Result<RegionAPI.GetAllResponse> result = operationHandler.process(serializationServiceStub,
+        generateTestRequest(true, true), new MessageExecutionContext(cacheStub, null, null));
 
     assertTrue(result instanceof Success);
 
diff --git a/geode-protobuf/src/test/java/org/apache/geode/protocol/protobuf/operations/GetAvailableServersOperationHandlerJUnitTest.java b/geode-protobuf/src/test/java/org/apache/geode/protocol/protobuf/operations/GetAvailableServersOperationHandlerJUnitTest.java
index 492f19f..a38767a 100644
--- a/geode-protobuf/src/test/java/org/apache/geode/protocol/protobuf/operations/GetAvailableServersOperationHandlerJUnitTest.java
+++ b/geode-protobuf/src/test/java/org/apache/geode/protocol/protobuf/operations/GetAvailableServersOperationHandlerJUnitTest.java
@@ -19,12 +19,12 @@ import org.apache.geode.distributed.internal.LocatorLoadSnapshot;
 import org.apache.geode.distributed.internal.ServerLocation;
 import org.apache.geode.distributed.internal.ServerLocator;
 import org.apache.geode.internal.exception.InvalidExecutionContextException;
-import org.apache.geode.internal.cache.tier.sockets.MessageExecutionContext;
+import org.apache.geode.internal.protocol.MessageExecutionContext;
 import org.apache.geode.internal.protocol.protobuf.BasicTypes;
-import org.apache.geode.protocol.protobuf.Result;
+import org.apache.geode.protocol.responses.Result;
 import org.apache.geode.internal.protocol.protobuf.ServerAPI;
 import org.apache.geode.internal.protocol.protobuf.ServerAPI.GetAvailableServersResponse;
-import org.apache.geode.protocol.protobuf.Success;
+import org.apache.geode.protocol.responses.Success;
 import org.apache.geode.protocol.protobuf.utilities.ProtobufRequestUtilities;
 import org.apache.geode.test.junit.categories.UnitTest;
 import org.junit.Before;
diff --git a/geode-protobuf/src/test/java/org/apache/geode/protocol/protobuf/operations/GetRegionNamesRequestOperationHandlerJUnitTest.java b/geode-protobuf/src/test/java/org/apache/geode/protocol/protobuf/operations/GetRegionNamesRequestOperationHandlerJUnitTest.java
index 0d09148..97c7bf0 100644
--- a/geode-protobuf/src/test/java/org/apache/geode/protocol/protobuf/operations/GetRegionNamesRequestOperationHandlerJUnitTest.java
+++ b/geode-protobuf/src/test/java/org/apache/geode/protocol/protobuf/operations/GetRegionNamesRequestOperationHandlerJUnitTest.java
@@ -27,16 +27,12 @@ import org.junit.experimental.categories.Category;
 
 import org.apache.geode.cache.Cache;
 import org.apache.geode.cache.Region;
-import org.apache.geode.internal.cache.tier.sockets.MessageExecutionContext;
 import org.apache.geode.internal.exception.InvalidExecutionContextException;
+import org.apache.geode.internal.protocol.MessageExecutionContext;
 import org.apache.geode.internal.protocol.protobuf.RegionAPI;
-import org.apache.geode.protocol.protobuf.Result;
-import org.apache.geode.protocol.protobuf.Success;
 import org.apache.geode.protocol.protobuf.utilities.ProtobufRequestUtilities;
-import org.apache.geode.security.server.NoOpAuthorizer;
-import org.apache.geode.serialization.exception.UnsupportedEncodingTypeException;
-import org.apache.geode.serialization.registry.exception.CodecAlreadyRegisteredForTypeException;
-import org.apache.geode.serialization.registry.exception.CodecNotRegisteredForTypeException;
+import org.apache.geode.protocol.responses.Result;
+import org.apache.geode.protocol.responses.Success;
 import org.apache.geode.test.dunit.Assert;
 import org.apache.geode.test.junit.categories.UnitTest;
 
@@ -63,12 +59,10 @@ public class GetRegionNamesRequestOperationHandlerJUnitTest extends OperationHan
   }
 
   @Test
-  public void processReturnsCacheRegions()
-      throws CodecAlreadyRegisteredForTypeException, UnsupportedEncodingTypeException,
-      CodecNotRegisteredForTypeException, InvalidExecutionContextException {
+  public void processReturnsCacheRegions() throws InvalidExecutionContextException {
     Result<RegionAPI.GetRegionNamesResponse> result = operationHandler.process(
         serializationServiceStub, ProtobufRequestUtilities.createGetRegionNamesRequest(),
-        new MessageExecutionContext(cacheStub, new NoOpAuthorizer()));
+        new MessageExecutionContext(cacheStub, null, null));
     Assert.assertTrue(result instanceof Success);
 
     RegionAPI.GetRegionNamesResponse getRegionsResponse = result.getMessage();
@@ -86,15 +80,13 @@ public class GetRegionNamesRequestOperationHandlerJUnitTest extends OperationHan
   }
 
   @Test
-  public void processReturnsNoCacheRegions()
-      throws CodecAlreadyRegisteredForTypeException, UnsupportedEncodingTypeException,
-      CodecNotRegisteredForTypeException, InvalidExecutionContextException {
+  public void processReturnsNoCacheRegions() throws InvalidExecutionContextException {
     Cache emptyCache = mock(Cache.class);;
     when(emptyCache.rootRegions())
         .thenReturn(Collections.unmodifiableSet(new HashSet<Region<String, String>>()));
     Result<RegionAPI.GetRegionNamesResponse> result = operationHandler.process(
         serializationServiceStub, ProtobufRequestUtilities.createGetRegionNamesRequest(),
-        new MessageExecutionContext(emptyCache, new NoOpAuthorizer()));
+        new MessageExecutionContext(emptyCache, null, null));
     Assert.assertTrue(result instanceof Success);
 
     RegionAPI.GetRegionNamesResponse getRegionsResponse = result.getMessage();
diff --git a/geode-protobuf/src/test/java/org/apache/geode/protocol/protobuf/operations/GetRegionRequestOperationHandlerJUnitTest.java b/geode-protobuf/src/test/java/org/apache/geode/protocol/protobuf/operations/GetRegionRequestOperationHandlerJUnitTest.java
index 3458e21..67aa1b5 100644
--- a/geode-protobuf/src/test/java/org/apache/geode/protocol/protobuf/operations/GetRegionRequestOperationHandlerJUnitTest.java
+++ b/geode-protobuf/src/test/java/org/apache/geode/protocol/protobuf/operations/GetRegionRequestOperationHandlerJUnitTest.java
@@ -14,35 +14,31 @@
  */
 package org.apache.geode.protocol.protobuf.operations;
 
+import static org.mockito.Mockito.mock;
+import static org.mockito.Mockito.when;
+
+import java.util.Collections;
+import java.util.HashSet;
+
+import org.junit.Before;
+import org.junit.Test;
+import org.junit.experimental.categories.Category;
+
 import org.apache.geode.cache.Cache;
 import org.apache.geode.cache.DataPolicy;
 import org.apache.geode.cache.Region;
 import org.apache.geode.cache.RegionAttributes;
 import org.apache.geode.cache.Scope;
-import org.apache.geode.internal.cache.tier.sockets.MessageExecutionContext;
 import org.apache.geode.internal.exception.InvalidExecutionContextException;
-import org.apache.geode.protocol.MessageUtil;
+import org.apache.geode.internal.protocol.MessageExecutionContext;
 import org.apache.geode.internal.protocol.protobuf.BasicTypes;
-import org.apache.geode.internal.protocol.protobuf.ClientProtocol;
-import org.apache.geode.protocol.protobuf.Failure;
-import org.apache.geode.protocol.protobuf.ProtocolErrorCode;
 import org.apache.geode.internal.protocol.protobuf.RegionAPI;
-import org.apache.geode.protocol.protobuf.Result;
-import org.apache.geode.security.server.NoOpAuthorizer;
-import org.apache.geode.serialization.exception.UnsupportedEncodingTypeException;
-import org.apache.geode.serialization.registry.exception.CodecAlreadyRegisteredForTypeException;
-import org.apache.geode.serialization.registry.exception.CodecNotRegisteredForTypeException;
+import org.apache.geode.protocol.MessageUtil;
+import org.apache.geode.protocol.protobuf.ProtocolErrorCode;
+import org.apache.geode.protocol.responses.Failure;
+import org.apache.geode.protocol.responses.Result;
 import org.apache.geode.test.dunit.Assert;
 import org.apache.geode.test.junit.categories.UnitTest;
-import org.junit.Before;
-import org.junit.Test;
-import org.junit.experimental.categories.Category;
-
-import java.util.Collections;
-import java.util.HashSet;
-
-import static org.mockito.Mockito.mock;
-import static org.mockito.Mockito.when;
 
 @Category(UnitTest.class)
 public class GetRegionRequestOperationHandlerJUnitTest extends OperationHandlerJUnitTest {
@@ -60,9 +56,7 @@ public class GetRegionRequestOperationHandlerJUnitTest extends OperationHandlerJ
   }
 
   @Test
-  public void processReturnsCacheRegions()
-      throws CodecAlreadyRegisteredForTypeException, UnsupportedEncodingTypeException,
-      CodecNotRegisteredForTypeException, InvalidExecutionContextException {
+  public void processReturnsCacheRegions() throws InvalidExecutionContextException {
 
     RegionAttributes regionAttributesStub = mock(RegionAttributes.class);
     when(cacheStub.getRegion(TEST_REGION1)).thenReturn(region1Stub);
@@ -77,7 +71,7 @@ public class GetRegionRequestOperationHandlerJUnitTest extends OperationHandlerJ
 
     Result<RegionAPI.GetRegionResponse> result = operationHandler.process(serializationServiceStub,
         MessageUtil.makeGetRegionRequest(TEST_REGION1),
-        new MessageExecutionContext(cacheStub, new NoOpAuthorizer()));
+        new MessageExecutionContext(cacheStub, null, null));
     RegionAPI.GetRegionResponse response = result.getMessage();
     BasicTypes.Region region = response.getRegion();
     Assert.assertEquals(TEST_REGION1, region.getName());
@@ -89,21 +83,15 @@ public class GetRegionRequestOperationHandlerJUnitTest extends OperationHandlerJ
     Assert.assertEquals(10, region.getSize());
   }
 
-  private ClientProtocol.Request createRequestMessage(RegionAPI.GetRegionRequest getRegionRequest) {
-    return ClientProtocol.Request.newBuilder().setGetRegionRequest(getRegionRequest).build();
-  }
-
   @Test
-  public void processReturnsNoCacheRegions()
-      throws CodecAlreadyRegisteredForTypeException, UnsupportedEncodingTypeException,
-      CodecNotRegisteredForTypeException, InvalidExecutionContextException {
+  public void processReturnsNoCacheRegions() throws InvalidExecutionContextException {
     Cache emptyCache = mock(Cache.class);
     when(emptyCache.rootRegions())
         .thenReturn(Collections.unmodifiableSet(new HashSet<Region<String, String>>()));
     String unknownRegionName = "UNKNOWN_REGION";
     Result<RegionAPI.GetRegionResponse> result = operationHandler.process(serializationServiceStub,
         MessageUtil.makeGetRegionRequest(unknownRegionName),
-        new MessageExecutionContext(emptyCache, new NoOpAuthorizer()));
+        new MessageExecutionContext(emptyCache, null, null));
     Assert.assertTrue(result instanceof Failure);
     Assert.assertEquals(ProtocolErrorCode.REGION_NOT_FOUND.codeValue,
         result.getErrorMessage().getError().getErrorCode());
diff --git a/geode-protobuf/src/test/java/org/apache/geode/protocol/protobuf/operations/GetRequestOperationHandlerJUnitTest.java b/geode-protobuf/src/test/java/org/apache/geode/protocol/protobuf/operations/GetRequestOperationHandlerJUnitTest.java
index 5bdd5d7..1769a14 100644
--- a/geode-protobuf/src/test/java/org/apache/geode/protocol/protobuf/operations/GetRequestOperationHandlerJUnitTest.java
+++ b/geode-protobuf/src/test/java/org/apache/geode/protocol/protobuf/operations/GetRequestOperationHandlerJUnitTest.java
@@ -14,33 +14,32 @@
  */
 package org.apache.geode.protocol.protobuf.operations;
 
+import static org.mockito.ArgumentMatchers.any;
+import static org.mockito.Mockito.mock;
+import static org.mockito.Mockito.when;
+
+import java.io.UnsupportedEncodingException;
+
 import com.google.protobuf.ByteString;
+import org.junit.Before;
+import org.junit.Test;
+import org.junit.experimental.categories.Category;
+
 import org.apache.geode.cache.Region;
-import org.apache.geode.internal.cache.tier.sockets.MessageExecutionContext;
 import org.apache.geode.internal.exception.InvalidExecutionContextException;
+import org.apache.geode.internal.protocol.MessageExecutionContext;
 import org.apache.geode.internal.protocol.protobuf.BasicTypes;
-import org.apache.geode.protocol.protobuf.Failure;
-import org.apache.geode.protocol.protobuf.ProtocolErrorCode;
 import org.apache.geode.internal.protocol.protobuf.RegionAPI;
-import org.apache.geode.protocol.protobuf.Result;
-import org.apache.geode.protocol.protobuf.Success;
+import org.apache.geode.protocol.protobuf.ProtocolErrorCode;
 import org.apache.geode.protocol.protobuf.utilities.ProtobufRequestUtilities;
 import org.apache.geode.protocol.protobuf.utilities.ProtobufUtilities;
-import org.apache.geode.security.server.NoOpAuthorizer;
+import org.apache.geode.protocol.responses.Failure;
+import org.apache.geode.protocol.responses.Result;
+import org.apache.geode.protocol.responses.Success;
 import org.apache.geode.serialization.exception.UnsupportedEncodingTypeException;
-import org.apache.geode.serialization.registry.exception.CodecAlreadyRegisteredForTypeException;
 import org.apache.geode.serialization.registry.exception.CodecNotRegisteredForTypeException;
 import org.apache.geode.test.dunit.Assert;
 import org.apache.geode.test.junit.categories.UnitTest;
-import org.junit.Before;
-import org.junit.Test;
-import org.junit.experimental.categories.Category;
-
-import java.io.UnsupportedEncodingException;
-
-import static org.mockito.ArgumentMatchers.any;
-import static org.mockito.Mockito.mock;
-import static org.mockito.Mockito.when;
 
 @Category(UnitTest.class)
 public class GetRequestOperationHandlerJUnitTest extends OperationHandlerJUnitTest {
@@ -68,12 +67,11 @@ public class GetRequestOperationHandlerJUnitTest extends OperationHandlerJUnitTe
   }
 
   @Test
-  public void processReturnsTheEncodedValueFromTheRegion()
-      throws CodecAlreadyRegisteredForTypeException, UnsupportedEncodingTypeException,
+  public void processReturnsTheEncodedValueFromTheRegion() throws UnsupportedEncodingTypeException,
       CodecNotRegisteredForTypeException, InvalidExecutionContextException {
     RegionAPI.GetRequest getRequest = generateTestRequest(false, false, false);
     Result<RegionAPI.GetResponse> result = operationHandler.process(serializationServiceStub,
-        getRequest, new MessageExecutionContext(cacheStub, new NoOpAuthorizer()));
+        getRequest, new MessageExecutionContext(cacheStub, null, null));
 
     Assert.assertTrue(result instanceof Success);
     Assert.assertEquals(BasicTypes.EncodedValue.ValueCase.STRINGRESULT,
@@ -84,11 +82,11 @@ public class GetRequestOperationHandlerJUnitTest extends OperationHandlerJUnitTe
 
   @Test
   public void processReturnsUnsucessfulResponseForInvalidRegion()
-      throws CodecAlreadyRegisteredForTypeException, UnsupportedEncodingTypeException,
-      CodecNotRegisteredForTypeException, InvalidExecutionContextException {
+      throws UnsupportedEncodingTypeException, CodecNotRegisteredForTypeException,
+      InvalidExecutionContextException {
     RegionAPI.GetRequest getRequest = generateTestRequest(true, false, false);
     Result<RegionAPI.GetResponse> response = operationHandler.process(serializationServiceStub,
-        getRequest, new MessageExecutionContext(cacheStub, new NoOpAuthorizer()));
+        getRequest, new MessageExecutionContext(cacheStub, null, null));
 
     Assert.assertTrue(response instanceof Failure);
     Assert.assertEquals(ProtocolErrorCode.REGION_NOT_FOUND.codeValue,
@@ -96,32 +94,30 @@ public class GetRequestOperationHandlerJUnitTest extends OperationHandlerJUnitTe
   }
 
   @Test
-  public void processReturnsKeyNotFoundWhenKeyIsNotFound()
-      throws CodecAlreadyRegisteredForTypeException, UnsupportedEncodingTypeException,
+  public void processReturnsKeyNotFoundWhenKeyIsNotFound() throws UnsupportedEncodingTypeException,
       CodecNotRegisteredForTypeException, InvalidExecutionContextException {
     RegionAPI.GetRequest getRequest = generateTestRequest(false, true, false);
     Result<RegionAPI.GetResponse> response = operationHandler.process(serializationServiceStub,
-        getRequest, new MessageExecutionContext(cacheStub, new NoOpAuthorizer()));
+        getRequest, new MessageExecutionContext(cacheStub, null, null));
 
     Assert.assertTrue(response instanceof Success);
   }
 
   @Test
   public void processReturnsLookupFailureWhenKeyFoundWithNoValue()
-      throws CodecAlreadyRegisteredForTypeException, UnsupportedEncodingTypeException,
-      CodecNotRegisteredForTypeException, InvalidExecutionContextException {
+      throws UnsupportedEncodingTypeException, CodecNotRegisteredForTypeException,
+      InvalidExecutionContextException {
     RegionAPI.GetRequest getRequest = generateTestRequest(false, false, true);
     Result<RegionAPI.GetResponse> response = operationHandler.process(serializationServiceStub,
-        getRequest, new MessageExecutionContext(cacheStub, new NoOpAuthorizer()));
+        getRequest, new MessageExecutionContext(cacheStub, null, null));
 
     Assert.assertTrue(response instanceof Success);
   }
 
   @Test
   public void processReturnsErrorWhenUnableToDecodeRequest()
-      throws CodecAlreadyRegisteredForTypeException, UnsupportedEncodingTypeException,
-      CodecNotRegisteredForTypeException, UnsupportedEncodingException,
-      InvalidExecutionContextException {
+      throws UnsupportedEncodingTypeException, CodecNotRegisteredForTypeException,
+      UnsupportedEncodingException, InvalidExecutionContextException {
     CodecNotRegisteredForTypeException exception =
         new CodecNotRegisteredForTypeException("error finding codec for type");
     when(serializationServiceStub.decode(any(), any())).thenThrow(exception);
@@ -134,7 +130,7 @@ public class GetRequestOperationHandlerJUnitTest extends OperationHandlerJUnitTe
     RegionAPI.GetRequest getRequest =
         ProtobufRequestUtilities.createGetRequest(TEST_REGION, encodedKey).getGetRequest();
     Result<RegionAPI.GetResponse> response = operationHandler.process(serializationServiceStub,
-        getRequest, new MessageExecutionContext(cacheStub, new NoOpAuthorizer()));
+        getRequest, new MessageExecutionContext(cacheStub, null, null));
 
     Assert.assertTrue(response instanceof Failure);
     Assert.assertEquals(ProtocolErrorCode.VALUE_ENCODING_ERROR.codeValue,
diff --git a/geode-protobuf/src/test/java/org/apache/geode/protocol/protobuf/operations/PutAllRequestOperationHandlerJUnitTest.java b/geode-protobuf/src/test/java/org/apache/geode/protocol/protobuf/operations/PutAllRequestOperationHandlerJUnitTest.java
index 36a5cf4..18c2ec4 100644
--- a/geode-protobuf/src/test/java/org/apache/geode/protocol/protobuf/operations/PutAllRequestOperationHandlerJUnitTest.java
+++ b/geode-protobuf/src/test/java/org/apache/geode/protocol/protobuf/operations/PutAllRequestOperationHandlerJUnitTest.java
@@ -14,35 +14,35 @@
  */
 package org.apache.geode.protocol.protobuf.operations;
 
+import static org.junit.Assert.assertEquals;
+import static org.junit.Assert.assertTrue;
+import static org.mockito.Mockito.any;
+import static org.mockito.Mockito.mock;
+import static org.mockito.Mockito.times;
+import static org.mockito.Mockito.verify;
+import static org.mockito.Mockito.when;
+
+import java.util.HashSet;
+import java.util.Set;
+
+import org.junit.Before;
+import org.junit.Test;
+import org.junit.experimental.categories.Category;
+
 import org.apache.geode.cache.Region;
-import org.apache.geode.internal.cache.tier.sockets.MessageExecutionContext;
 import org.apache.geode.internal.exception.InvalidExecutionContextException;
+import org.apache.geode.internal.protocol.MessageExecutionContext;
 import org.apache.geode.internal.protocol.protobuf.BasicTypes;
 import org.apache.geode.internal.protocol.protobuf.RegionAPI;
-import org.apache.geode.protocol.protobuf.Result;
-import org.apache.geode.protocol.protobuf.Success;
 import org.apache.geode.protocol.protobuf.utilities.ProtobufRequestUtilities;
 import org.apache.geode.protocol.protobuf.utilities.ProtobufUtilities;
-import org.apache.geode.security.server.NoOpAuthorizer;
+import org.apache.geode.protocol.responses.Result;
+import org.apache.geode.protocol.responses.Success;
 import org.apache.geode.serialization.exception.UnsupportedEncodingTypeException;
 import org.apache.geode.serialization.registry.exception.CodecAlreadyRegisteredForTypeException;
 import org.apache.geode.serialization.registry.exception.CodecNotRegisteredForTypeException;
 import org.apache.geode.test.dunit.Assert;
 import org.apache.geode.test.junit.categories.UnitTest;
-import org.junit.Before;
-import org.junit.Test;
-import org.junit.experimental.categories.Category;
-
-import java.util.HashSet;
-import java.util.Set;
-
-import static org.junit.Assert.assertEquals;
-import static org.junit.Assert.assertTrue;
-import static org.mockito.Mockito.any;
-import static org.mockito.Mockito.mock;
-import static org.mockito.Mockito.times;
-import static org.mockito.Mockito.verify;
-import static org.mockito.Mockito.when;
 
 @Category(UnitTest.class)
 public class PutAllRequestOperationHandlerJUnitTest extends OperationHandlerJUnitTest {
@@ -74,9 +74,8 @@ public class PutAllRequestOperationHandlerJUnitTest extends OperationHandlerJUni
       CodecAlreadyRegisteredForTypeException, InvalidExecutionContextException {
     PutAllRequestOperationHandler operationHandler = new PutAllRequestOperationHandler();
 
-    Result<RegionAPI.PutAllResponse> result =
-        operationHandler.process(serializationServiceStub, generateTestRequest(false, true),
-            new MessageExecutionContext(cacheStub, new NoOpAuthorizer()));
+    Result<RegionAPI.PutAllResponse> result = operationHandler.process(serializationServiceStub,
+        generateTestRequest(false, true), new MessageExecutionContext(cacheStub, null, null));
 
     Assert.assertTrue(result instanceof Success);
 
@@ -89,9 +88,8 @@ public class PutAllRequestOperationHandlerJUnitTest extends OperationHandlerJUni
   public void processWithInvalidEntrySucceedsAndReturnsFailedKey() throws Exception {
     PutAllRequestOperationHandler operationHandler = new PutAllRequestOperationHandler();
 
-    Result<RegionAPI.PutAllResponse> result =
-        operationHandler.process(serializationServiceStub, generateTestRequest(true, true),
-            new MessageExecutionContext(cacheStub, new NoOpAuthorizer()));
+    Result<RegionAPI.PutAllResponse> result = operationHandler.process(serializationServiceStub,
+        generateTestRequest(true, true), new MessageExecutionContext(cacheStub, null, null));
 
     assertTrue(result instanceof Success);
     verify(regionMock).put(TEST_KEY1, TEST_VALUE1);
@@ -109,9 +107,8 @@ public class PutAllRequestOperationHandlerJUnitTest extends OperationHandlerJUni
   public void processWithNoEntriesPasses() throws Exception {
     PutAllRequestOperationHandler operationHandler = new PutAllRequestOperationHandler();
 
-    Result<RegionAPI.PutAllResponse> result =
-        operationHandler.process(serializationServiceStub, generateTestRequest(false, false),
-            new MessageExecutionContext(cacheStub, new NoOpAuthorizer()));
+    Result<RegionAPI.PutAllResponse> result = operationHandler.process(serializationServiceStub,
+        generateTestRequest(false, false), new MessageExecutionContext(cacheStub, null, null));
 
     assertTrue(result instanceof Success);
 
diff --git a/geode-protobuf/src/test/java/org/apache/geode/protocol/protobuf/operations/PutRequestOperationHandlerJUnitTest.java b/geode-protobuf/src/test/java/org/apache/geode/protocol/protobuf/operations/PutRequestOperationHandlerJUnitTest.java
index 5235a90..70b34c3 100644
--- a/geode-protobuf/src/test/java/org/apache/geode/protocol/protobuf/operations/PutRequestOperationHandlerJUnitTest.java
+++ b/geode-protobuf/src/test/java/org/apache/geode/protocol/protobuf/operations/PutRequestOperationHandlerJUnitTest.java
@@ -14,37 +14,36 @@
  */
 package org.apache.geode.protocol.protobuf.operations;
 
+import static org.junit.Assert.assertEquals;
+import static org.junit.Assert.assertTrue;
+import static org.mockito.Mockito.any;
+import static org.mockito.Mockito.anyString;
+import static org.mockito.Mockito.mock;
+import static org.mockito.Mockito.times;
+import static org.mockito.Mockito.verify;
+import static org.mockito.Mockito.when;
+
+import java.io.UnsupportedEncodingException;
+
 import com.google.protobuf.ByteString;
+import org.junit.Before;
+import org.junit.Test;
+import org.junit.experimental.categories.Category;
+
 import org.apache.geode.cache.Region;
-import org.apache.geode.internal.cache.tier.sockets.MessageExecutionContext;
 import org.apache.geode.internal.exception.InvalidExecutionContextException;
+import org.apache.geode.internal.protocol.MessageExecutionContext;
 import org.apache.geode.internal.protocol.protobuf.BasicTypes;
-import org.apache.geode.protocol.protobuf.Failure;
-import org.apache.geode.protocol.protobuf.ProtocolErrorCode;
 import org.apache.geode.internal.protocol.protobuf.RegionAPI;
-import org.apache.geode.protocol.protobuf.Result;
-import org.apache.geode.protocol.protobuf.Success;
+import org.apache.geode.protocol.protobuf.ProtocolErrorCode;
 import org.apache.geode.protocol.protobuf.utilities.ProtobufRequestUtilities;
 import org.apache.geode.protocol.protobuf.utilities.ProtobufUtilities;
-import org.apache.geode.security.server.NoOpAuthorizer;
+import org.apache.geode.protocol.responses.Failure;
+import org.apache.geode.protocol.responses.Result;
+import org.apache.geode.protocol.responses.Success;
 import org.apache.geode.serialization.exception.UnsupportedEncodingTypeException;
-import org.apache.geode.serialization.registry.exception.CodecAlreadyRegisteredForTypeException;
 import org.apache.geode.serialization.registry.exception.CodecNotRegisteredForTypeException;
 import org.apache.geode.test.junit.categories.UnitTest;
-import org.junit.Before;
-import org.junit.Test;
-import org.junit.experimental.categories.Category;
-
-import java.io.UnsupportedEncodingException;
-
-import static org.junit.Assert.assertEquals;
-import static org.junit.Assert.assertTrue;
-import static org.mockito.Mockito.any;
-import static org.mockito.Mockito.anyString;
-import static org.mockito.Mockito.mock;
-import static org.mockito.Mockito.times;
-import static org.mockito.Mockito.verify;
-import static org.mockito.Mockito.when;
 
 @Category(UnitTest.class)
 public class PutRequestOperationHandlerJUnitTest extends OperationHandlerJUnitTest {
@@ -64,12 +63,11 @@ public class PutRequestOperationHandlerJUnitTest extends OperationHandlerJUnitTe
   }
 
   @Test
-  public void test_puttingTheEncodedEntryIntoRegion()
-      throws UnsupportedEncodingTypeException, CodecNotRegisteredForTypeException,
-      CodecAlreadyRegisteredForTypeException, InvalidExecutionContextException {
+  public void test_puttingTheEncodedEntryIntoRegion() throws UnsupportedEncodingTypeException,
+      CodecNotRegisteredForTypeException, InvalidExecutionContextException {
     PutRequestOperationHandler operationHandler = new PutRequestOperationHandler();
     Result<RegionAPI.PutResponse> result = operationHandler.process(serializationServiceStub,
-        generateTestRequest(), new MessageExecutionContext(cacheStub, new NoOpAuthorizer()));
+        generateTestRequest(), new MessageExecutionContext(cacheStub, null, null));
 
     assertTrue(result instanceof Success);
 
@@ -78,8 +76,8 @@ public class PutRequestOperationHandlerJUnitTest extends OperationHandlerJUnitTe
   }
 
   @Test
-  public void test_invalidEncodingType() throws CodecAlreadyRegisteredForTypeException,
-      UnsupportedEncodingTypeException, CodecNotRegisteredForTypeException,
+  public void test_invalidEncodingType()
+      throws UnsupportedEncodingTypeException, CodecNotRegisteredForTypeException,
       UnsupportedEncodingException, InvalidExecutionContextException {
     String exceptionText = "unsupported type!";
     UnsupportedEncodingTypeException exception =
@@ -100,7 +98,7 @@ public class PutRequestOperationHandlerJUnitTest extends OperationHandlerJUnitTe
     RegionAPI.PutRequest putRequest =
         ProtobufRequestUtilities.createPutRequest(TEST_REGION, testEntry).getPutRequest();
     Result<RegionAPI.PutResponse> result = operationHandler.process(serializationServiceStub,
-        putRequest, new MessageExecutionContext(cacheStub, new NoOpAuthorizer()));
+        putRequest, new MessageExecutionContext(cacheStub, null, null));
 
     assertTrue(result instanceof Failure);
     assertEquals(ProtocolErrorCode.VALUE_ENCODING_ERROR.codeValue,
@@ -108,13 +106,12 @@ public class PutRequestOperationHandlerJUnitTest extends OperationHandlerJUnitTe
   }
 
   @Test
-  public void test_RegionNotFound()
-      throws CodecAlreadyRegisteredForTypeException, UnsupportedEncodingTypeException,
+  public void test_RegionNotFound() throws UnsupportedEncodingTypeException,
       CodecNotRegisteredForTypeException, InvalidExecutionContextException {
     when(cacheStub.getRegion(TEST_REGION)).thenReturn(null);
     PutRequestOperationHandler operationHandler = new PutRequestOperationHandler();
     Result<RegionAPI.PutResponse> result = operationHandler.process(serializationServiceStub,
-        generateTestRequest(), new MessageExecutionContext(cacheStub, new NoOpAuthorizer()));
+        generateTestRequest(), new MessageExecutionContext(cacheStub, null, null));
 
     assertTrue(result instanceof Failure);
     assertEquals(ProtocolErrorCode.REGION_NOT_FOUND.codeValue,
@@ -122,14 +119,13 @@ public class PutRequestOperationHandlerJUnitTest extends OperationHandlerJUnitTe
   }
 
   @Test
-  public void test_RegionThrowsClasscastException()
-      throws CodecAlreadyRegisteredForTypeException, UnsupportedEncodingTypeException,
+  public void test_RegionThrowsClasscastException() throws UnsupportedEncodingTypeException,
       CodecNotRegisteredForTypeException, InvalidExecutionContextException {
     when(regionMock.put(any(), any())).thenThrow(ClassCastException.class);
 
     PutRequestOperationHandler operationHandler = new PutRequestOperationHandler();
     Result<RegionAPI.PutResponse> result = operationHandler.process(serializationServiceStub,
-        generateTestRequest(), new MessageExecutionContext(cacheStub, new NoOpAuthorizer()));
+        generateTestRequest(), new MessageExecutionContext(cacheStub, null, null));
 
     assertTrue(result instanceof Failure);
     assertEquals(ProtocolErrorCode.CONSTRAINT_VIOLATION.codeValue,
diff --git a/geode-protobuf/src/test/java/org/apache/geode/protocol/protobuf/operations/RemoveRequestOperationHandlerJUnitTest.java b/geode-protobuf/src/test/java/org/apache/geode/protocol/protobuf/operations/RemoveRequestOperationHandlerJUnitTest.java
index a5bde46..db77184 100644
--- a/geode-protobuf/src/test/java/org/apache/geode/protocol/protobuf/operations/RemoveRequestOperationHandlerJUnitTest.java
+++ b/geode-protobuf/src/test/java/org/apache/geode/protocol/protobuf/operations/RemoveRequestOperationHandlerJUnitTest.java
@@ -14,36 +14,35 @@
  */
 package org.apache.geode.protocol.protobuf.operations;
 
+import static org.junit.Assert.assertEquals;
+import static org.junit.Assert.assertTrue;
+import static org.mockito.ArgumentMatchers.any;
+import static org.mockito.Mockito.mock;
+import static org.mockito.Mockito.verify;
+import static org.mockito.Mockito.when;
+
+import java.io.UnsupportedEncodingException;
+
 import com.google.protobuf.ByteString;
+import org.junit.Before;
+import org.junit.Test;
+import org.junit.experimental.categories.Category;
+
 import org.apache.geode.cache.Region;
-import org.apache.geode.internal.cache.tier.sockets.MessageExecutionContext;
 import org.apache.geode.internal.exception.InvalidExecutionContextException;
+import org.apache.geode.internal.protocol.MessageExecutionContext;
 import org.apache.geode.internal.protocol.protobuf.BasicTypes;
 import org.apache.geode.internal.protocol.protobuf.ClientProtocol;
-import org.apache.geode.protocol.protobuf.Failure;
-import org.apache.geode.protocol.protobuf.ProtocolErrorCode;
 import org.apache.geode.internal.protocol.protobuf.RegionAPI;
-import org.apache.geode.protocol.protobuf.Result;
-import org.apache.geode.protocol.protobuf.Success;
+import org.apache.geode.protocol.protobuf.ProtocolErrorCode;
 import org.apache.geode.protocol.protobuf.utilities.ProtobufRequestUtilities;
 import org.apache.geode.protocol.protobuf.utilities.ProtobufUtilities;
-import org.apache.geode.security.server.NoOpAuthorizer;
+import org.apache.geode.protocol.responses.Failure;
+import org.apache.geode.protocol.responses.Result;
+import org.apache.geode.protocol.responses.Success;
 import org.apache.geode.serialization.exception.UnsupportedEncodingTypeException;
-import org.apache.geode.serialization.registry.exception.CodecAlreadyRegisteredForTypeException;
 import org.apache.geode.serialization.registry.exception.CodecNotRegisteredForTypeException;
 import org.apache.geode.test.junit.categories.UnitTest;
-import org.junit.Before;
-import org.junit.Test;
-import org.junit.experimental.categories.Category;
-
-import java.io.UnsupportedEncodingException;
-
-import static org.junit.Assert.assertEquals;
-import static org.junit.Assert.assertTrue;
-import static org.mockito.ArgumentMatchers.any;
-import static org.mockito.Mockito.mock;
-import static org.mockito.Mockito.verify;
-import static org.mockito.Mockito.when;
 
 @Category(UnitTest.class)
 public class RemoveRequestOperationHandlerJUnitTest extends OperationHandlerJUnitTest {
@@ -70,11 +69,11 @@ public class RemoveRequestOperationHandlerJUnitTest extends OperationHandlerJUni
 
   @Test
   public void processValidKeyRemovesTheEntryAndReturnSuccess()
-      throws CodecAlreadyRegisteredForTypeException, UnsupportedEncodingTypeException,
-      CodecNotRegisteredForTypeException, InvalidExecutionContextException {
+      throws UnsupportedEncodingTypeException, CodecNotRegisteredForTypeException,
+      InvalidExecutionContextException {
     RegionAPI.RemoveRequest removeRequest = generateTestRequest(false, false).getRemoveRequest();
     Result<RegionAPI.RemoveResponse> result = operationHandler.process(serializationServiceStub,
-        removeRequest, new MessageExecutionContext(cacheStub, new NoOpAuthorizer()));
+        removeRequest, new MessageExecutionContext(cacheStub, null, null));
 
     assertTrue(result instanceof Success);
     verify(regionStub).remove(TEST_KEY);
@@ -82,11 +81,11 @@ public class RemoveRequestOperationHandlerJUnitTest extends OperationHandlerJUni
 
   @Test
   public void processReturnsUnsucessfulResponseForInvalidRegion()
-      throws CodecAlreadyRegisteredForTypeException, UnsupportedEncodingTypeException,
-      CodecNotRegisteredForTypeException, InvalidExecutionContextException {
+      throws UnsupportedEncodingTypeException, CodecNotRegisteredForTypeException,
+      InvalidExecutionContextException {
     RegionAPI.RemoveRequest removeRequest = generateTestRequest(true, false).getRemoveRequest();
     Result<RegionAPI.RemoveResponse> result = operationHandler.process(serializationServiceStub,
-        removeRequest, new MessageExecutionContext(cacheStub, new NoOpAuthorizer()));
+        removeRequest, new MessageExecutionContext(cacheStub, null, null));
 
     assertTrue(result instanceof Failure);
     assertEquals(ProtocolErrorCode.REGION_NOT_FOUND.codeValue,
@@ -94,21 +93,19 @@ public class RemoveRequestOperationHandlerJUnitTest extends OperationHandlerJUni
   }
 
   @Test
-  public void processReturnsSuccessWhenKeyIsNotFound()
-      throws CodecAlreadyRegisteredForTypeException, UnsupportedEncodingTypeException,
+  public void processReturnsSuccessWhenKeyIsNotFound() throws UnsupportedEncodingTypeException,
       CodecNotRegisteredForTypeException, InvalidExecutionContextException {
     RegionAPI.RemoveRequest removeRequest = generateTestRequest(false, true).getRemoveRequest();
     Result<RegionAPI.RemoveResponse> result = operationHandler.process(serializationServiceStub,
-        removeRequest, new MessageExecutionContext(cacheStub, new NoOpAuthorizer()));
+        removeRequest, new MessageExecutionContext(cacheStub, null, null));
 
     assertTrue(result instanceof Success);
   }
 
   @Test
   public void processReturnsErrorWhenUnableToDecodeRequest()
-      throws CodecAlreadyRegisteredForTypeException, UnsupportedEncodingTypeException,
-      CodecNotRegisteredForTypeException, UnsupportedEncodingException,
-      InvalidExecutionContextException {
+      throws UnsupportedEncodingTypeException, CodecNotRegisteredForTypeException,
+      UnsupportedEncodingException, InvalidExecutionContextException {
     CodecNotRegisteredForTypeException exception =
         new CodecNotRegisteredForTypeException("error finding codec for type");
     when(serializationServiceStub.decode(any(), any())).thenThrow(exception);
@@ -122,7 +119,7 @@ public class RemoveRequestOperationHandlerJUnitTest extends OperationHandlerJUni
     RegionAPI.RemoveRequest removeRequest =
         ProtobufRequestUtilities.createRemoveRequest(TEST_REGION, encodedKey).getRemoveRequest();;
     Result<RegionAPI.RemoveResponse> result = operationHandler.process(serializationServiceStub,
-        removeRequest, new MessageExecutionContext(cacheStub, new NoOpAuthorizer()));
+        removeRequest, new MessageExecutionContext(cacheStub, null, null));
 
     assertTrue(result instanceof Failure);
     assertEquals(ProtocolErrorCode.VALUE_ENCODING_ERROR.codeValue,
diff --git a/geode-protobuf/src/test/java/org/apache/geode/protocol/protobuf/utilities/ProtobufUtilitiesJUnitTest.java b/geode-protobuf/src/test/java/org/apache/geode/protocol/protobuf/utilities/ProtobufUtilitiesJUnitTest.java
index 14b4b77..339e4b7 100644
--- a/geode-protobuf/src/test/java/org/apache/geode/protocol/protobuf/utilities/ProtobufUtilitiesJUnitTest.java
+++ b/geode-protobuf/src/test/java/org/apache/geode/protocol/protobuf/utilities/ProtobufUtilitiesJUnitTest.java
@@ -15,17 +15,18 @@
 
 package org.apache.geode.protocol.protobuf.utilities;
 
+import static org.junit.Assert.assertArrayEquals;
+import static org.junit.Assert.assertEquals;
+
+import java.nio.charset.Charset;
+
 import com.google.protobuf.ByteString;
-import org.apache.geode.internal.protocol.protobuf.BasicTypes;
-import org.apache.geode.protocol.protobuf.utilities.exception.UnknownProtobufPrimitiveType;
-import org.apache.geode.test.junit.categories.UnitTest;
 import org.junit.Test;
 import org.junit.experimental.categories.Category;
 
-import java.nio.charset.Charset;
-
-import static org.junit.Assert.assertArrayEquals;
-import static org.junit.Assert.assertEquals;
+import org.apache.geode.internal.protocol.protobuf.BasicTypes;
+import org.apache.geode.protocol.exception.UnknownProtobufPrimitiveType;
+import org.apache.geode.test.junit.categories.UnitTest;
 
 @Category(UnitTest.class)
 public class ProtobufUtilitiesJUnitTest {
diff --git a/geode-protobuf/src/test/java/org/apache/geode/protocol/AuthenticationIntegrationTest.java b/geode-protobuf/src/test/java/org/apache/geode/protocol/security/server/AuthenticationIntegrationTest.java
similarity index 99%
rename from geode-protobuf/src/test/java/org/apache/geode/protocol/AuthenticationIntegrationTest.java
rename to geode-protobuf/src/test/java/org/apache/geode/protocol/security/server/AuthenticationIntegrationTest.java
index 02a053f..6406431 100644
--- a/geode-protobuf/src/test/java/org/apache/geode/protocol/AuthenticationIntegrationTest.java
+++ b/geode-protobuf/src/test/java/org/apache/geode/protocol/security/server/AuthenticationIntegrationTest.java
@@ -12,41 +12,42 @@
  * or implied. See the License for the specific language governing permissions and limitations under
  * the License.
  */
-package org.apache.geode.protocol;
+package org.apache.geode.protocol.security.server;
+
+import static org.junit.Assert.assertEquals;
+import static org.junit.Assert.assertTrue;
+import static org.mockito.ArgumentMatchers.any;
+import static org.mockito.ArgumentMatchers.same;
+import static org.mockito.Mockito.mock;
+import static org.mockito.Mockito.when;
+
+import java.io.IOException;
+import java.io.InputStream;
+import java.io.OutputStream;
+import java.net.Socket;
+import java.util.Properties;
+import java.util.concurrent.TimeUnit;
+
+import org.awaitility.Awaitility;
+import org.junit.After;
+import org.junit.Rule;
+import org.junit.Test;
+import org.junit.contrib.java.lang.system.RestoreSystemProperties;
+import org.junit.experimental.categories.Category;
 
 import org.apache.geode.cache.Cache;
 import org.apache.geode.cache.CacheFactory;
 import org.apache.geode.cache.server.CacheServer;
 import org.apache.geode.distributed.ConfigurationProperties;
 import org.apache.geode.internal.AvailablePortHelper;
-import org.apache.geode.management.internal.security.ResourceConstants;
 import org.apache.geode.internal.protocol.protobuf.AuthenticationAPI;
 import org.apache.geode.internal.protocol.protobuf.ClientProtocol;
 import org.apache.geode.internal.protocol.protobuf.RegionAPI;
+import org.apache.geode.management.internal.security.ResourceConstants;
 import org.apache.geode.protocol.protobuf.serializer.ProtobufProtocolSerializer;
 import org.apache.geode.security.SecurityManager;
 import org.apache.geode.serialization.registry.exception.CodecAlreadyRegisteredForTypeException;
 import org.apache.geode.test.junit.categories.IntegrationTest;
-import org.awaitility.Awaitility;
-import org.junit.After;
-import org.junit.Rule;
-import org.junit.Test;
-import org.junit.contrib.java.lang.system.RestoreSystemProperties;
-import org.junit.experimental.categories.Category;
-
-import java.io.IOException;
-import java.io.InputStream;
-import java.io.OutputStream;
-import java.net.Socket;
-import java.util.Properties;
-import java.util.concurrent.TimeUnit;
-
-import static org.junit.Assert.assertEquals;
-import static org.junit.Assert.assertTrue;
-import static org.mockito.ArgumentMatchers.any;
-import static org.mockito.ArgumentMatchers.same;
-import static org.mockito.Mockito.mock;
-import static org.mockito.Mockito.when;
 
 @Category(IntegrationTest.class)
 public class AuthenticationIntegrationTest {
diff --git a/geode-protobuf/src/test/java/org/apache/geode/protocol/AuthorizationIntegrationTest.java b/geode-protobuf/src/test/java/org/apache/geode/protocol/security/server/AuthorizationIntegrationTest.java
similarity index 99%
rename from geode-protobuf/src/test/java/org/apache/geode/protocol/AuthorizationIntegrationTest.java
rename to geode-protobuf/src/test/java/org/apache/geode/protocol/security/server/AuthorizationIntegrationTest.java
index 47bdbf5..af93924 100644
--- a/geode-protobuf/src/test/java/org/apache/geode/protocol/AuthorizationIntegrationTest.java
+++ b/geode-protobuf/src/test/java/org/apache/geode/protocol/security/server/AuthorizationIntegrationTest.java
@@ -12,7 +12,7 @@
  * or implied. See the License for the specific language governing permissions and limitations under
  * the License.
  */
-package org.apache.geode.protocol;
+package org.apache.geode.protocol.security.server;
 
 import static org.junit.Assert.assertEquals;
 import static org.junit.Assert.assertTrue;
@@ -73,7 +73,6 @@ public class AuthorizationIntegrationTest {
   private ProtobufProtocolSerializer protobufProtocolSerializer;
   private Object securityPrincipal;
   private SecurityManager mockSecurityManager;
-  private String testRegion;
   public static final ResourcePermission READ_PERMISSION =
       new ResourcePermission(ResourcePermission.Resource.DATA, ResourcePermission.Operation.READ);
   public static final ResourcePermission WRITE_PERMISSION =
@@ -81,6 +80,10 @@ public class AuthorizationIntegrationTest {
 
   @Before
   public void setUp() throws IOException, CodecAlreadyRegisteredForTypeException {
+
+    System.setProperty("geode.feature-protobuf-protocol", "true");
+    System.setProperty("geode.protocol-authentication-mode", "SIMPLE");
+
     Properties expectedAuthProperties = new Properties();
     expectedAuthProperties.setProperty(ResourceConstants.USER_NAME, TEST_USERNAME);
     expectedAuthProperties.setProperty(ResourceConstants.PASSWORD, TEST_PASSWORD);
@@ -103,8 +106,6 @@ public class AuthorizationIntegrationTest {
 
     cache.createRegionFactory().create(TEST_REGION);
 
-    System.setProperty("geode.feature-protobuf-protocol", "true");
-    System.setProperty("geode.protocol-authentication-mode", "SIMPLE");
     socket = new Socket("localhost", cacheServerPort);
 
     Awaitility.await().atMost(5, TimeUnit.SECONDS).until(socket::isConnected);

-- 
To stop receiving notification emails like this one, please contact
"commits@geode.apache.org" <commits@geode.apache.org>.

Mime
View raw message