@@ -66,6 +66,14 @@ namespace Aws
66
66
S3EncryptionClientBase (const std::shared_ptr<Aws::Utils::Crypto::EncryptionMaterials>& encryptionMaterials, const Aws::S3Encryption::CryptoConfiguration& cryptoConfig,
67
67
const std::shared_ptr<Aws::Auth::AWSCredentialsProvider>& credentialsProvider, const Aws::Client::ClientConfiguration& clientConfiguration = Aws::Client::ClientConfiguration());
68
68
69
+ /*
70
+ * Initialize the S3EncryptionClientBase with encryption materials, crypto configuration, and a s3 client factory.
71
+ * The factory will be used to create the underlying S3 Client.
72
+ */
73
+ S3EncryptionClientBase (const std::shared_ptr<Aws::Utils::Crypto::EncryptionMaterials>& encryptionMaterials,
74
+ const Aws::S3Encryption::CryptoConfiguration& cryptoConfig,
75
+ const std::function<Aws::UniquePtr<Aws::S3::S3Client> ()>& s3ClientFactory);
76
+
69
77
S3EncryptionClientBase (const S3EncryptionClientBase&) = delete ;
70
78
S3EncryptionClientBase& operator =(const S3EncryptionClientBase&) = delete ;
71
79
@@ -180,6 +188,17 @@ namespace Aws
180
188
Init (cryptoConfig);
181
189
}
182
190
191
+ /*
192
+ * Initialize the S3 Encryption Client V2 with crypto configuration v2, and a s3 client factory.
193
+ * The factory will be used to create the underlying S3 Client.
194
+ */
195
+ S3EncryptionClientV2 (const Aws::S3Encryption::CryptoConfigurationV2& cryptoConfig,
196
+ const std::function<Aws::UniquePtr<Aws::S3::S3Client> ()>& s3ClientFactory)
197
+ : S3EncryptionClientBase(cryptoConfig.GetEncryptionMaterials(), CryptoConfiguration(), s3ClientFactory)
198
+ {
199
+ Init (cryptoConfig);
200
+ }
201
+
183
202
S3EncryptionClientV2 (const S3EncryptionClientV2&) = delete ;
184
203
S3EncryptionClientV2& operator =(const S3EncryptionClientV2&) = delete ;
185
204
0 commit comments