sha1.h File Reference

SHA-1 in C. More...

#include <isc/lang.h>
#include <isc/platform.h>
#include <isc/types.h>

Go to the source code of this file.

Data Structures

struct  isc_sha1_t

Defines

#define ISC_SHA1_H   1
#define ISC_SHA1_DIGESTLENGTH   20U
#define ISC_SHA1_BLOCK_LENGTH   64U

Functions

ISC_LANG_BEGINDECLS void isc_sha1_init (isc_sha1_t *ctx)
void isc_sha1_invalidate (isc_sha1_t *ctx)
void isc_sha1_update (isc_sha1_t *ctx, const unsigned char *data, unsigned int len)
void isc_sha1_final (isc_sha1_t *ctx, unsigned char *digest)


Detailed Description

SHA-1 in C.

Author:
By Steve Reid <steve@edmweb.com>
Note:
100% Public Domain

Definition in file sha1.h.


Define Documentation

#define ISC_SHA1_H   1

Definition at line 19 of file sha1.h.

#define ISC_SHA1_DIGESTLENGTH   20U

Definition at line 35 of file sha1.h.

Referenced by addnsec3(), ATF_TC_BODY(), check_options(), dns_ds_buildrdata(), dns_nsec3_buildrdata(), dns_nsec3_hashlength(), dst_key_sigsize(), fromstruct_cds(), fromstruct_dlv(), fromstruct_ds(), fromtext_cds(), fromtext_dlv(), fromtext_ds(), fromwire_cds(), fromwire_dlv(), fromwire_ds(), hmacsha1_fromdns(), hmacsha1_sign(), hmacsha1_verify(), isc_entropy_getdata(), isc_hmacsha1_sign(), isc_hmacsha1_verify(), load_configuration(), sign(), and verify().

#define ISC_SHA1_BLOCK_LENGTH   64U

Definition at line 36 of file sha1.h.

Referenced by hmacmd5_compare(), hmacmd5_createctx(), hmacmd5_fromdns(), hmacmd5_generate(), hmacsha1_compare(), hmacsha1_createctx(), hmacsha1_fromdns(), hmacsha1_generate(), isc_hmacsha1_init(), and isc_hmacsha1_sign().


Function Documentation

ISC_LANG_BEGINDECLS void isc_sha1_init ( isc_sha1_t context  ) 

isc_sha1_init - Initialize new context

Definition at line 317 of file sha1.c.

References isc_sha1_t::count, INSIST, and isc_sha1_t::state.

Referenced by ATF_TC_BODY(), dns_ds_buildrdata(), hmacsha1_fromdns(), isc_entropy_getdata(), isc_hmacsha1_init(), isc_hmacsha1_sign(), and isc_iterated_hash().

void isc_sha1_invalidate ( isc_sha1_t ctx  ) 

Definition at line 332 of file sha1.c.

Referenced by isc_hmacsha1_invalidate().

void isc_sha1_update ( isc_sha1_t context,
const unsigned char *  data,
unsigned int  len 
)

Run your data through this.

Definition at line 340 of file sha1.c.

References isc_sha1_t::buffer, isc_sha1_t::count, INSIST, isc_sha1_t::state, and transform().

Referenced by ATF_TC_BODY(), dns_ds_buildrdata(), hmacsha1_fromdns(), isc_entropy_getdata(), isc_hmacsha1_init(), isc_hmacsha1_sign(), isc_hmacsha1_update(), isc_iterated_hash(), and isc_sha1_final().

void isc_sha1_final ( isc_sha1_t ctx,
unsigned char *  digest 
)

Definition at line 374 of file sha1.c.

References isc_sha1_t::count, INSIST, isc_sha1_update(), and isc_sha1_t::state.

Referenced by ATF_TC_BODY(), dns_ds_buildrdata(), hmacsha1_fromdns(), isc_entropy_getdata(), isc_hmacsha1_init(), isc_hmacsha1_sign(), and isc_iterated_hash().


Generated on Tue Apr 28 17:41:16 2015 by Doxygen 1.5.4 for BIND9 Internals 9.11.0pre-alpha