Compare commits
2 Commits
| Author | SHA1 | Date | |
|---|---|---|---|
| 502a35357c | |||
| f3020200a0 |
@@ -13,6 +13,7 @@
|
||||
#include <ctime>
|
||||
|
||||
#include <processthreadsapi.h>
|
||||
#include <cstring>
|
||||
|
||||
std::string randomizeString(size_t length)
|
||||
{
|
||||
@@ -133,9 +134,11 @@ bool CertManager::GenerateCA()
|
||||
|
||||
Log::info("Generated new CA key and certificate files. Installing to Windows Root CA store automatically...");
|
||||
|
||||
STARTUPINFOA si = {0};
|
||||
STARTUPINFOA si;
|
||||
memset(&si, 0, sizeof(si));
|
||||
si.cb = sizeof(si);
|
||||
PROCESS_INFORMATION pi = {0};
|
||||
PROCESS_INFORMATION pi;
|
||||
memset(&pi, 0, sizeof(pi));
|
||||
char cmd[] = "certutil.exe -user -addstore root ca_cert.pem";
|
||||
if (CreateProcessA(NULL, cmd, NULL, NULL, FALSE, CREATE_NO_WINDOW, NULL, NULL, &si, &pi))
|
||||
{
|
||||
|
||||
@@ -535,9 +535,6 @@ void Proxy::handleClient(SOCKET hClientSocket)
|
||||
|
||||
std::string respHeaders = serverStream.buffer.substr(0, bStart);
|
||||
size_t firstSpace = respHeaders.find(' ');
|
||||
int sc =
|
||||
(firstSpace != std::string::npos) ? safe_stoi(respHeaders.substr(firstSpace + 1, 3)) : 0;
|
||||
|
||||
OnServerResponse.run(url, body, respHeaders);
|
||||
|
||||
removeHeader(respHeaders, "Transfer-Encoding");
|
||||
|
||||
Reference in New Issue
Block a user