fix: refactor everything, fix everything
This commit is contained in:
+453
-486
File diff suppressed because it is too large
Load Diff
+19
-18
@@ -12,28 +12,29 @@
|
||||
|
||||
typedef unsigned __int64 SOCKET;
|
||||
|
||||
class Proxy {
|
||||
public:
|
||||
Proxy();
|
||||
~Proxy();
|
||||
class Proxy
|
||||
{
|
||||
public:
|
||||
Proxy();
|
||||
~Proxy();
|
||||
|
||||
bool Init();
|
||||
void Shutdown();
|
||||
bool Init();
|
||||
void Shutdown();
|
||||
|
||||
CallbackEvent<const std::string&, std::string&> OnClientRequest;
|
||||
CallbackEvent<const std::string&, std::string&> OnServerResponse;
|
||||
CallbackEvent<const std::string&, std::string&> OnClientRequest;
|
||||
CallbackEvent<const std::string&, std::string&> OnServerResponse;
|
||||
|
||||
private:
|
||||
void loop();
|
||||
void handleClient(SOCKET clientSocket);
|
||||
private:
|
||||
void loop();
|
||||
void handleClient(SOCKET clientSocket);
|
||||
|
||||
bool initSSL();
|
||||
void cleanupSSL();
|
||||
bool initSSL();
|
||||
void cleanupSSL();
|
||||
|
||||
SOCKET _listenSocket = 0;
|
||||
std::thread _workerThread;
|
||||
std::atomic<bool> _running;
|
||||
SOCKET _listenSocket = 0;
|
||||
std::thread _workerThread;
|
||||
std::atomic<bool> _running = false;
|
||||
|
||||
CertManager _certManager;
|
||||
SSL_CTX* _clientCtx = nullptr;
|
||||
CertManager _certManager;
|
||||
SSL_CTX* _clientCtx = nullptr;
|
||||
};
|
||||
|
||||
Reference in New Issue
Block a user