diff --git a/src/main/java/com/box/sdkgen/box/jwtauth/JWTConfig.java b/src/main/java/com/box/sdkgen/box/jwtauth/JWTConfig.java index 622010952..e49816431 100644 --- a/src/main/java/com/box/sdkgen/box/jwtauth/JWTConfig.java +++ b/src/main/java/com/box/sdkgen/box/jwtauth/JWTConfig.java @@ -260,6 +260,16 @@ public Builder( String jwtKeyId, String privateKey, String privateKeyPassphrase) { + this(clientId, clientSecret, jwtKeyId, privateKey, privateKeyPassphrase, new DefaultPrivateKeyDecryptor()); + } + + public Builder( + String clientId, + String clientSecret, + String jwtKeyId, + String privateKey, + String privateKeyPassphrase, + PrivateKeyDecryptor privateKeyDecryptor) { this.clientId = clientId; this.clientSecret = clientSecret; this.jwtKeyId = jwtKeyId; @@ -267,7 +277,7 @@ public Builder( this.privateKeyPassphrase = privateKeyPassphrase; this.algorithm = new EnumWrapper(JwtAlgorithm.RS256); this.tokenStorage = new InMemoryTokenStorage(); - this.privateKeyDecryptor = new DefaultPrivateKeyDecryptor(); + this.privateKeyDecryptor = privateKeyDecryptor; } public Builder enterpriseId(String enterpriseId) {