#include "third_party/private-join-and-compute/src/crypto/context.h"
#include <math.h>
#include <algorithm>
#include <cmath>
#include "third_party/private-join-and-compute/src/chromium_patch.h"
namespace private_join_and_compute {
std::string OpenSSLErrorString() { … }
Context::Context()
: … { … }
Context::~Context() { … }
BN_CTX* Context::GetBnCtx() { … }
BigNum Context::CreateBigNum(const std::string& bytes) { … }
BigNum Context::CreateBigNum(uint64_t number) { … }
BigNum Context::CreateBigNum(BigNum::BignumPtr bn) { … }
std::string Context::Sha256String(const std::string& bytes) { … }
std::string Context::Sha512String(const std::string& bytes) { … }
BigNum Context::RandomOracle(const std::string& x, const BigNum& max_value,
RandomOracleHashType hash_type) { … }
BigNum Context::RandomOracleSha512(const std::string& x,
const BigNum& max_value) { … }
BigNum Context::RandomOracleSha256(const std::string& x,
const BigNum& max_value) { … }
BigNum Context::PRF(const std::string& key, const std::string& data,
const BigNum& max_value) { … }
BigNum Context::GenerateSafePrime(int prime_length) { … }
BigNum Context::GeneratePrime(int prime_length) { … }
BigNum Context::GenerateRandLessThan(const BigNum& max_value) { … }
BigNum Context::GenerateRandBetween(const BigNum& start, const BigNum& end) { … }
std::string Context::GenerateRandomBytes(int num_bytes) { … }
BigNum Context::RelativelyPrimeRandomLessThan(const BigNum& num) { … }
}