FFmpeg
 All Data Structures Namespaces Files Functions Variables Typedefs Enumerations Enumerator Macros Groups Pages
Functions | Variables

Functions

struct AVTEAav_tea_alloc (void)
 Allocate an AVTEA context To free the struct: av_free(ptr) More...
 
void av_tea_init (struct AVTEA *ctx, const uint8_t key[16], int rounds)
 Initialize an AVTEA context. More...
 
void av_tea_crypt (struct AVTEA *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. More...
 

Variables

const int av_tea_size
 

Detailed Description

Function Documentation

struct AVTEA* av_tea_alloc ( void  )

Allocate an AVTEA context To free the struct: av_free(ptr)

Definition at line 35 of file tea.c.

Referenced by aa_read_header().

void av_tea_init ( struct AVTEA ctx,
const uint8_t  key[16],
int  rounds 
)

Initialize an AVTEA context.

Parameters
ctxan AVTEA context
keya key of 16 bytes used for encryption/decryption
roundsthe number of rounds in TEA (64 is the "standard")

Definition at line 42 of file tea.c.

Referenced by aa_read_header(), and aa_read_packet().

void av_tea_crypt ( struct AVTEA 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.

Parameters
ctxan AVTEA context
dstdestination array, can be equal to src
srcsource array, can be equal to dst
countnumber of 8 byte blocks
ivinitialization vector for CBC mode, if NULL then ECB will be used
decrypt0 for encryption, 1 for decryption

Definition at line 95 of file tea.c.

Referenced by aa_read_header(), and aa_read_packet().

Variable Documentation

const int av_tea_size

Definition at line 40 of file tea.c.