From: Michael Tremer Date: Thu, 11 Mar 2021 16:48:11 +0000 (+0000) Subject: downloader: Disable all protocols except https://, http:// and file:// X-Git-Tag: 0.9.28~1285^2~567 X-Git-Url: http://git.ipfire.org/?a=commitdiff_plain;h=a1fc6bdcee4388146a5c9f6f6160f395c8621793;p=pakfire.git downloader: Disable all protocols except https://, http:// and file:// Signed-off-by: Michael Tremer --- diff --git a/src/libpakfire/downloader.c b/src/libpakfire/downloader.c index c9ddba40a..0b260439a 100644 --- a/src/libpakfire/downloader.c +++ b/src/libpakfire/downloader.c @@ -288,6 +288,10 @@ static struct pakfire_transfer* pakfire_downloader_create_transfer( curl_easy_setopt(transfer->handle, CURLOPT_DEBUGDATA, downloader->pakfire); #endif + // Limit protocols to HTTPS, HTTP, and FILE + curl_easy_setopt(transfer->handle, CURLOPT_PROTOCOLS, + CURLPROTO_HTTPS|CURLPROTO_HTTP|CURLPROTO_FILE); + // Reference back to this transfer curl_easy_setopt(transfer->handle, CURLOPT_PRIVATE, transfer);