function: rmd160_sum_words (library) rmd160

Name

rmd160_sum_words - yield digest sum as an array of words

Synopsis

rmd160uint32 *rmd160_sum_words( RMD160 instance, rmd160uint32 *sum )

Description

rmd160_sum_words returns the RMD160 message digest sum as an array of 5 32-bit words stored in an array of type rmd160uint32 with 5 elements.

instance is the RMD160 message digest instance from which the sum is obtained.

sum is a pointer to an array of type rmd160uint32 containing at least 5 elements into which the sum will be written, or is NULL indicating that an array of type rmd160uint32 of 5 elements will be dynamically allocated for the sum, which must be freed by the calling program via the standard free() function.

Return values

A pointer to an array of type char is returned. If sum was given as NULL, then the returned value points to dynamically allocated memory that the caller must free via the standard free() function. The value NULL is returned if memory cannot be allocated, or if instance is NULL.

Errors

Errors are given in the return value.

See also

rmd160 homepage


The documentation, source code, and derived compilations are Copyright © 1999 by Philip Howard.

This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License [ GNU copy | local copy ] as published by the Free Software Foundation; either version 2 of the License, or (at your option) any later version.

This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details.

You should have received a copy of the GNU General Public License along with this program; if not, write to the Free Software Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.