1#ifndef BKCRACK_DATA_HPP
2#define BKCRACK_DATA_HPP
20 explicit Error(
const std::string& description);
32 Data(std::vector<std::uint8_t>
ciphertext, std::optional<std::uint8_t> checkByte,
BaseError(const std::string &type, const std::string &description)
Constructor.
Error(const std::string &description)
Constructor.
std::vector< std::pair< std::size_t, std::uint8_t > > extraPlaintext
additional bytes of plaintext with their offset relative to ciphertext with encryption header
Definition Data.hpp:43
static constexpr std::size_t encryptionHeaderSize
Size of the traditional PKWARE encryption header.
Definition Data.hpp:13
std::vector< std::uint8_t > ciphertext
ciphertext bytes including encryption header
Definition Data.hpp:35
std::vector< std::uint8_t > keystream
keystream bytes
Definition Data.hpp:37
Data(std::vector< std::uint8_t > ciphertext, std::optional< std::uint8_t > checkByte, std::vector< std::uint8_t > plaintext, int offset, const std::map< int, std::uint8_t > &extraPlaintext)
Construct data and check it can be used to carry out an attack.
std::vector< std::uint8_t > plaintext
plaintext bytes
Definition Data.hpp:36
std::size_t offset
plaintext and keystream offset relative to ciphertext with encryption header
Definition Data.hpp:40
Useful types, constants and utility functions.