diff options
Diffstat (limited to 'src/other_tools/utils/curl_easy_handle.hpp')
-rw-r--r-- | src/other_tools/utils/curl_easy_handle.hpp | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/src/other_tools/utils/curl_easy_handle.hpp b/src/other_tools/utils/curl_easy_handle.hpp index 33bf462e..ea5989a1 100644 --- a/src/other_tools/utils/curl_easy_handle.hpp +++ b/src/other_tools/utils/curl_easy_handle.hpp @@ -49,6 +49,12 @@ class CurlEasyHandle { [[nodiscard]] auto static Create() noexcept -> std::shared_ptr<CurlEasyHandle>; + /// \brief Create a CurlEasyHandle object with non-default CA info + [[nodiscard]] auto static Create( + bool no_ssl_verify, + std::optional<std::filesystem::path> const& ca_bundle) noexcept + -> std::shared_ptr<CurlEasyHandle>; + /// \brief Download file from URL into given file_path. /// Will perform cleanup (i.e., remove empty file) in case download fails. /// Returns 0 if successful. @@ -68,6 +74,9 @@ class CurlEasyHandle { nullptr, curl_easy_closer}; + bool no_ssl_verify_{false}; + std::optional<std::filesystem::path> ca_bundle_{std::nullopt}; + /// \brief Overwrites write_callback to redirect to file instead of stdout. [[nodiscard]] auto static EasyWriteToFile(gsl::owner<char*> data, size_t size, |