From 5bd9c1611dd961ee7d7c32a5948de8babff89bac Mon Sep 17 00:00:00 2001 From: logmanoriginal Date: Sun, 25 Mar 2018 15:28:00 +0200 Subject: [PATCH] [contents] Limit cURL protocols to HTTP and HTTPS --- lib/contents.php | 1 + 1 file changed, 1 insertion(+) diff --git a/lib/contents.php b/lib/contents.php index f9b68d29..7fbda2d6 100644 --- a/lib/contents.php +++ b/lib/contents.php @@ -6,6 +6,7 @@ function getContents($url, $header = array(), $opts = array()){ curl_setopt($ch, CURLOPT_HTTPHEADER, $header); curl_setopt($ch, CURLOPT_USERAGENT, ini_get('user_agent')); curl_setopt($ch, CURLOPT_ENCODING, ''); + curl_setopt($ch, CURLOPT_PROTOCOLS, CURLPROTO_HTTP | CURLPROTO_HTTPS); if(is_array($opts)) { foreach($opts as $key => $value) {