From 2da3a9e98e5d129d4507b5db01bba5ee9558d28e Mon Sep 17 00:00:00 2001 From: Marcelo Vanzin Date: Wed, 2 Sep 2015 12:53:24 -0700 Subject: [SPARK-10004] [SHUFFLE] Perform auth checks when clients read shuffle data. To correctly isolate applications, when requests to read shuffle data arrive at the shuffle service, proper authorization checks need to be performed. This change makes sure that only the application that created the shuffle data can read from it. Such checks are only enabled when "spark.authenticate" is enabled, otherwise there's no secure way to make sure that the client is really who it says it is. Author: Marcelo Vanzin Closes #8218 from vanzin/SPARK-10004. --- network/common/pom.xml | 4 + .../spark/network/client/TransportClient.java | 22 +++ .../spark/network/sasl/SaslClientBootstrap.java | 2 + .../apache/spark/network/sasl/SaslRpcHandler.java | 1 + .../network/server/OneForOneStreamManager.java | 31 +++- .../apache/spark/network/server/StreamManager.java | 9 ++ .../network/server/TransportRequestHandler.java | 1 + .../shuffle/ExternalShuffleBlockHandler.java | 16 +- .../spark/network/sasl/SaslIntegrationSuite.java | 163 +++++++++++++++++---- .../shuffle/ExternalShuffleBlockHandlerSuite.java | 2 +- 10 files changed, 217 insertions(+), 34 deletions(-) (limited to 'network') diff --git a/network/common/pom.xml b/network/common/pom.xml index 7dc3068ab8..4141fcb826 100644 --- a/network/common/pom.xml +++ b/network/common/pom.xml @@ -48,6 +48,10 @@ slf4j-api provided + + com.google.code.findbugs + jsr305 +