Sha256: 1f8cb980df5194be2244912abd8f2c643598dbea258db35eeefa937300681145

Contents?: true

Size: 347 Bytes

Versions: 3

Compression:

Stored size: 347 Bytes

Contents

#include <string>
using std::string;
#include "crypto_scalarmult.h"

string crypto_scalarmult_base(const string &n)
{
  unsigned char q[crypto_scalarmult_BYTES];
  if (n.size() != crypto_scalarmult_SCALARBYTES) throw "incorrect scalar length";
  crypto_scalarmult_base(q,(const unsigned char *) n.c_str());
  return string((char *) q,sizeof q);
}

Version data entries

3 entries across 3 versions & 1 rubygems

Version Path
ruby_nacl-0.1.2 ext/ruby_nacl/NaCl/crypto_scalarmult/wrapper-base.cpp
ruby_nacl-0.1.1 ext/ruby_nacl/NaCl/crypto_scalarmult/wrapper-base.cpp
ruby_nacl-0.1.0 ext/ruby_nacl/NaCl/crypto_scalarmult/wrapper-base.cpp