| 171 | } |
| 172 | |
| 173 | std::shared_ptr<FileDecryptionProperties> CryptoFactory::GetFileDecryptionProperties( |
| 174 | const KmsConnectionConfig& kms_connection_config, |
| 175 | const DecryptionConfiguration& decryption_config, const std::string& file_path, |
| 176 | const std::shared_ptr<::arrow::fs::FileSystem>& file_system) { |
| 177 | auto key_retriever = std::make_shared<FileKeyUnwrapper>( |
| 178 | key_toolkit_, kms_connection_config, decryption_config.cache_lifetime_seconds, |
| 179 | file_path, file_system); |
| 180 | |
| 181 | return FileDecryptionProperties::Builder() |
| 182 | .key_retriever(std::move(key_retriever)) |
| 183 | ->plaintext_files_allowed() |
| 184 | ->build(); |
| 185 | } |
| 186 | |
| 187 | void CryptoFactory::RotateMasterKeys( |
| 188 | const KmsConnectionConfig& kms_connection_config, |