summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMinteck <contact@minteck.org>2022-06-12 23:00:33 +0200
committerMinteck <contact@minteck.org>2022-06-12 23:00:33 +0200
commit01a7ea3c92861529e22f8df52d6005cafcedc334 (patch)
treef255e36b3b810fe13e951e6ba22697df8aab4008
parent146774a4ed1fca946fcc24d66dcca7ffe21dcd72 (diff)
downloadbits-server-01a7ea3c92861529e22f8df52d6005cafcedc334.tar.gz
bits-server-01a7ea3c92861529e22f8df52d6005cafcedc334.tar.bz2
bits-server-01a7ea3c92861529e22f8df52d6005cafcedc334.zip
Remove half-baked code
-rw-r--r--Authentication/Callback/index.php10
1 files changed, 0 insertions, 10 deletions
diff --git a/Authentication/Callback/index.php b/Authentication/Callback/index.php
index 3f50e1c..0dad35d 100644
--- a/Authentication/Callback/index.php
+++ b/Authentication/Callback/index.php
@@ -42,16 +42,6 @@ if (isset($result["access_token"])) {
if (in_array($result["id"], json_decode(file_get_contents($_SERVER['DOCUMENT_ROOT'] . "/Private/AllowedUsers.json"), true))) {
$token = bin2hex(random_bytes(32));
file_put_contents($_SERVER['DOCUMENT_ROOT'] . "/Private/SessionTokens/" . $token, json_encode($result));
- session_start();
- session_set_cookie_params([
- 'lifetime' => 0,
- 'path' => '/',
- 'domain' => "",
- 'secure' => true,
- 'httponly' => true,
- 'samesite' => 'None'
- ]);
- setcookie("BITS_SESSION_TOKEN", $token, 0, "/", "", true, true);
header("Set-Cookie: BITS_SESSION_TOKEN=" . $token . "; SameSite=None; Path=/; Secure; HttpOnly");
header("Location: /Authentication/Success");