37 #ifndef VIRGIL_CHUNK_CIPHER_H
38 #define VIRGIL_CHUNK_CIPHER_H
42 #include <virgil/crypto/VirgilCipherBase.h>
43 #include <virgil/crypto/VirgilByteArray.h>
44 #include <virgil/crypto/VirgilDataSource.h>
45 #include <virgil/crypto/VirgilDataSink.h>
47 namespace virgil {
namespace crypto {
78 size_t preferredChunkSize = kPreferredChunkSize);
102 void storeChunkSize(
size_t chunkSize);
107 size_t retrieveChunkSize()
const;
void decryptWithPassword(VirgilDataSource &source, VirgilDataSink &sink, const VirgilByteArray &pwd)
Decrypt data read from given source for recipient defined by password, and write it to the sink...
This class provides high-level interface to encrypt / decrypt data splitted to chunks.
Definition: VirgilChunkCipher.h:54
This is base class for output streams.
Definition: VirgilDataSink.h:49
Root namespace for all Virgil Security libraries.
Definition: VirgilAsn1Compatible.h:46
std::vector< unsigned char > VirgilByteArray
This type represents a sequence of bytes.
Definition: VirgilByteArray.h:53
void decryptWithKey(VirgilDataSource &source, VirgilDataSink &sink, const VirgilByteArray &recipientId, const VirgilByteArray &privateKey, const VirgilByteArray &privateKeyPassword=VirgilByteArray())
Decrypt data read from given source for recipient defined by id and private key, and write it to the ...
static constexpr size_t kPreferredChunkSize
Recommended chunk size.
Definition: VirgilChunkCipher.h:64
void encrypt(VirgilDataSource &source, VirgilDataSink &sink, bool embedContentInfo=true, size_t preferredChunkSize=kPreferredChunkSize)
Encrypt data read from given source and write it the sink.
This is base class for input streams.
Definition: VirgilDataSource.h:49
This class provides configuration methods to all Virgil*Cipher classes.
Definition: VirgilCipherBase.h:61