Correctly identify as iTop in cURL requests (#652)

* Correctly identify as iTop in cURL requests (with configuration option)
This commit is contained in:
Thomas Casteleyn
2024-11-14 15:18:47 +01:00
committed by GitHub
parent 85f6195a51
commit 1f3780f338
2 changed files with 8 additions and 1 deletions

View File

@@ -1944,7 +1944,7 @@ SQL;
CURLOPT_HEADER => false, // don't return the headers in the output
CURLOPT_FOLLOWLOCATION => true, // follow redirects
CURLOPT_ENCODING => "", // handle all encodings
CURLOPT_USERAGENT => "spider", // who am i
CURLOPT_USERAGENT => static::GetConfig()->Get('http.request.user_agent'), // who am i
CURLOPT_AUTOREFERER => true, // set referer on redirect
CURLOPT_CONNECTTIMEOUT => 120, // timeout on connect
CURLOPT_TIMEOUT => 120, // timeout on response