Dallas Semiconductor DS80C400 C Libraries Home Page

Main Page | Modules | Data Structures | Directories | File List | Data Fields | Globals

tini400_crypt.h File Reference


Detailed Description

SHA-1 and MD4 functions for the DS80C400.

This library contains functions that compute the SHA-1 hash and MD4 hash of a byte array.

For detailed information on the DS80C400 please see the High-Speed Microcontroller User's Guide: DS80C400 Supplement.

Warning:
The functions in this library are NOT multi-process safe--that is, if you call the same method from two different processes at the same time, the parameters to the function may be destroyed, yielding unpredictable results. Consult each individual funtion's documentation for details on which functions are multi-process safe.

Go to the source code of this file.

Defines

#define TINI400_CRYPT_VERSION   3

Functions

unsigned int crypt_version (void)
 Returns the version number of this CRYPT library.
void crypt_sha1 (short inLength, void *inBuff, void *outBuff)
 Computes a SHA-1 hash on the given message.
void crypt_md4 (unsigned char *out, unsigned char *in, int n)
 Computes a MD4 hash on the given message.


Define Documentation

#define TINI400_CRYPT_VERSION   3
 

Version number associated with this header file. Should be the same as the version number returned by the crypt_version function.

See also:
crypt_version


Function Documentation

void crypt_md4 unsigned char *  out,
unsigned char *  in,
int  n
 

Computes a MD4 hash on the given message.

See RFC 1320 for more information. WARNING! MD4 has known cryptographic weaknesses. Where possible, SHA-1 should be used instead.

Parameters:
out holds the hash value on return (16 bytes)
in the message to hash
n length of the message to hash

void crypt_sha1 short  inLength,
void *  inBuff,
void *  outBuff
 

Computes a SHA-1 hash on the given message.

See FIPS 180-1 for more information on SHA-1.

Parameters:
inLength length of the message to hash
inBuff the message to hash
outBuff holds the hash value on return (20 bytes minimum)

unsigned int crypt_version void   ) 
 

Returns the version number of this CRYPT library.

Returns:
Version number of this CRYPT library.


Copyright 2005 Dallas Semiconductor, Inc.. Documentation generated by Doxygen.