From 88bc6c11a1d3d2b6ae088bf550b584603e9b4f46 Mon Sep 17 00:00:00 2001 From: amass <168062547@qq.com> Date: Fri, 3 May 2024 21:39:01 +0800 Subject: [PATCH] correct http method. --- HttpProxy/NetworkUtility.cpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/HttpProxy/NetworkUtility.cpp b/HttpProxy/NetworkUtility.cpp index 698d35e..d73d228 100644 --- a/HttpProxy/NetworkUtility.cpp +++ b/HttpProxy/NetworkUtility.cpp @@ -135,7 +135,7 @@ void Client::loadRootCertificates(boost::system::error_code &error) { std::string Client::get(const std::string &host, const std::string &port, const std::string &url, boost::system::error_code &error) { using namespace boost::beast; - m_request.method(http::verb::put); + m_request.method(http::verb::get); m_request.target(url); m_request.set(http::field::host, host); return execute(host, port, m_request, error); @@ -144,7 +144,7 @@ std::string Client::get(const std::string &host, const std::string &port, const std::string Client::post(const std::string &host, const std::string &port, const std::string &url, const std::string &body, boost::system::error_code &error) { using namespace boost::beast; - m_request.method(http::verb::put); + m_request.method(http::verb::post); m_request.target(url); m_request.set(http::field::host, host); m_request.body() = body;