aaaaaaaa
This commit is contained in:
@@ -18,7 +18,7 @@ function write_ini_file($assoc_array, $path) {
|
||||
|
||||
$config = parse_ini_file("$documentRoot/data/config.ini");
|
||||
|
||||
$hash = file_get_contents("$documentRoot/data/hash.txt");
|
||||
include("$documentRoot/data/hash.php");
|
||||
$method = $_SERVER['REQUEST_METHOD'];
|
||||
if ($method == "POST") {
|
||||
$start_time = $_POST['start_time'];
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
<?php
|
||||
$documentRoot = $_SERVER['DOCUMENT_ROOT'];
|
||||
include("$documentRoot/import_runners.php");
|
||||
$hash = file_get_contents("$documentRoot/data/hash.txt");
|
||||
include("$documentRoot/data/hash.php");
|
||||
$method = $_SERVER['REQUEST_METHOD'];
|
||||
if ($method == "GET") {
|
||||
parse_str($_SERVER['QUERY_STRING'], $query);
|
||||
|
||||
@@ -1,18 +1,17 @@
|
||||
<?php
|
||||
$documentRoot = $_SERVER['DOCUMENT_ROOT'];
|
||||
print_r($documentRoot);
|
||||
$hash = file_get_contents("$documentRoot/data/hash.txt");
|
||||
include("$documentRoot/data/hash.php");
|
||||
$method = $_SERVER['REQUEST_METHOD'];
|
||||
if ($method == "POST") {
|
||||
$password = $_POST['password'];
|
||||
|
||||
if (!password_verify($password, $hash)) {
|
||||
http_response_code(response_code: 401);
|
||||
}
|
||||
else {
|
||||
http_response_code(response_code: 200);
|
||||
}
|
||||
}
|
||||
else {
|
||||
}else {
|
||||
http_response_code(response_code: 405);
|
||||
}
|
||||
|
||||
|
||||
@@ -6,7 +6,7 @@ $runner_id = $_POST['id'];
|
||||
$time = $_POST['time'];
|
||||
$password = $_POST['password'];
|
||||
|
||||
$hash = file_get_contents("$documentRoot/data/hash.txt");
|
||||
include("$documentRoot/data/hash.php");
|
||||
|
||||
if (!password_verify($password, $hash)) {
|
||||
http_response_code(response_code: 401);
|
||||
|
||||
@@ -3,7 +3,7 @@ $documentRoot = $_SERVER['DOCUMENT_ROOT'];
|
||||
include("$documentRoot/import_runners.php");
|
||||
|
||||
|
||||
$hash = file_get_contents("$documentRoot/data/hash.txt");
|
||||
include("$documentRoot/data/hash.php");
|
||||
$method = $_SERVER['REQUEST_METHOD'];
|
||||
if ($method == "POST") {
|
||||
$runner_id = $_POST['id'];
|
||||
|
||||
Reference in New Issue
Block a user