diff options
author | Roland Reichwein <mail@reichwein.it> | 2023-01-10 14:22:47 +0100 |
---|---|---|
committer | Roland Reichwein <mail@reichwein.it> | 2023-01-10 14:22:47 +0100 |
commit | d02a29f0ff33279268e675aae0856f3f8cf9d939 (patch) | |
tree | bbb22aeb9c14488ef0871b34f0400259658d46f0 /plugins/websocket/websocket.h | |
parent | 1191f07767583a9b19280a4f29cb1b0bd6799785 (diff) |
Configurable Websocket für HTTPS
Diffstat (limited to 'plugins/websocket/websocket.h')
-rw-r--r-- | plugins/websocket/websocket.h | 29 |
1 files changed, 29 insertions, 0 deletions
diff --git a/plugins/websocket/websocket.h b/plugins/websocket/websocket.h new file mode 100644 index 0000000..27218da --- /dev/null +++ b/plugins/websocket/websocket.h @@ -0,0 +1,29 @@ +#pragma once + +#include "../../plugin_interface.h" + +#include <boost/asio.hpp> + +#include <cstdint> +#include <mutex> +#include <set> + +class websocket_plugin: public webserver_plugin_interface +{ + +public: + websocket_plugin(); + ~websocket_plugin(); + + std::string name() override; + std::string generate_page( + std::function<std::string(const std::string& key)>& GetServerParam, + std::function<std::string(const std::string& key)>& GetRequestParam, // request including body (POST...) + std::function<void(const std::string& key, const std::string& value)>& SetResponseHeader // to be added to result string + ) override; + + bool has_own_authentication() override; +}; + +extern "C" BOOST_SYMBOL_EXPORT websocket_plugin webserver_plugin; +websocket_plugin webserver_plugin; |