3#include <userver/utils/boost_filesystem_file_status.hpp>
5#include <userver/dump/factory.hpp>
6#include <userver/dump/operations.hpp>
7#include <userver/utils/fast_pimpl.hpp>
8#include <userver/utils/strong_typedef.hpp>
10USERVER_NAMESPACE_BEGIN
16class EncryptedWriter
final :
public Writer {
22 const SecretKey& secret_key,
23 boost::filesystem::perms,
27 ~EncryptedWriter()
override;
32 void WriteRaw(std::string_view data)
override;
35 utils::FastPimpl<Impl, 632, 8> impl_;
38class EncryptedReader
final :
public Reader {
44 ~EncryptedReader()
override;
49 std::string_view ReadRaw(std::size_t max_size)
override;
52 utils::FastPimpl<Impl, 600, 8> impl_;
57 EncryptedOperationsFactory(SecretKey&& secret_key, boost::filesystem::perms perms);
59 std::unique_ptr<Reader> CreateReader(std::string full_path)
override;
61 std::unique_ptr<Writer> CreateWriter(std::string full_path, tracing::ScopeTime& scope)
override;
64 const SecretKey secret_key_;
65 const boost::filesystem::perms perms_;