Loading...
Searching...
No Matches
XTEA
libavutil » Crypto and Hashing

## Data Structures

struct | AVXTEA

## Functions

AVXTEA * | av_xtea_alloc (void)
| Allocate an AVXTEA context.
void | av_xtea_init (struct AVXTEA *ctx, const uint8_t key[16])
| Initialize an AVXTEA context.
void | av_xtea_le_init (struct AVXTEA *ctx, const uint8_t key[16])
| Initialize an AVXTEA context.
void | av_xtea_crypt (struct AVXTEA *ctx, uint8_t *dst, const uint8_t *src, int count, uint8_t *iv, int decrypt)
| Encrypt or decrypt a buffer using a previously initialized context, in big endian format.
void | av_xtea_le_crypt (struct AVXTEA *ctx, uint8_t *dst, const uint8_t *src, int count, uint8_t *iv, int decrypt)
| Encrypt or decrypt a buffer using a previously initialized context, in little endian format.

## Detailed Description

## Function Documentation

## av_xtea_alloc()

AVXTEA * av_xtea_alloc | ( | void |  | ) |

Allocate an AVXTEA context.

## av_xtea_init()

void av_xtea_init | ( | struct AVXTEA * | ctx,
|  | const uint8_t | key[16] )

Initialize an AVXTEA context.

Parameters

  ctx | an AVXTEA context
  key | a key of 16 bytes used for encryption/decryption, interpreted as big endian 32 bit numbers

## av_xtea_le_init()

void av_xtea_le_init | ( | struct AVXTEA * | ctx,
|  | const uint8_t | key[16] )

Initialize an AVXTEA context.

Parameters

  ctx | an AVXTEA context
  key | a key of 16 bytes used for encryption/decryption, interpreted as little endian 32 bit numbers

## av_xtea_crypt()

void av_xtea_crypt | ( | struct AVXTEA * | ctx,
|  | uint8_t * | dst,
|  | const uint8_t * | src,
|  | int | count,
|  | uint8_t * | iv,
|  | int | decrypt )

Encrypt or decrypt a buffer using a previously initialized context, in big endian format.

Parameters

  ctx | an AVXTEA context
  dst | destination array, can be equal to src
  src | source array, can be equal to dst
  count | number of 8 byte blocks
  iv | initialization vector for CBC mode, if NULL then ECB will be used
  decrypt | 0 for encryption, 1 for decryption

## av_xtea_le_crypt()

void av_xtea_le_crypt | ( | struct AVXTEA * | ctx,
|  | uint8_t * | dst,
|  | const uint8_t * | src,
|  | int | count,
|  | uint8_t * | iv,
|  | int | decrypt )

Encrypt or decrypt a buffer using a previously initialized context, in little endian format.

Parameters

  ctx | an AVXTEA context
  dst | destination array, can be equal to src
  src | source array, can be equal to dst
  count | number of 8 byte blocks
  iv | initialization vector for CBC mode, if NULL then ECB will be used
  decrypt | 0 for encryption, 1 for decryption