Rizin
unix-like reverse engineering framework and cli tools
|
Go to the source code of this file.
Classes | |
struct | _zip_winzip_aes |
Macros | |
#define | MAX_KEY_LENGTH 256 |
#define | PBKDF2_ITERATIONS 1000 |
Functions | |
static bool | aes_crypt (zip_winzip_aes_t *ctx, zip_uint8_t *data, zip_uint64_t length) |
zip_winzip_aes_t * | _zip_winzip_aes_new (const zip_uint8_t *password, zip_uint64_t password_length, const zip_uint8_t *salt, zip_uint16_t encryption_method, zip_uint8_t *password_verify, zip_error_t *error) |
bool | _zip_winzip_aes_encrypt (zip_winzip_aes_t *ctx, zip_uint8_t *data, zip_uint64_t length) |
bool | _zip_winzip_aes_decrypt (zip_winzip_aes_t *ctx, zip_uint8_t *data, zip_uint64_t length) |
bool | _zip_winzip_aes_finish (zip_winzip_aes_t *ctx, zip_uint8_t *hmac) |
void | _zip_winzip_aes_free (zip_winzip_aes_t *ctx) |
#define MAX_KEY_LENGTH 256 |
Definition at line 42 of file zip_winzip_aes.c.
#define PBKDF2_ITERATIONS 1000 |
Definition at line 43 of file zip_winzip_aes.c.
bool _zip_winzip_aes_decrypt | ( | zip_winzip_aes_t * | ctx, |
zip_uint8_t * | data, | ||
zip_uint64_t | length | ||
) |
Definition at line 142 of file zip_winzip_aes.c.
References _zip_crypto_hmac, aes_crypt(), and length.
Referenced by winzip_aes_decrypt().
bool _zip_winzip_aes_encrypt | ( | zip_winzip_aes_t * | ctx, |
zip_uint8_t * | data, | ||
zip_uint64_t | length | ||
) |
Definition at line 136 of file zip_winzip_aes.c.
References _zip_crypto_hmac, aes_crypt(), and length.
Referenced by winzip_aes_encrypt().
bool _zip_winzip_aes_finish | ( | zip_winzip_aes_t * | ctx, |
zip_uint8_t * | hmac | ||
) |
Definition at line 148 of file zip_winzip_aes.c.
References _zip_crypto_hmac_output.
Referenced by verify_hmac(), and winzip_aes_encrypt().
void _zip_winzip_aes_free | ( | zip_winzip_aes_t * | ctx | ) |
Definition at line 154 of file zip_winzip_aes.c.
References _zip_crypto_aes_free(), _zip_crypto_hmac_free(), free(), and NULL.
Referenced by decrypt_header(), encrypt_header(), verify_hmac(), winzip_aes_encrypt(), and winzip_aes_free().
zip_winzip_aes_t* _zip_winzip_aes_new | ( | const zip_uint8_t * | password, |
zip_uint64_t | password_length, | ||
const zip_uint8_t * | salt, | ||
zip_uint16_t | encryption_method, | ||
zip_uint8_t * | password_verify, | ||
zip_error_t * | error | ||
) |
Definition at line 78 of file zip_winzip_aes.c.
References _zip_crypto_aes_free(), _zip_crypto_aes_new(), _zip_crypto_clear, _zip_crypto_hmac_new(), _zip_crypto_pbkdf2, error(), free(), malloc(), MAX_KEY_LENGTH, memcpy(), memset(), NULL, PBKDF2_ITERATIONS, WINZIP_AES_PASSWORD_VERIFY_LENGTH, ZIP_CRYPTO_AES_BLOCK_LENGTH, ZIP_EM_AES_128, ZIP_EM_AES_192, ZIP_EM_AES_256, ZIP_ER_INVAL, ZIP_ER_MEMORY, and zip_error_set().
Referenced by decrypt_header(), and encrypt_header().
|
static |
Definition at line 54 of file zip_winzip_aes.c.
References _zip_crypto_aes_encrypt_block, AES_BLOCK_SIZE, i, and length.
Referenced by _zip_winzip_aes_decrypt(), and _zip_winzip_aes_encrypt().