diff --git a/cdap-app-fabric/src/main/java/io/cdap/cdap/app/guice/AppFabricServiceRuntimeModule.java b/cdap-app-fabric/src/main/java/io/cdap/cdap/app/guice/AppFabricServiceRuntimeModule.java index 24c028a0471d..7773653fec5f 100644 --- a/cdap-app-fabric/src/main/java/io/cdap/cdap/app/guice/AppFabricServiceRuntimeModule.java +++ b/cdap-app-fabric/src/main/java/io/cdap/cdap/app/guice/AppFabricServiceRuntimeModule.java @@ -152,7 +152,7 @@ import io.cdap.cdap.scheduler.CoreSchedulerService; import io.cdap.cdap.scheduler.Scheduler; import io.cdap.cdap.securestore.spi.SecretStore; -import io.cdap.cdap.security.encryption.guice.DataStorageAeadEncryptionModule; +import io.cdap.cdap.common.encryption.guice.DataStorageAeadEncryptionModule; import io.cdap.cdap.security.impersonation.DefaultOwnerAdmin; import io.cdap.cdap.security.impersonation.DefaultUGIProvider; import io.cdap.cdap.security.impersonation.OwnerAdmin; diff --git a/cdap-app-fabric/src/main/java/io/cdap/cdap/internal/credential/CredentialIdentityStore.java b/cdap-app-fabric/src/main/java/io/cdap/cdap/internal/credential/CredentialIdentityStore.java index f7a83d1c63cf..55c184a884e0 100644 --- a/cdap-app-fabric/src/main/java/io/cdap/cdap/internal/credential/CredentialIdentityStore.java +++ b/cdap-app-fabric/src/main/java/io/cdap/cdap/internal/credential/CredentialIdentityStore.java @@ -21,8 +21,8 @@ import io.cdap.cdap.proto.credential.CredentialIdentity; import io.cdap.cdap.proto.id.CredentialIdentityId; import io.cdap.cdap.proto.id.CredentialProfileId; -import io.cdap.cdap.security.encryption.AeadCipher; -import io.cdap.cdap.security.encryption.guice.DataStorageAeadEncryptionModule; +import io.cdap.cdap.common.encryption.AeadCipher; +import io.cdap.cdap.common.encryption.guice.DataStorageAeadEncryptionModule; import io.cdap.cdap.security.spi.encryption.CipherException; import io.cdap.cdap.spi.data.StructuredRow; import io.cdap.cdap.spi.data.StructuredTable; diff --git a/cdap-app-fabric/src/main/java/io/cdap/cdap/internal/credential/CredentialProfileStore.java b/cdap-app-fabric/src/main/java/io/cdap/cdap/internal/credential/CredentialProfileStore.java index 4580a543c517..4243cfe8640c 100644 --- a/cdap-app-fabric/src/main/java/io/cdap/cdap/internal/credential/CredentialProfileStore.java +++ b/cdap-app-fabric/src/main/java/io/cdap/cdap/internal/credential/CredentialProfileStore.java @@ -21,8 +21,8 @@ import io.cdap.cdap.common.NotFoundException; import io.cdap.cdap.proto.credential.CredentialProfile; import io.cdap.cdap.proto.id.CredentialProfileId; -import io.cdap.cdap.security.encryption.AeadCipher; -import io.cdap.cdap.security.encryption.guice.DataStorageAeadEncryptionModule; +import io.cdap.cdap.common.encryption.AeadCipher; +import io.cdap.cdap.common.encryption.guice.DataStorageAeadEncryptionModule; import io.cdap.cdap.security.spi.encryption.CipherException; import io.cdap.cdap.spi.data.StructuredRow; import io.cdap.cdap.spi.data.StructuredTable; diff --git a/cdap-app-fabric/src/test/java/io/cdap/cdap/internal/credential/CredentialProviderTestBase.java b/cdap-app-fabric/src/test/java/io/cdap/cdap/internal/credential/CredentialProviderTestBase.java index 2fee6d287100..14dbb88a42d9 100644 --- a/cdap-app-fabric/src/test/java/io/cdap/cdap/internal/credential/CredentialProviderTestBase.java +++ b/cdap-app-fabric/src/test/java/io/cdap/cdap/internal/credential/CredentialProviderTestBase.java @@ -36,7 +36,7 @@ import io.cdap.cdap.proto.credential.ProvisionedCredential; import io.cdap.cdap.proto.id.CredentialProfileId; import io.cdap.cdap.security.authorization.AuthorizationEnforcementModule; -import io.cdap.cdap.security.encryption.NoOpAeadCipher; +import io.cdap.cdap.common.encryption.NoOpAeadCipher; import io.cdap.cdap.security.spi.authorization.ContextAccessEnforcer; import io.cdap.cdap.security.spi.credential.CredentialProvider; import io.cdap.cdap.security.spi.credential.ProfileValidationException; diff --git a/cdap-security/src/main/java/io/cdap/cdap/security/encryption/AeadCipher.java b/cdap-common/src/main/java/io/cdap/cdap/common/encryption/AeadCipher.java similarity index 98% rename from cdap-security/src/main/java/io/cdap/cdap/security/encryption/AeadCipher.java rename to cdap-common/src/main/java/io/cdap/cdap/common/encryption/AeadCipher.java index f4635e7ac21a..fc1c5e462504 100644 --- a/cdap-security/src/main/java/io/cdap/cdap/security/encryption/AeadCipher.java +++ b/cdap-common/src/main/java/io/cdap/cdap/common/encryption/AeadCipher.java @@ -14,7 +14,7 @@ * the License. */ -package io.cdap.cdap.security.encryption; +package io.cdap.cdap.common.encryption; import io.cdap.cdap.security.spi.encryption.CipherException; import io.cdap.cdap.security.spi.encryption.CipherOperationException; diff --git a/cdap-security/src/main/java/io/cdap/cdap/security/encryption/NoOpAeadCipher.java b/cdap-common/src/main/java/io/cdap/cdap/common/encryption/NoOpAeadCipher.java similarity index 95% rename from cdap-security/src/main/java/io/cdap/cdap/security/encryption/NoOpAeadCipher.java rename to cdap-common/src/main/java/io/cdap/cdap/common/encryption/NoOpAeadCipher.java index ca2e4ff99604..4d9d39af9a7f 100644 --- a/cdap-security/src/main/java/io/cdap/cdap/security/encryption/NoOpAeadCipher.java +++ b/cdap-common/src/main/java/io/cdap/cdap/common/encryption/NoOpAeadCipher.java @@ -14,7 +14,7 @@ * the License. */ -package io.cdap.cdap.security.encryption; +package io.cdap.cdap.common.encryption; /** * Performs no encryption. diff --git a/cdap-security/src/main/java/io/cdap/cdap/security/encryption/guice/AbstractAeadCipherProvider.java b/cdap-common/src/main/java/io/cdap/cdap/common/encryption/guice/AbstractAeadCipherProvider.java similarity index 93% rename from cdap-security/src/main/java/io/cdap/cdap/security/encryption/guice/AbstractAeadCipherProvider.java rename to cdap-common/src/main/java/io/cdap/cdap/common/encryption/guice/AbstractAeadCipherProvider.java index e10966733ab5..4ec633569893 100644 --- a/cdap-security/src/main/java/io/cdap/cdap/security/encryption/guice/AbstractAeadCipherProvider.java +++ b/cdap-common/src/main/java/io/cdap/cdap/common/encryption/guice/AbstractAeadCipherProvider.java @@ -14,12 +14,12 @@ * the License. */ -package io.cdap.cdap.security.encryption.guice; +package io.cdap.cdap.common.encryption.guice; import io.cdap.cdap.common.conf.CConfiguration; import io.cdap.cdap.common.conf.SConfiguration; -import io.cdap.cdap.security.encryption.AeadCipher; -import io.cdap.cdap.security.encryption.NoOpAeadCipher; +import io.cdap.cdap.common.encryption.AeadCipher; +import io.cdap.cdap.common.encryption.NoOpAeadCipher; import java.util.Map; import javax.inject.Provider; diff --git a/cdap-security/src/main/java/io/cdap/cdap/security/encryption/guice/AeadCipherCryptorExtensionLoader.java b/cdap-common/src/main/java/io/cdap/cdap/common/encryption/guice/AeadCipherCryptorExtensionLoader.java similarity index 98% rename from cdap-security/src/main/java/io/cdap/cdap/security/encryption/guice/AeadCipherCryptorExtensionLoader.java rename to cdap-common/src/main/java/io/cdap/cdap/common/encryption/guice/AeadCipherCryptorExtensionLoader.java index 4a76529eee70..753ff255e98a 100644 --- a/cdap-security/src/main/java/io/cdap/cdap/security/encryption/guice/AeadCipherCryptorExtensionLoader.java +++ b/cdap-common/src/main/java/io/cdap/cdap/common/encryption/guice/AeadCipherCryptorExtensionLoader.java @@ -14,7 +14,7 @@ * the License. */ -package io.cdap.cdap.security.encryption.guice; +package io.cdap.cdap.common.encryption.guice; import com.google.inject.Inject; import io.cdap.cdap.common.conf.CConfiguration; diff --git a/cdap-security/src/main/java/io/cdap/cdap/security/encryption/guice/DataStorageAeadCipherProvider.java b/cdap-common/src/main/java/io/cdap/cdap/common/encryption/guice/DataStorageAeadCipherProvider.java similarity index 94% rename from cdap-security/src/main/java/io/cdap/cdap/security/encryption/guice/DataStorageAeadCipherProvider.java rename to cdap-common/src/main/java/io/cdap/cdap/common/encryption/guice/DataStorageAeadCipherProvider.java index b89bcd692689..059eae834a37 100644 --- a/cdap-security/src/main/java/io/cdap/cdap/security/encryption/guice/DataStorageAeadCipherProvider.java +++ b/cdap-common/src/main/java/io/cdap/cdap/common/encryption/guice/DataStorageAeadCipherProvider.java @@ -14,12 +14,12 @@ * the License. */ -package io.cdap.cdap.security.encryption.guice; +package io.cdap.cdap.common.encryption.guice; import io.cdap.cdap.common.conf.CConfiguration; import io.cdap.cdap.common.conf.Constants.Security.Encryption; import io.cdap.cdap.common.conf.SConfiguration; -import io.cdap.cdap.security.encryption.AeadCipher; +import io.cdap.cdap.common.encryption.AeadCipher; import java.util.Map; import javax.inject.Inject; diff --git a/cdap-security/src/main/java/io/cdap/cdap/security/encryption/guice/DataStorageAeadEncryptionModule.java b/cdap-common/src/main/java/io/cdap/cdap/common/encryption/guice/DataStorageAeadEncryptionModule.java similarity index 93% rename from cdap-security/src/main/java/io/cdap/cdap/security/encryption/guice/DataStorageAeadEncryptionModule.java rename to cdap-common/src/main/java/io/cdap/cdap/common/encryption/guice/DataStorageAeadEncryptionModule.java index d202f320910e..7462b2b25273 100644 --- a/cdap-security/src/main/java/io/cdap/cdap/security/encryption/guice/DataStorageAeadEncryptionModule.java +++ b/cdap-common/src/main/java/io/cdap/cdap/common/encryption/guice/DataStorageAeadEncryptionModule.java @@ -14,12 +14,12 @@ * the License. */ -package io.cdap.cdap.security.encryption.guice; +package io.cdap.cdap.common.encryption.guice; import com.google.inject.PrivateModule; import com.google.inject.Scopes; import com.google.inject.name.Names; -import io.cdap.cdap.security.encryption.AeadCipher; +import io.cdap.cdap.common.encryption.AeadCipher; /** * Guice module for encryption bindings for data storage encryption. diff --git a/cdap-security/src/main/java/io/cdap/cdap/security/encryption/guice/LazyDelegateAeadCipher.java b/cdap-common/src/main/java/io/cdap/cdap/common/encryption/guice/LazyDelegateAeadCipher.java similarity index 96% rename from cdap-security/src/main/java/io/cdap/cdap/security/encryption/guice/LazyDelegateAeadCipher.java rename to cdap-common/src/main/java/io/cdap/cdap/common/encryption/guice/LazyDelegateAeadCipher.java index 20a79630f078..754c9e33390d 100644 --- a/cdap-security/src/main/java/io/cdap/cdap/security/encryption/guice/LazyDelegateAeadCipher.java +++ b/cdap-common/src/main/java/io/cdap/cdap/common/encryption/guice/LazyDelegateAeadCipher.java @@ -14,9 +14,9 @@ * the License. */ -package io.cdap.cdap.security.encryption.guice; +package io.cdap.cdap.common.encryption.guice; -import io.cdap.cdap.security.encryption.AeadCipher; +import io.cdap.cdap.common.encryption.AeadCipher; import io.cdap.cdap.security.spi.encryption.AeadCipherContext; import io.cdap.cdap.security.spi.encryption.AeadCipherCryptor; import io.cdap.cdap.security.spi.encryption.CipherException; diff --git a/cdap-security/src/main/java/io/cdap/cdap/security/encryption/guice/UserCredentialAeadCipherProvider.java b/cdap-common/src/main/java/io/cdap/cdap/common/encryption/guice/UserCredentialAeadCipherProvider.java similarity index 96% rename from cdap-security/src/main/java/io/cdap/cdap/security/encryption/guice/UserCredentialAeadCipherProvider.java rename to cdap-common/src/main/java/io/cdap/cdap/common/encryption/guice/UserCredentialAeadCipherProvider.java index 3cf19eccae8d..f081f5ac31b6 100644 --- a/cdap-security/src/main/java/io/cdap/cdap/security/encryption/guice/UserCredentialAeadCipherProvider.java +++ b/cdap-common/src/main/java/io/cdap/cdap/common/encryption/guice/UserCredentialAeadCipherProvider.java @@ -14,13 +14,13 @@ * the License. */ -package io.cdap.cdap.security.encryption.guice; +package io.cdap.cdap.common.encryption.guice; import io.cdap.cdap.common.conf.CConfiguration; import io.cdap.cdap.common.conf.Constants.Security.Authentication; import io.cdap.cdap.common.conf.Constants.Security.Encryption; import io.cdap.cdap.common.conf.SConfiguration; -import io.cdap.cdap.security.encryption.AeadCipher; +import io.cdap.cdap.common.encryption.AeadCipher; import java.util.Map; import javax.inject.Inject; diff --git a/cdap-security/src/main/java/io/cdap/cdap/security/encryption/guice/UserCredentialAeadEncryptionModule.java b/cdap-common/src/main/java/io/cdap/cdap/common/encryption/guice/UserCredentialAeadEncryptionModule.java similarity index 93% rename from cdap-security/src/main/java/io/cdap/cdap/security/encryption/guice/UserCredentialAeadEncryptionModule.java rename to cdap-common/src/main/java/io/cdap/cdap/common/encryption/guice/UserCredentialAeadEncryptionModule.java index 3e75a0128874..09e64843ce3d 100644 --- a/cdap-security/src/main/java/io/cdap/cdap/security/encryption/guice/UserCredentialAeadEncryptionModule.java +++ b/cdap-common/src/main/java/io/cdap/cdap/common/encryption/guice/UserCredentialAeadEncryptionModule.java @@ -14,12 +14,12 @@ * the License. */ -package io.cdap.cdap.security.encryption.guice; +package io.cdap.cdap.common.encryption.guice; import com.google.inject.PrivateModule; import com.google.inject.Scopes; import com.google.inject.name.Names; -import io.cdap.cdap.security.encryption.AeadCipher; +import io.cdap.cdap.common.encryption.AeadCipher; /** * Guice module for encryption bindings for user credential encryption. diff --git a/cdap-security/src/test/java/io/cdap/cdap/security/encryption/DataStorageAeadEncryptionModuleTest.java b/cdap-common/src/test/java/io/cdap/cdap/common/encryption/DataStorageAeadEncryptionModuleTest.java similarity index 90% rename from cdap-security/src/test/java/io/cdap/cdap/security/encryption/DataStorageAeadEncryptionModuleTest.java rename to cdap-common/src/test/java/io/cdap/cdap/common/encryption/DataStorageAeadEncryptionModuleTest.java index 14aace96fc39..57aae29ad5e7 100644 --- a/cdap-security/src/test/java/io/cdap/cdap/security/encryption/DataStorageAeadEncryptionModuleTest.java +++ b/cdap-common/src/test/java/io/cdap/cdap/common/encryption/DataStorageAeadEncryptionModuleTest.java @@ -14,14 +14,14 @@ * the License. */ -package io.cdap.cdap.security.encryption; +package io.cdap.cdap.common.encryption; import com.google.inject.Guice; import com.google.inject.Injector; import com.google.inject.Key; import com.google.inject.name.Names; import io.cdap.cdap.common.guice.ConfigModule; -import io.cdap.cdap.security.encryption.guice.DataStorageAeadEncryptionModule; +import io.cdap.cdap.common.encryption.guice.DataStorageAeadEncryptionModule; import org.junit.Test; /** diff --git a/cdap-security/src/test/java/io/cdap/cdap/security/encryption/FakeAeadCipher.java b/cdap-common/src/test/java/io/cdap/cdap/common/encryption/FakeAeadCipher.java similarity index 99% rename from cdap-security/src/test/java/io/cdap/cdap/security/encryption/FakeAeadCipher.java rename to cdap-common/src/test/java/io/cdap/cdap/common/encryption/FakeAeadCipher.java index 41001e7321af..156aa899c066 100644 --- a/cdap-security/src/test/java/io/cdap/cdap/security/encryption/FakeAeadCipher.java +++ b/cdap-common/src/test/java/io/cdap/cdap/common/encryption/FakeAeadCipher.java @@ -14,7 +14,7 @@ * the License. */ -package io.cdap.cdap.security.encryption; +package io.cdap.cdap.common.encryption; import com.google.gson.Gson; import com.google.gson.JsonSyntaxException; diff --git a/cdap-security/src/test/java/io/cdap/cdap/security/encryption/FakeAeadCipherTest.java b/cdap-common/src/test/java/io/cdap/cdap/common/encryption/FakeAeadCipherTest.java similarity index 98% rename from cdap-security/src/test/java/io/cdap/cdap/security/encryption/FakeAeadCipherTest.java rename to cdap-common/src/test/java/io/cdap/cdap/common/encryption/FakeAeadCipherTest.java index 23e4359cf3ea..9c1bd43afff5 100644 --- a/cdap-security/src/test/java/io/cdap/cdap/security/encryption/FakeAeadCipherTest.java +++ b/cdap-common/src/test/java/io/cdap/cdap/common/encryption/FakeAeadCipherTest.java @@ -14,7 +14,7 @@ * the License. */ -package io.cdap.cdap.security.encryption; +package io.cdap.cdap.common.encryption; import com.google.gson.Gson; import io.cdap.cdap.security.spi.encryption.CipherOperationException; diff --git a/cdap-security/src/test/java/io/cdap/cdap/security/encryption/UserCredentialAeadEncryptionModuleTest.java b/cdap-common/src/test/java/io/cdap/cdap/common/encryption/UserCredentialAeadEncryptionModuleTest.java similarity index 90% rename from cdap-security/src/test/java/io/cdap/cdap/security/encryption/UserCredentialAeadEncryptionModuleTest.java rename to cdap-common/src/test/java/io/cdap/cdap/common/encryption/UserCredentialAeadEncryptionModuleTest.java index 0f9b529cd395..221591d2c355 100644 --- a/cdap-security/src/test/java/io/cdap/cdap/security/encryption/UserCredentialAeadEncryptionModuleTest.java +++ b/cdap-common/src/test/java/io/cdap/cdap/common/encryption/UserCredentialAeadEncryptionModuleTest.java @@ -14,14 +14,14 @@ * the License. */ -package io.cdap.cdap.security.encryption; +package io.cdap.cdap.common.encryption; import com.google.inject.Guice; import com.google.inject.Injector; import com.google.inject.Key; import com.google.inject.name.Names; import io.cdap.cdap.common.guice.ConfigModule; -import io.cdap.cdap.security.encryption.guice.UserCredentialAeadEncryptionModule; +import io.cdap.cdap.common.encryption.guice.UserCredentialAeadEncryptionModule; import org.junit.Test; /** diff --git a/cdap-security/src/test/java/io/cdap/cdap/security/encryption/guice/LazyDelegateAeadCipherTest.java b/cdap-common/src/test/java/io/cdap/cdap/common/encryption/guice/LazyDelegateAeadCipherTest.java similarity index 98% rename from cdap-security/src/test/java/io/cdap/cdap/security/encryption/guice/LazyDelegateAeadCipherTest.java rename to cdap-common/src/test/java/io/cdap/cdap/common/encryption/guice/LazyDelegateAeadCipherTest.java index 9e8d6ec9a4c1..50c0ae5d6703 100644 --- a/cdap-security/src/test/java/io/cdap/cdap/security/encryption/guice/LazyDelegateAeadCipherTest.java +++ b/cdap-common/src/test/java/io/cdap/cdap/common/encryption/guice/LazyDelegateAeadCipherTest.java @@ -14,7 +14,7 @@ * the License. */ -package io.cdap.cdap.security.encryption.guice; +package io.cdap.cdap.common.encryption.guice; import static org.mockito.Matchers.any; import static org.mockito.Matchers.argThat; diff --git a/cdap-gateway/src/main/java/io/cdap/cdap/gateway/router/NettyRouter.java b/cdap-gateway/src/main/java/io/cdap/cdap/gateway/router/NettyRouter.java index 415fe221a988..b580ace78dbe 100644 --- a/cdap-gateway/src/main/java/io/cdap/cdap/gateway/router/NettyRouter.java +++ b/cdap-gateway/src/main/java/io/cdap/cdap/gateway/router/NettyRouter.java @@ -35,8 +35,8 @@ import io.cdap.cdap.gateway.router.handlers.HttpStatusRequestHandler; import io.cdap.cdap.security.auth.TokenValidator; import io.cdap.cdap.security.auth.UserIdentityExtractor; -import io.cdap.cdap.security.encryption.AeadCipher; -import io.cdap.cdap.security.encryption.guice.UserCredentialAeadEncryptionModule; +import io.cdap.cdap.common.encryption.AeadCipher; +import io.cdap.cdap.common.encryption.guice.UserCredentialAeadEncryptionModule; import io.cdap.cdap.security.impersonation.SecurityUtil; import io.cdap.http.SSLConfig; import io.cdap.http.SSLHandlerFactory; diff --git a/cdap-gateway/src/main/java/io/cdap/cdap/gateway/router/RouterMain.java b/cdap-gateway/src/main/java/io/cdap/cdap/gateway/router/RouterMain.java index d3348d0d4e83..6be7b1450593 100644 --- a/cdap-gateway/src/main/java/io/cdap/cdap/gateway/router/RouterMain.java +++ b/cdap-gateway/src/main/java/io/cdap/cdap/gateway/router/RouterMain.java @@ -29,7 +29,7 @@ import io.cdap.cdap.common.guice.ZkClientModule; import io.cdap.cdap.common.guice.ZkDiscoveryModule; import io.cdap.cdap.common.runtime.DaemonMain; -import io.cdap.cdap.security.encryption.guice.UserCredentialAeadEncryptionModule; +import io.cdap.cdap.common.encryption.guice.UserCredentialAeadEncryptionModule; import io.cdap.cdap.security.guice.CoreSecurityRuntimeModule; import io.cdap.cdap.security.guice.ExternalAuthenticationModule; import io.cdap.cdap.security.impersonation.SecurityUtil; diff --git a/cdap-gateway/src/main/java/io/cdap/cdap/gateway/router/handlers/AuthenticationHandler.java b/cdap-gateway/src/main/java/io/cdap/cdap/gateway/router/handlers/AuthenticationHandler.java index f408378e5650..878824d78392 100644 --- a/cdap-gateway/src/main/java/io/cdap/cdap/gateway/router/handlers/AuthenticationHandler.java +++ b/cdap-gateway/src/main/java/io/cdap/cdap/gateway/router/handlers/AuthenticationHandler.java @@ -32,7 +32,7 @@ import io.cdap.cdap.security.auth.UserIdentityExtractionState; import io.cdap.cdap.security.auth.UserIdentityExtractor; import io.cdap.cdap.security.auth.UserIdentityPair; -import io.cdap.cdap.security.encryption.AeadCipher; +import io.cdap.cdap.common.encryption.AeadCipher; import io.cdap.cdap.security.server.GrantAccessToken; import io.cdap.cdap.security.spi.encryption.CipherException; import io.netty.buffer.ByteBuf; diff --git a/cdap-gateway/src/test/java/io/cdap/cdap/gateway/router/AuditLogTest.java b/cdap-gateway/src/test/java/io/cdap/cdap/gateway/router/AuditLogTest.java index 90fefaf6971f..b238cd5b447e 100644 --- a/cdap-gateway/src/test/java/io/cdap/cdap/gateway/router/AuditLogTest.java +++ b/cdap-gateway/src/test/java/io/cdap/cdap/gateway/router/AuditLogTest.java @@ -31,7 +31,7 @@ import io.cdap.cdap.common.security.AuditDetail; import io.cdap.cdap.common.security.AuditPolicy; import io.cdap.cdap.security.auth.TokenValidator; -import io.cdap.cdap.security.encryption.NoOpAeadCipher; +import io.cdap.cdap.common.encryption.NoOpAeadCipher; import io.cdap.http.AbstractHttpHandler; import io.cdap.http.HttpResponder; import io.cdap.http.NettyHttpService; diff --git a/cdap-gateway/src/test/java/io/cdap/cdap/gateway/router/AuthServerAnnounceTest.java b/cdap-gateway/src/test/java/io/cdap/cdap/gateway/router/AuthServerAnnounceTest.java index 79591fd481e9..2a94b742bb40 100644 --- a/cdap-gateway/src/test/java/io/cdap/cdap/gateway/router/AuthServerAnnounceTest.java +++ b/cdap-gateway/src/test/java/io/cdap/cdap/gateway/router/AuthServerAnnounceTest.java @@ -31,7 +31,7 @@ import io.cdap.cdap.security.auth.AuthenticationMode; import io.cdap.cdap.security.auth.TokenValidator; import io.cdap.cdap.security.auth.UserIdentityExtractor; -import io.cdap.cdap.security.encryption.NoOpAeadCipher; +import io.cdap.cdap.common.encryption.NoOpAeadCipher; import io.cdap.cdap.security.guice.CoreSecurityRuntimeModule; import io.cdap.cdap.security.guice.ExternalAuthenticationModule; import io.cdap.cdap.security.server.GrantAccessToken; diff --git a/cdap-gateway/src/test/java/io/cdap/cdap/gateway/router/ConfigBasedRequestBlockingTest.java b/cdap-gateway/src/test/java/io/cdap/cdap/gateway/router/ConfigBasedRequestBlockingTest.java index a8c09c9535c2..860ff7cd640e 100644 --- a/cdap-gateway/src/test/java/io/cdap/cdap/gateway/router/ConfigBasedRequestBlockingTest.java +++ b/cdap-gateway/src/test/java/io/cdap/cdap/gateway/router/ConfigBasedRequestBlockingTest.java @@ -22,7 +22,7 @@ import io.cdap.cdap.common.conf.Constants; import io.cdap.cdap.common.conf.SConfiguration; import io.cdap.cdap.security.auth.TokenValidator; -import io.cdap.cdap.security.encryption.NoOpAeadCipher; +import io.cdap.cdap.common.encryption.NoOpAeadCipher; import io.cdap.http.NettyHttpService; import io.netty.handler.codec.http.HttpResponseStatus; import java.io.IOException; diff --git a/cdap-gateway/src/test/java/io/cdap/cdap/gateway/router/NettyRouterHttpTest.java b/cdap-gateway/src/test/java/io/cdap/cdap/gateway/router/NettyRouterHttpTest.java index 1d0589db02c6..2ec4365c3c30 100644 --- a/cdap-gateway/src/test/java/io/cdap/cdap/gateway/router/NettyRouterHttpTest.java +++ b/cdap-gateway/src/test/java/io/cdap/cdap/gateway/router/NettyRouterHttpTest.java @@ -28,7 +28,7 @@ import io.cdap.cdap.common.guice.InMemoryDiscoveryModule; import io.cdap.cdap.internal.guice.AppFabricTestModule; import io.cdap.cdap.security.auth.UserIdentityExtractor; -import io.cdap.cdap.security.encryption.NoOpAeadCipher; +import io.cdap.cdap.common.encryption.NoOpAeadCipher; import io.cdap.cdap.security.guice.CoreSecurityRuntimeModule; import io.cdap.cdap.security.guice.ExternalAuthenticationModule; import java.net.InetSocketAddress; diff --git a/cdap-gateway/src/test/java/io/cdap/cdap/gateway/router/NettyRouterHttpsTest.java b/cdap-gateway/src/test/java/io/cdap/cdap/gateway/router/NettyRouterHttpsTest.java index 7411f3c43db9..233e71e37fd0 100644 --- a/cdap-gateway/src/test/java/io/cdap/cdap/gateway/router/NettyRouterHttpsTest.java +++ b/cdap-gateway/src/test/java/io/cdap/cdap/gateway/router/NettyRouterHttpsTest.java @@ -30,7 +30,7 @@ import io.cdap.cdap.common.security.KeyStoresTest; import io.cdap.cdap.internal.guice.AppFabricTestModule; import io.cdap.cdap.security.auth.UserIdentityExtractor; -import io.cdap.cdap.security.encryption.NoOpAeadCipher; +import io.cdap.cdap.common.encryption.NoOpAeadCipher; import io.cdap.cdap.security.guice.CoreSecurityRuntimeModule; import io.cdap.cdap.security.guice.ExternalAuthenticationModule; import io.cdap.common.http.HttpRequests; diff --git a/cdap-gateway/src/test/java/io/cdap/cdap/gateway/router/NettyRouterTestBase.java b/cdap-gateway/src/test/java/io/cdap/cdap/gateway/router/NettyRouterTestBase.java index a264d964b9e7..e3e37000c78f 100644 --- a/cdap-gateway/src/test/java/io/cdap/cdap/gateway/router/NettyRouterTestBase.java +++ b/cdap-gateway/src/test/java/io/cdap/cdap/gateway/router/NettyRouterTestBase.java @@ -38,7 +38,7 @@ import io.cdap.cdap.common.discovery.ResolvingDiscoverable; import io.cdap.cdap.common.http.AbstractBodyConsumer; import io.cdap.cdap.security.auth.TokenValidator; -import io.cdap.cdap.security.encryption.NoOpAeadCipher; +import io.cdap.cdap.common.encryption.NoOpAeadCipher; import io.cdap.http.AbstractHttpHandler; import io.cdap.http.BodyConsumer; import io.cdap.http.ChannelPipelineModifier; diff --git a/cdap-gateway/src/test/java/io/cdap/cdap/gateway/router/RouterResource.java b/cdap-gateway/src/test/java/io/cdap/cdap/gateway/router/RouterResource.java index 90c2f640469d..3d3a74038712 100644 --- a/cdap-gateway/src/test/java/io/cdap/cdap/gateway/router/RouterResource.java +++ b/cdap-gateway/src/test/java/io/cdap/cdap/gateway/router/RouterResource.java @@ -26,7 +26,7 @@ import io.cdap.cdap.internal.guice.AppFabricTestModule; import io.cdap.cdap.security.auth.TokenValidator; import io.cdap.cdap.security.auth.UserIdentityExtractor; -import io.cdap.cdap.security.encryption.NoOpAeadCipher; +import io.cdap.cdap.common.encryption.NoOpAeadCipher; import io.cdap.cdap.security.guice.CoreSecurityRuntimeModule; import io.cdap.cdap.security.guice.ExternalAuthenticationModule; import java.net.InetSocketAddress; diff --git a/cdap-gateway/src/test/java/io/cdap/cdap/gateway/router/RoutingToDataSetsTest.java b/cdap-gateway/src/test/java/io/cdap/cdap/gateway/router/RoutingToDataSetsTest.java index 14c9a561d09c..f5dd4ac39036 100644 --- a/cdap-gateway/src/test/java/io/cdap/cdap/gateway/router/RoutingToDataSetsTest.java +++ b/cdap-gateway/src/test/java/io/cdap/cdap/gateway/router/RoutingToDataSetsTest.java @@ -28,7 +28,7 @@ import io.cdap.cdap.common.utils.Networks; import io.cdap.cdap.internal.guice.AppFabricTestModule; import io.cdap.cdap.security.auth.UserIdentityExtractor; -import io.cdap.cdap.security.encryption.NoOpAeadCipher; +import io.cdap.cdap.common.encryption.NoOpAeadCipher; import io.cdap.cdap.security.guice.CoreSecurityRuntimeModule; import io.cdap.cdap.security.guice.ExternalAuthenticationModule; import io.cdap.http.AbstractHttpHandler; diff --git a/cdap-master/src/main/java/io/cdap/cdap/master/environment/k8s/RouterServiceMain.java b/cdap-master/src/main/java/io/cdap/cdap/master/environment/k8s/RouterServiceMain.java index b02ed6dd5cdf..4e384e8802ae 100644 --- a/cdap-master/src/main/java/io/cdap/cdap/master/environment/k8s/RouterServiceMain.java +++ b/cdap-master/src/main/java/io/cdap/cdap/master/environment/k8s/RouterServiceMain.java @@ -32,7 +32,7 @@ import io.cdap.cdap.master.spi.environment.MasterEnvironmentContext; import io.cdap.cdap.messaging.guice.MessagingServiceModule; import io.cdap.cdap.proto.id.NamespaceId; -import io.cdap.cdap.security.encryption.guice.UserCredentialAeadEncryptionModule; +import io.cdap.cdap.common.encryption.guice.UserCredentialAeadEncryptionModule; import io.cdap.cdap.security.guice.ExternalAuthenticationModule; import java.util.ArrayList; import java.util.List; diff --git a/cdap-security/src/main/java/io/cdap/cdap/security/authorization/AuthorizationEnforcementModule.java b/cdap-security/src/main/java/io/cdap/cdap/security/authorization/AuthorizationEnforcementModule.java index 965938587f90..e10d516bf328 100644 --- a/cdap-security/src/main/java/io/cdap/cdap/security/authorization/AuthorizationEnforcementModule.java +++ b/cdap-security/src/main/java/io/cdap/cdap/security/authorization/AuthorizationEnforcementModule.java @@ -26,7 +26,7 @@ import io.cdap.cdap.proto.element.EntityType; import io.cdap.cdap.proto.id.EntityId; import io.cdap.cdap.proto.security.Permission; -import io.cdap.cdap.security.encryption.guice.UserCredentialAeadEncryptionModule; +import io.cdap.cdap.common.encryption.guice.UserCredentialAeadEncryptionModule; import io.cdap.cdap.security.impersonation.SecurityUtil; import io.cdap.cdap.security.spi.authorization.AccessEnforcer; import io.cdap.cdap.security.spi.authorization.ContextAccessEnforcer; diff --git a/cdap-security/src/main/java/io/cdap/cdap/security/authorization/DefaultAccessEnforcer.java b/cdap-security/src/main/java/io/cdap/cdap/security/authorization/DefaultAccessEnforcer.java index d9e88dad3e61..7bce74b9d6aa 100644 --- a/cdap-security/src/main/java/io/cdap/cdap/security/authorization/DefaultAccessEnforcer.java +++ b/cdap-security/src/main/java/io/cdap/cdap/security/authorization/DefaultAccessEnforcer.java @@ -36,18 +36,16 @@ import io.cdap.cdap.proto.security.Permission; import io.cdap.cdap.proto.security.Principal; import io.cdap.cdap.proto.security.Role; -import io.cdap.cdap.security.encryption.AeadCipher; -import io.cdap.cdap.security.encryption.guice.UserCredentialAeadEncryptionModule; +import io.cdap.cdap.common.encryption.AeadCipher; +import io.cdap.cdap.common.encryption.guice.UserCredentialAeadEncryptionModule; import io.cdap.cdap.security.impersonation.SecurityUtil; import io.cdap.cdap.security.spi.authentication.AuthenticationContext; import io.cdap.cdap.security.spi.authorization.AccessEnforcer; -import io.cdap.cdap.security.spi.authorization.AuditLogContext; import io.cdap.cdap.security.spi.authorization.AuthorizationResponse; import io.cdap.cdap.security.spi.authorization.AuthorizedResult; import io.cdap.cdap.security.spi.encryption.CipherException; import java.util.Collections; import java.util.HashSet; -import java.util.List; import java.util.Map; import java.util.Set; import java.util.concurrent.TimeUnit; diff --git a/cdap-security/src/test/java/io/cdap/cdap/security/authorization/DefaultAccessEnforcerTest.java b/cdap-security/src/test/java/io/cdap/cdap/security/authorization/DefaultAccessEnforcerTest.java index 345e097272c6..2dddf3d9578f 100644 --- a/cdap-security/src/test/java/io/cdap/cdap/security/authorization/DefaultAccessEnforcerTest.java +++ b/cdap-security/src/test/java/io/cdap/cdap/security/authorization/DefaultAccessEnforcerTest.java @@ -47,7 +47,7 @@ import io.cdap.cdap.proto.security.StandardPermission; import io.cdap.cdap.security.auth.CipherException; import io.cdap.cdap.security.auth.context.AuthenticationTestContext; -import io.cdap.cdap.security.encryption.FakeAeadCipher; +import io.cdap.cdap.common.encryption.FakeAeadCipher; import io.cdap.cdap.security.spi.authentication.AuthenticationContext; import io.cdap.cdap.security.spi.authorization.AccessControllerSpi; import io.cdap.cdap.security.spi.authorization.AccessEnforcer;