summaryrefslogtreecommitdiff
path: root/nacl/crypto_hash/wrapper-hash.cpp
blob: 4c0fb59036e33c7754fd8459a25992a2e991e205 (plain)
1
2
3
4
5
6
7
8
9
10
#include <string>
using std::string;
#include "crypto_hash.h"

string crypto_hash(const string &m)
{
  unsigned char h[crypto_hash_BYTES];
  crypto_hash(h,(const unsigned char *) m.c_str(),m.size());
  return string((char *) h,sizeof h);
}