libavutil/sha.h File Reference

#include <stdint.h>

Go to the source code of this file.

Functions

int av_sha_init (struct AVSHA *context, int bits)
 Initializes SHA-1 or SHA-2 hashing.
void av_sha_update (struct AVSHA *context, const uint8_t *data, unsigned int len)
 Updates hash value.
void av_sha_final (struct AVSHA *context, uint8_t *digest)
 Finishes hashing and output digest value.

Variables

const int av_sha_size


Function Documentation

void av_sha_final ( struct AVSHA context,
uint8_t *  digest 
)

Finishes hashing and output digest value.

Parameters:
context hash function context
digest buffer where output digest value is stored

Definition at line 314 of file sha.c.

Referenced by av_sha1_final(), and rtmp_calc_digest().

int av_sha_init ( struct AVSHA context,
int  bits 
)

Initializes SHA-1 or SHA-2 hashing.

Parameters:
context pointer to the function context (of size av_sha_size)
bits number of bits in digest (SHA-1 - 160 bits, SHA-2 224 or 256 bits)
Returns:
zero if initialization succeeded, -1 otherwise

Definition at line 246 of file sha.c.

Referenced by av_sha1_init(), and rtmp_calc_digest().

void av_sha_update ( struct AVSHA context,
const uint8_t *  data,
unsigned int  len 
)

Updates hash value.

Parameters:
context hash function context
data input data to update hash with
len input data length

Definition at line 287 of file sha.c.

Referenced by av_sha1_update(), av_sha_final(), and rtmp_calc_digest().


Variable Documentation

const int av_sha_size

Definition at line 41 of file sha.c.

Referenced by rtmp_calc_digest().


Generated on Fri Oct 26 02:36:55 2012 for FFmpeg by  doxygen 1.5.8