Limit CURL to only support HTTP(S) protocols
We don't actually need any other protocols, so lets disable them to ensure we can't be affected by any vulnerabilities in that part of the CURL library.
This commit is contained in:
parent
5817a8b5f4
commit
094fdc1b13
|
@ -24,6 +24,8 @@
|
|||
|
||||
// kicad_curl_easy.h **must be** included before any wxWidgets header to avoid conflicts
|
||||
// at least on Windows/msys2
|
||||
#include <curl/curl.h>
|
||||
#include <curl/easy.h>
|
||||
#include <kicad_curl/kicad_curl.h>
|
||||
#include <kicad_curl/kicad_curl_easy.h>
|
||||
|
||||
|
@ -112,6 +114,9 @@ KICAD_CURL_EASY::KICAD_CURL_EASY() : m_headers( nullptr )
|
|||
curl_easy_setopt( m_CURL, CURLOPT_WRITEFUNCTION, write_callback );
|
||||
curl_easy_setopt( m_CURL, CURLOPT_WRITEDATA, (void*) &m_buffer );
|
||||
|
||||
// Only allow HTTP and HTTPS protocols
|
||||
curl_easy_setopt( m_CURL, CURLOPT_PROTOCOLS, CURLPROTO_HTTP | CURLPROTO_HTTPS );
|
||||
|
||||
wxPlatformInfo platformInfo;
|
||||
wxString application( Pgm().App().GetAppName() );
|
||||
wxString version( GetBuildVersion() );
|
||||
|
|
Loading…
Reference in New Issue