.\" .\" ---------------------------------------------------------------------------- .\" "THE BEER-WARE LICENSE" (Revision 42): .\" wrote this file. As long as you retain this notice you .\" can do whatever you want with this stuff. If we meet some day, and you think .\" this stuff is worth it, you can buy me a beer in return. Poul-Henning Kamp .\" ---------------------------------------------------------------------------- .\" .\" From: Id: mdX.3,v 1.14 1999/02/11 20:31:49 wollman Exp .\" $FreeBSD: src/lib/libmd/sha512.3,v 1.4 2005/11/17 13:00:00 ru Exp $ .\" $DragonFly: src/lib/libmd/sha512.3,v 1.2 2008/09/11 20:25:34 swildner Exp $ .\" .Dd July 4, 2010 .Dt SHA384 3 .Os .Sh NAME .Nm SHA384_Init , .Nm SHA384_Update , .Nm SHA384_Final .Nd calculate the FIPS 180-2 ``SHA-384'' message digest .Sh LIBRARY .Lb libmd .Sh SYNOPSIS .In sys/types.h .In sha512.h .Ft void .Fn SHA384_Init "SHA384_CTX *context" .Ft void .Fn SHA384_Update "SHA384_CTX *context" "const u_int8_t *data" "size_t len" .Ft void .Fn SHA384_Final "u_int8_t digest[48]" "SHA384_CTX *context" .Sh DESCRIPTION The .Li SHA384_ functions calculate a 384-bit cryptographic checksum (digest) for any number of input bytes. A cryptographic checksum is a one-way hash function; that is, it is computationally impractical to find the input corresponding to a particular output. This net result is a .Dq fingerprint of the input-data, which does not disclose the actual input. .Pp The .Fn SHA384_Init , .Fn SHA384_Update , and .Fn SHA384_Final functions are the core functions. Allocate an .Vt SHA384_CTX , initialize it with .Fn SHA384_Init , run over the data with .Fn SHA384_Update , and finally extract the result using .Fn SHA384_Final . .Pp .Sh SEE ALSO .Xr md2 3 , .Xr md4 3 , .Xr md5 3 , .Xr ripemd 3 , .Xr sha 3 .Sh HISTORY These functions appeared in .Dx 2.9 . .Sh AUTHORS The core hash routines were implemented by Colin Percival based on the published .Tn FIPS 180-2 standard. .Sh BUGS No method is known to exist which finds two files having the same hash value, nor to find a file with a specific hash value. There is on the other hand no guarantee that such a method does not exist.