check remote-ip when ip-restriction is set in api_keys table
Signed-off-by: Michael Kaufmann (d00p) <d00p@froxlor.org>
This commit is contained in:
@@ -368,7 +368,11 @@ abstract class ApiCommand
|
||||
*/
|
||||
protected function response($status, $status_message, $data = null)
|
||||
{
|
||||
header("HTTP/1.1 " . $status);
|
||||
$resheader = $_SERVER["SERVER_PROTOCOL"] . " " . $status;
|
||||
if (! empty($status_message)) {
|
||||
$resheader .= ' ' . $status_message;
|
||||
}
|
||||
header($resheader);
|
||||
|
||||
$response['status'] = $status;
|
||||
$response['status_message'] = $status_message;
|
||||
|
||||
Reference in New Issue
Block a user