Hello
joomla 3.4.1
serveur apache
J'ai remarqué un truc un peu space dans mes logs.
error.log :
Reviens régulièrement et pas avec la même IP
Correspondant a :
web.php
uri.php
J'ai comparé avec access.log, et c'est toujours un HEAD qui fait apparaitre l'erreur, jamais un POST ni un GET
Une idée ?
joomla 3.4.1
serveur apache
J'ai remarqué un truc un peu space dans mes logs.
error.log :
Code:
[Thu Jul 02 09:12:03 2015] [error] [client 37.128.xxx.xx] PHP Notice: Undefined index: HTTP_HOST in /var/www/libraries/joomla/application/web.php on line 863 [Thu Jul 02 09:12:04 2015] [error] [client 37.128.xxx.xx] PHP Notice: Undefined index: HTTP_HOST in /var/www/libraries/joomla/uri/uri.php on line 85
Correspondant a :
web.php
Code PHP:
/*
* There are some differences in the way that Apache and IIS populate server environment variables. To
* properly detect the requested URI we need to adjust our algorithm based on whether or not we are getting
* information from Apache or IIS.
*/
// If PHP_SELF and REQUEST_URI are both populated then we will assume "Apache Mode".
if (!empty($_SERVER['PHP_SELF']) && !empty($_SERVER['REQUEST_URI']))
{
// The URI is built from the HTTP_HOST and REQUEST_URI environment variables in an Apache environment.
$uri = $scheme . $_SERVER['HTTP_HOST'] . $_SERVER['REQUEST_URI'];
}
// If not in "Apache Mode" we will assume that we are in an IIS environment and proceed.
else
{
// IIS uses the SCRIPT_NAME variable instead of a REQUEST_URI variable... thanks, MS
$uri = $scheme . $_SERVER['HTTP_HOST'] . $_SERVER['SCRIPT_NAME']; //ligne 863
// If the QUERY_STRING variable exists append it to the URI string.
if (isset($_SERVER['QUERY_STRING']) && !empty($_SERVER['QUERY_STRING']))
{
$uri .= '?' . $_SERVER['QUERY_STRING'];
}
}
return trim($uri);
}
Code PHP:
/*
* Since we are assigning the URI from the server variables, we first need
* to determine if we are running on apache or IIS. If PHP_SELF and REQUEST_URI
* are present, we will assume we are running on apache.
*/
if (!empty($_SERVER['PHP_SELF']) && !empty($_SERVER['REQUEST_URI']))
{
// To build the entire URI we need to prepend the protocol, and the http host
// to the URI string.
$theURI = 'http' . $https . $_SERVER['HTTP_HOST'] . $_SERVER['REQUEST_URI']; //ligne 85
}
else
{
/*
* Since we do not have REQUEST_URI to work with, we will assume we are
* running on IIS and will therefore need to work some magic with the SCRIPT_NAME and
* QUERY_STRING environment variables.
*
* IIS uses the SCRIPT_NAME variable instead of a REQUEST_URI variable... thanks, MS
*/
$theURI = 'http' . $https . $_SERVER['HTTP_HOST'] . $_SERVER['SCRIPT_NAME'];
// If the query string exists append it to the URI string
if (isset($_SERVER['QUERY_STRING']) && !empty($_SERVER['QUERY_STRING']))
{
$theURI .= '?' . $_SERVER['QUERY_STRING'];
}
}
Code:
179.191.xxx.xx - - [02/Jul/2015:09:04:41 +0200] "HEAD / HTTP/1.0" 200 579 "-" "-"
Commentaire