diff options
author | Minteck <contact@minteck.org> | 2023-01-31 10:40:30 +0100 |
---|---|---|
committer | Minteck <contact@minteck.org> | 2023-01-31 10:40:30 +0100 |
commit | c6df470866ce00f91345888eac6d8aa76db694dc (patch) | |
tree | c986648d44afa95fafefa2780bc205ac434b8cca /api/booru-check.php | |
parent | bdc6e413162587faea3e528fed4efa81e0f8a73f (diff) | |
download | pluralconnect-c6df470866ce00f91345888eac6d8aa76db694dc.tar.gz pluralconnect-c6df470866ce00f91345888eac6d8aa76db694dc.tar.bz2 pluralconnect-c6df470866ce00f91345888eac6d8aa76db694dc.zip |
Deleted 2 files (automated)
Diffstat (limited to 'api/booru-check.php')
-rw-r--r-- | api/booru-check.php | 24 |
1 files changed, 0 insertions, 24 deletions
diff --git a/api/booru-check.php b/api/booru-check.php deleted file mode 100644 index b2a3800..0000000 --- a/api/booru-check.php +++ /dev/null @@ -1,24 +0,0 @@ -<?php - -$list = array_map(function ($i) { - return sha1($i) . md5($i); -}, array_filter(scandir($_SERVER['DOCUMENT_ROOT'] . "/includes/tokens"), function ($i) { return !str_starts_with($i, "."); })); -header("Content-Type: text/plain"); - -$obj = [ - "valid" => false, - "user" => null -]; - -if (isset($_GET["key"])) { - if (in_array($_GET["key"], $list)) { - $obj["valid"] = true; - - foreach (array_filter(scandir($_SERVER['DOCUMENT_ROOT'] . "/includes/tokens"), function ($i) { return !str_starts_with($i, "."); }) as $token) { - $data = json_decode(file_get_contents($_SERVER['DOCUMENT_ROOT'] . "/includes/tokens/" . $token), true); - $obj["user"] = $data["login"]; - } - } -} - -die(json_encode($obj));
\ No newline at end of file |