@@ -203,52 +203,6 @@ public TenantSecurityClient build() throws Exception {
203203 }
204204 }
205205
206- /**
207- * Constructor for TenantSecurityClient class that allows for modifying the random number
208- * generator used for encryption.
209- *
210- * @param tspDomain Domain where the Tenant Security Proxy is running.
211- * @param apiKey Key to use for requests to the Tenant Security Proxy.
212- * @param requestThreadSize Number of threads to use for fixed-size web request thread pool
213- * @param aesThreadSize Number of threads to use for fixed-size AES operations threadpool
214- * @param randomGen Instance of SecureRandom to use for PRNG when performing encryption
215- * operations.
216- * @param timeout Request to TSP read and connect timeout in ms.
217- * @throws Exception If the provided domain is invalid or the provided SecureRandom instance is
218- * not set.
219- */
220- public TenantSecurityClient (String tspDomain , String apiKey , int requestThreadSize ,
221- int aesThreadSize , SecureRandom randomGen , int timeout , boolean allowInsecureHttp )
222- throws Exception {
223- // Use the URL class to validate the form of the provided TSP domain URL
224- new URL (tspDomain );
225- if (apiKey == null || apiKey .isEmpty ()) {
226- throw new IllegalArgumentException ("No value provided for apiKey!" );
227- }
228- if (randomGen == null ) {
229- throw new IllegalArgumentException ("No value provided for random number generator!" );
230- }
231- if (requestThreadSize < 1 ) {
232- throw new IllegalArgumentException (
233- "Value provided for request threadpool size must be greater than 0!" );
234- }
235- if (aesThreadSize < 1 ) {
236- throw new IllegalArgumentException (
237- "Value provided for AES threadpool size must be greater than 0!" );
238- }
239- if (timeout < 1 ) {
240- throw new IllegalArgumentException ("Value provided for timeout must be greater than 0!" );
241- }
242-
243- this .encryptionExecutor = Executors .newFixedThreadPool (aesThreadSize );
244- this .encryptionService =
245- new TenantSecurityRequest (tspDomain , apiKey , requestThreadSize , timeout );
246- this .deterministicClient =
247- new DeterministicTenantSecurityClient (this .encryptionExecutor , this .encryptionService );
248-
249- this .secureRandom = randomGen ;
250- }
251-
252206 public void close () throws IOException {
253207 this .encryptionService .close ();
254208 this .encryptionExecutor .shutdown ();
0 commit comments