hash3.c 301 B

1234567891011121314
  1. #include <stdio.h>
  2. #include "crypto_hash_sha512.h"
  3. unsigned char x[8] = "testing\n";
  4. unsigned char h[crypto_hash_sha512_BYTES];
  5. int main()
  6. {
  7. int i;
  8. crypto_hash_sha512(h,x,sizeof x);
  9. for (i = 0;i < crypto_hash_sha512_BYTES;++i) printf("%02x",(unsigned int) h[i]);
  10. printf("\n");
  11. return 0;
  12. }