Rizin
unix-like reverse engineering framework and cli tools
aes-encrypt.c File Reference
#include <stdlib.h>
#include "aes-internal.h"

Go to the source code of this file.

Functions

void aes_encrypt (const struct aes_ctx *ctx, size_t length, uint8_t *dst, const uint8_t *src)
 

Function Documentation

◆ aes_encrypt()

void aes_encrypt ( const struct aes_ctx ctx,
size_t  length,
uint8_t dst,
const uint8_t src 
)

Definition at line 49 of file aes-encrypt.c.

52 {
53  switch (ctx->key_size)
54  {
55  default: abort();
56  case AES128_KEY_SIZE:
57  aes128_encrypt(&ctx->u.ctx128, length, dst, src);
58  break;
59  case AES192_KEY_SIZE:
60  aes192_encrypt(&ctx->u.ctx192, length, dst, src);
61  break;
62  case AES256_KEY_SIZE:
63  aes256_encrypt(&ctx->u.ctx256, length, dst, src);
64  break;
65  }
66 }
void aes128_encrypt(const struct aes128_ctx *ctx, size_t length, uint8_t *dst, const uint8_t *src)
#define AES192_KEY_SIZE
Definition: aes.h:71
void aes192_encrypt(const struct aes192_ctx *ctx, size_t length, uint8_t *dst, const uint8_t *src)
void aes256_encrypt(const struct aes256_ctx *ctx, size_t length, uint8_t *dst, const uint8_t *src)
#define AES256_KEY_SIZE
Definition: aes.h:72
#define AES128_KEY_SIZE
Definition: aes.h:70
lzma_index * src
Definition: index.h:567
static static sync static getppid static getegid const char static filename char static len const char char static bufsiz static mask static vfork const void static prot static getpgrp const char static swapflags static arg static fd static protocol static who struct sockaddr static addrlen static backlog struct timeval struct timezone static tz const struct iovec static count static mode const void const struct sockaddr static tolen const char static pathname void static offset struct stat static buf void long static basep static whence static length const void static len static semflg const void static shmflg const struct timespec struct timespec static rem const char static group const void length
Definition: sflib.h:133
char * dst
Definition: lz4.h:724

References aes128_encrypt(), AES128_KEY_SIZE, aes192_encrypt(), AES192_KEY_SIZE, aes256_encrypt(), AES256_KEY_SIZE, dst, length, and src.