Thank you very much!

David Irvine-2 wrote:
> 
> You may find that reading the file test.cpp will help you quickly grab the
> simpler concepts. There is a simple.h which will show you
> default initialised algorithms. See test.cpp line 483 (approx, see below)
> HmacFile for an implementation to start you off. It's trivial to replace
> the hash algorithm in this case to pretty much whatever you wish
> (it's currently SHA1). Change SHA1 to RIPEMD160 in the code below to start
> you off.
> 
> void HmacFile(const char *hexKey, const char *file)
> {
>         member_ptr<MessageAuthenticationCode> mac;
>         if (strcmp(hexKey, "selftest") == 0)
>         {
>                 cerr << "Computing HMAC/SHA1 value for self test.\n";
>                 mac.reset(NewIntegrityCheckingMAC());
>         }
>         else
>         {
>                 std::string decodedKey;
>                 StringSource(hexKey, true, new HexDecoder(new
> StringSink(decodedKey)));
>                 mac.reset(new HMAC<SHA1>((const byte *)decodedKey.data(),
> decodedKey.size()));
>         }
>         FileSource(file, true, new HashFilter(*mac, new HexEncoder(new
> FileSink(cout))));
> }
> 
> 
> Best Regards
> David Irvine
> 
> 
>  <http://maidsafe.net>maidsafe.net Limited is a limited liability company
> incorporated in Scotland with number SC297540. VAT Registered 889 0608 77.
> Registered Office: 72 Templehill, Troon, KA10 6BE.
> Telephone Scotland: +44 1292 750020.
> 
> 
> 
> 
> On Sat, Jul 14, 2012 at 3:02 PM, Rianq <[email protected]> wrote:
> 
>>
>> Hi there,
>> I'm having a little trouble finding my way into Crypto++. I'm not very
>> proficient in C++ and I just need an HMAC with underlying RIPEMD160 to
>> verify the result of test vectors for a PBKDF2 built in VHDL. I have no
>> aversion to reading, but I have no idea which parts of the crypto++ wiki
>> are
>> useful to me and which aren't. :/
>>
>> If you could give me some helpers where to go or what to read to reach my
>> goal, I'd be very glad.
>>
>> Thank you,
>> Rianq
>> --
>> View this message in context:
>> http://old.nabble.com/Verifying-HMAC-RIPEMD160-values-tp34161105p34161105.html
>> Sent from the Crypto++ Users mailing list archive at Nabble.com.
>>
>> --
>> You received this message because you are subscribed to the "Crypto++
>> Users" Google Group.
>> To unsubscribe, send an email to
>> [email protected].
>> More information about Crypto++ and this group is available at
>> http://www.cryptopp.com.
>>
> 
> -- 
> You received this message because you are subscribed to the "Crypto++
> Users" Google Group.
> To unsubscribe, send an email to
> [email protected].
> More information about Crypto++ and this group is available at
> http://www.cryptopp.com.
> 

-- 
View this message in context: 
http://old.nabble.com/Verifying-HMAC-RIPEMD160-values-tp34161105p34161396.html
Sent from the Crypto++ Users mailing list archive at Nabble.com.

-- 
You received this message because you are subscribed to the "Crypto++ Users" 
Google Group.
To unsubscribe, send an email to [email protected].
More information about Crypto++ and this group is available at 
http://www.cryptopp.com.

Reply via email to