proof.hpp 1.0 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152
  1. #ifndef __PROOF_HPP
  2. #define __PROOF_HPP
  3. #include <openssl/evp.h>
  4. #include <openssl/sha.h>
  5. #include <string>
  6. #include <vector>
  7. #include <sstream>
  8. #include <iomanip>
  9. #include "Scalar.hpp"
  10. #include "Curvepoint.hpp"
  11. #include "Bipoint.hpp"
  12. class Proof {
  13. public:
  14. Proof()
  15. { /* */ }
  16. Proof(
  17. std::string hbc)
  18. : hbc(hbc)
  19. { /* */ }
  20. void clear();
  21. // HBC security
  22. std::string hbc;
  23. // Malicious security
  24. std::vector<Twistpoint> curvepointUniversals;
  25. std::vector<TwistBipoint> curveBipointUniversals;
  26. std::vector<Scalar> challengeParts;
  27. std::vector<Scalar> responseParts;
  28. bool operator==(
  29. const Proof& b);
  30. friend std::ostream& operator<<(
  31. std::ostream& os,
  32. const Proof& output);
  33. friend std::istream& operator>>(
  34. std::istream& is,
  35. Proof& input);
  36. };
  37. Scalar oracle(
  38. const std::string& input,
  39. size_t lambda_0 = 256);
  40. #endif