node-multi-hashing/keccak.c

15 lines
337 B
C
Raw Normal View History

2014-03-30 10:04:48 +02:00
#include "keccak.h"
#include "sha3/sph_types.h"
2014-03-30 10:04:48 +02:00
#include "sha3/sph_keccak.h"
2014-04-19 23:33:45 +02:00
void keccak_hash(const char* input, char* output, uint32_t size)
2014-03-30 10:04:48 +02:00
{
2014-04-01 18:19:01 +02:00
sph_keccak256_context ctx_keccak;
2014-03-30 10:04:48 +02:00
sph_keccak256_init(&ctx_keccak);
sph_keccak256 (&ctx_keccak, input, size);//80);
2014-03-30 10:04:48 +02:00
sph_keccak256_close(&ctx_keccak, output);
}