You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

28 lines
475 B

  1. #include "src/system/betatest.hpp"
  2. #include <fstream>
  3. #include <string>
  4. bool checkBetaTest()
  5. {
  6. std::string betaFlag = "7h1s_i5_n0t_a_b3t4_tE5t_k3y";
  7. std::string tmp;
  8. int result = -1;
  9. try
  10. {
  11. std::fstream betaFile("beta.test");
  12. if (betaFile) {
  13. betaFile >> tmp;
  14. result = tmp.compare("SlashRootCTF{" + betaFlag + "}");
  15. }
  16. }
  17. catch(...)
  18. {
  19. return false;
  20. }
  21. return result == 0;
  22. }