/usr/include/measurement_kit/ooni/bouncer.hpp is in libmeasurement-kit-dev 0.7.1-2build1.
This file is owned by root:root, with mode 0o644.
The actual contents of the file can be viewed below.
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 | // Part of measurement-kit <https://measurement-kit.github.io/>.
// Measurement-kit is free software. See AUTHORS and LICENSE for more
// information on the copying conditions.
#ifndef MEASUREMENT_KIT_OONI_BOUNCER_HPP
#define MEASUREMENT_KIT_OONI_BOUNCER_HPP
#include <measurement_kit/common.hpp>
#include <measurement_kit/ext/json.hpp>
namespace mk {
namespace ooni {
class BouncerReply {
public:
nlohmann::json response;
static ErrorOr<Var<BouncerReply>> create(std::string, Var<Logger>);
ErrorOr<std::string> get_collector();
ErrorOr<std::string> get_collector_alternate(std::string type);
ErrorOr<std::string> get_name();
ErrorOr<std::string> get_test_helper(std::string name);
ErrorOr<std::string> get_test_helper_alternate(std::string name,
std::string type);
ErrorOr<std::string> get_version();
private:
nlohmann::json get_base();
};
namespace bouncer {
void post_net_tests(std::string base_bouncer_url, std::string test_name,
std::string test_version, std::list<std::string> helpers,
Callback<Error, Var<BouncerReply>> cb, Settings settings,
Var<Reactor> reactor, Var<Logger> logger);
#define MK_OONI_PRODUCTION_BOUNCER_URL "https://bouncer.ooni.io"
#define MK_OONI_TESTING_BOUNCER_URL "https://bouncer.test.ooni.io"
std::string production_bouncer_url();
std::string testing_bouncer_url();
} // namespace bouncer
} // namespace ooni
} // namespace mk
#endif
|