30#include <libthreadar/libthreadar.hpp>
34#include "central_report.hpp"
35#include "exceptions.hpp"
36#include "authentication.hpp"
37#include "ssl_context.hpp"
38#include "server_pool.hpp"
48class listener :
public libthreadar::thread_signal
51 listener(
const std::shared_ptr<central_report> & log,
52 const std::shared_ptr<const authentication> & auth,
53 std::unique_ptr<ssl_context> & ciphering,
54 std::shared_ptr<server_pool> & pool,
57 listener(
const std::shared_ptr<central_report> & log,
58 const std::shared_ptr<const authentication> & auth,
59 std::unique_ptr<ssl_context> & ciphering,
60 std::shared_ptr<server_pool> & pool,
61 const std::string & ip,
68 ~listener() { close(sockfd); cancel(); join(); };
72 virtual void inherited_run()
override;
79 std::shared_ptr<central_report> rep;
80 std::shared_ptr<const authentication> src;
85 std::unique_ptr<ssl_context> ssl_ctx;
86 std::shared_ptr<server_pool> srv;
88 void set_sockfd(
int domain);
89 void init(
const std::shared_ptr<central_report> & log,
90 const std::shared_ptr<const authentication> & auth,
91 std::unique_ptr<ssl_context> & ciphering,
92 std::shared_ptr<server_pool> & pool,
93 const std::string & ip,
class listener
Definition: listener.hpp:49
listener(const std::shared_ptr< central_report > &log, const std::shared_ptr< const authentication > &auth, std::unique_ptr< ssl_context > &ciphering, std::shared_ptr< server_pool > &pool, unsigned int port)
Definition: listener.cpp:86