#include "core/fdrm/fx_crypt_aes.h"
#include "core/fxcrt/byteorder.h"
#include "core/fxcrt/check.h"
#include "core/fxcrt/check_op.h"
#include "core/fxcrt/compiler_specific.h"
#include "core/fxcrt/fx_memcpy_wrappers.h"
#define mulby2(x) …
namespace {
constexpr std::array<const uint8_t, 256> Sbox = …;
constexpr std::array<const uint8_t, 256> Sboxinv = …;
constexpr std::array<const uint32_t, 256> E0 = …;
constexpr std::array<uint32_t, 256> E1 = …;
constexpr std::array<uint32_t, 256> E2 = …;
constexpr std::array<uint32_t, 256> E3 = …;
constexpr std::array<uint32_t, 256> D0 = …;
constexpr std::array<uint32_t, 256> D1 = …;
constexpr std::array<uint32_t, 256> D2 = …;
constexpr std::array<uint32_t, 256> D3 = …;
#define ADD_ROUND_KEY_4() …
#define MOVEWORD(i) …
#define FMAKEWORD …
#define LASTWORD …
void aes_encrypt_nb_4(CRYPT_aes_context* ctx, uint32_t* block) { … }
#undef FMAKEWORD
#undef LASTWORD
#define FMAKEWORD …
#define LASTWORD …
void aes_decrypt_nb_4(CRYPT_aes_context* ctx, uint32_t* block) { … }
#undef FMAKEWORD
#undef LASTWORD
}
void CRYPT_AESSetKey(CRYPT_aes_context* ctx,
const uint8_t* key,
uint32_t keylen) { … }
void CRYPT_AESSetIV(CRYPT_aes_context* ctx, const uint8_t* iv) { … }
void CRYPT_AESDecrypt(CRYPT_aes_context* ctx,
uint8_t* dest,
const uint8_t* src,
uint32_t size) { … }
void CRYPT_AESEncrypt(CRYPT_aes_context* ctx,
pdfium::span<uint8_t> dest,
pdfium::span<const uint8_t> src) { … }