mirror of
https://github.com/vrana/adminer.git
synced 2026-07-01 00:38:33 +02:00
Hide error message from HTTP servers
This commit is contained in:
@@ -424,7 +424,6 @@ if (isset($_GET["simpledb"])) {
|
||||
}
|
||||
$query = str_replace('%7E', '~', substr($query, 1));
|
||||
$query .= "&Signature=" . urlencode(base64_encode(hmac('sha1', "POST\n" . preg_replace('~^https?://~', '', $host) . "\n/\n$query", $secret, true)));
|
||||
@ini_set('track_errors', 1); // @ - may be disabled
|
||||
$file = @file_get_contents((preg_match('~^https?://~', $host) ? $host : "http://$host"), false, stream_context_create(array('http' => array(
|
||||
'method' => 'POST', // may not fit in URL with GET
|
||||
'content' => $query,
|
||||
@@ -433,7 +432,7 @@ if (isset($_GET["simpledb"])) {
|
||||
'max_redirects' => 0,
|
||||
))));
|
||||
if (!$file) {
|
||||
$connection->error = $php_errormsg;
|
||||
$this->error = lang('Invalid credentials.');
|
||||
return false;
|
||||
}
|
||||
libxml_use_internal_errors(true);
|
||||
|
||||
Reference in New Issue
Block a user