[Harbour] Harbour SHA2 and SHA2-HMAC support
Viktor Szakáts
harbour.01 at syenar.hu
Sat Jan 17 17:26:23 EST 2009
Hi all,
Pls see a Harbour library which implements SHA2 related
checksumming and SHA2 MAC creation, here:
http://www.syenar.hu/harbour/hbsha2.zip
Usage from .prg:
HB_SHA224( <cMessage> ) -> <cDigest>
HB_SHA256( <cMessage> ) -> <cDigest>
HB_SHA384( <cMessage> ) -> <cDigest>
HB_SHA512( <cMessage> ) -> <cDigest>
HB_SHA224_HMAC( <cMessage>, <cKey> ) -> <cMAC>
HB_SHA256_HMAC( <cMessage>, <cKey> ) -> <cMAC>
HB_SHA384_HMAC( <cMessage>, <cKey> ) -> <cMAC>
HB_SHA512_HMAC( <cMessage>, <cKey> ) -> <cMAC>
This is a thin wrapper around this code:
http://www.ouah.org/ogay/sha2/
http://www.ouah.org/ogay/hmac/
Above code has BSD license, the same as used in PCRE, so I assume
it's also safe to include it in Harbour.
You can unzip the attached code in the contrib dir, and build
it just like any other contribs.
If there are no objections and I've received feedback, I plan to
add these functions to the core.
Brgds,
Viktor
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.harbour-project.org/pipermail/harbour/attachments/20090117/d6bd5aa4/attachment.html
More information about the Harbour
mailing list